# project-zomboid-rcon

> Utilize RCON capabilities through NodeJS - useful for Discord bots, status monitoring etc

Latest version **1.0.0** (published 2023-08-13) · MIT license · 0 weekly downloads

## Install

```sh
npm install project-zomboid-rcon
pnpm add project-zomboid-rcon
yarn add project-zomboid-rcon
bun add project-zomboid-rcon
```

## Health

**Score 20/100 (F)** — status: abandoned.

Positive: has types; no vulnerabilities.

Warnings: low downloads; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.0 |
| Published | 2023-08-13 |
| First published | 2023-08-13 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | CommonJS |
| Dependencies | 0 |
| Unpacked size | 8.7 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 1 |
| Author | Alex |
| Maintainers | awexx |
| Keywords | projectzomboid, zomboid, rcon |

## Links

- npm: https://www.npmjs.com/package/project-zomboid-rcon
- Repository: https://github.com/azpha/project-zomboid-rcon
- Homepage: https://github.com/azpha/project-zomboid-rcon#readme
- Issues: https://github.com/azpha/project-zomboid-rcon/issues
- npm.io page: https://npm.io/package/project-zomboid-rcon

## Alternatives

- [@sindresorhus/slugify](https://npm.io/package/@sindresorhus/slugify.md) — 3.7M weekly downloads
- [solid-js](https://npm.io/package/solid-js.md) — 2.7M weekly downloads
- [expo-glass-effect](https://npm.io/package/expo-glass-effect.md) — 2.5M weekly downloads
- [nanoassert](https://npm.io/package/nanoassert.md) — 780.8K weekly downloads
- [@ffmpeg/ffmpeg](https://npm.io/package/@ffmpeg/ffmpeg.md) — 529.5K weekly downloads

## Recent versions

- 1.0.0 (latest) — 2023-08-13

## README

# project-zomboid-rcon
Connect and interact with your Project Zomboid server using RCON capabilities

## What you need
- A Project Zomboid server w/ `RCONPassword` and `RCONPort` set
- NodeJS

..and that's it!

## Usage
```javascript
import {ZomboidCommands, ZomboidRconClient} from 'project-zomboid-rcon'
```

## Example
```javascript
import * as Zomboid from 'project-zomboid-rcon'

// Initialize the client
const zomboid = new Zomboid({
    host: "1.2.3.4", // the IP address to your server
    port: 1234, // RCONPort in the server ini
    password: "bestpasswordevermade" // RCONPassword in the server ini
})

// Connect to the server (this will throw if connection was unsuccessful)
zomboid.connect()

// All valid commands are provided in the zomboid.ZomboidCommands enum
// Run commands using the .send() function on the zomboid class
zomboid.send(zomboid.ZomboidCommands.GRANT_ADMIN, "Alex") // granting admin to Alex

// More than 1 argument? Supply in the same string!
zomboid.send(zomboid.ZomboidCommands.ADD_ITEM, "Alex Base.Tshirt_CamoUrban")

// Disconnect using the .disconnect() function
zomboid.disconnect()
```

---
_Source: https://npm.io/package/project-zomboid-rcon · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
