Skip to content

Go Agent Overview

The PixlPay Go Agent is a standalone delivery agent that connects to game servers via RCON. It's the recommended integration method for games that don't have native plugin support.

Features

  • Automatic polling for pending deliveries
  • RCON command execution
  • Support for purchases, refunds, and chargebacks
  • Dual-secret authentication
  • Command history and delivery logging
  • Interactive CLI mode for debugging
  • Automatic reconnection with exponential backoff
  • Runs as a background service

Supported Games

GameStatusSetup Guide
Project ZomboidFully SupportedFull Guide
MinecraftPlannedComing Soon
ARK: Survival EvolvedPlannedComing Soon

Download

Download the latest release for your platform:

PlatformDownload
Windowsstore-agent.exe
Linuxstore-agent-linux

Downloads are available from your Pixlpay dashboard under Settings > Game Servers > Downloads.

Quick Start

1. Download the Agent

Get the appropriate version for your server's operating system.

2. Create Configuration

Create a pixlpay-config.json file in the same directory:

json
{
    "platform_url": "https://api.pixlpay.com",
    "store_secret": "YOUR_STORE_SECRET",
    "server_secret": "YOUR_SERVER_SECRET",
    "game_type": "project_zomboid",
    "rcon_host": "127.0.0.1",
    "rcon_port": 27015,
    "rcon_password": "YOUR_RCON_PASSWORD",
    "debug_mode": false
}

3. Run the Agent

bash
# Windows
./store-agent.exe

# Linux
./store-agent-linux

Configuration Options

FieldRequiredDescription
platform_urlYesAPI endpoint (https://api.pixlpay.com)
store_secretYesYour store's API key from dashboard
server_secretYesThis server's unique secret from dashboard
game_typeYesGame identifier (e.g., project_zomboid)
rcon_hostYesRCON server address (usually 127.0.0.1)
rcon_portYesRCON port from your game server config
rcon_passwordYesRCON password from your game server config
debug_modeNoEnable verbose logging (default: false)
dev_modeNoUse development API URL (default: false)
dev_api_urlNoCustom API URL for development

Command Line Options

bash
# Show help
./store-agent.exe -help

# Use custom config file
./store-agent.exe -config=/path/to/pixlpay-config.json

# Interactive mode (with admin commands)
./store-agent.exe -interactive

# Show version
./store-agent.exe -version

Interactive Mode

Run with -interactive to access admin commands:

> status     # Show agent status and configuration
> poll       # Force immediate poll for commands
> queue      # Show pending deliveries (waiting for players)
> history 10 # Show last 10 executed commands
> test       # Test API connection
> debug      # Toggle debug mode
> heartbeat  # Send heartbeat to API
> help       # Show all commands
> quit       # Stop agent

Example Session

========================================
     PixlPay Store Agent v1.0.0
========================================
Game Type:    project_zomboid
RCON Target:  127.0.0.1:27015
API Endpoint: https://api.pixlpay.com
========================================
Connecting to RCON at 127.0.0.1:27015...
RCON connection established!
Agent ready! Polling every 60s, heartbeat every 2m0s

> test
Testing API connection...
Connection successful! API returned status 200.
Server recognized: My PZ Server (ID: 123)
Pending commands: 0

> status
Agent Status:
  - RCON: Connected
  - API: Healthy
  - Last Poll: 5 seconds ago
  - Commands Executed: 42
  - Pending Queue: 0

Logs

The agent writes logs to the logs/ directory:

Log FileContents
pixlpay-general_YYYY-MM-DD.logAll events (comprehensive log)
pixlpay-deliveries_YYYY-MM-DD.logSuccessful deliveries only
pixlpay-errors_YYYY-MM-DD.logErrors and warnings

Log levels:

  • [INFO] - General information
  • [DEBUG] - Verbose debug info (requires debug_mode: true)
  • [WARN] - Warnings (also written to error log)
  • [ERROR] - Errors (also written to error log)

Running as a Service

Windows (Using NSSM)

NSSM (Non-Sucking Service Manager) is recommended for Windows:

powershell
# Download NSSM from https://nssm.cc/download
# Open Command Prompt as Administrator

nssm install PixlPayAgent "C:\path\to\store-agent.exe"
nssm set PixlPayAgent AppDirectory "C:\path\to"
nssm set PixlPayAgent DisplayName "PixlPay Delivery Agent"
nssm set PixlPayAgent Description "Automatic delivery agent for game servers"
nssm set PixlPayAgent Start SERVICE_AUTO_START
nssm start PixlPayAgent

Manage the service:

powershell
nssm status PixlPayAgent  # Check status
nssm stop PixlPayAgent    # Stop service
nssm restart PixlPayAgent # Restart service
nssm remove PixlPayAgent  # Remove service

Linux (Using systemd)

Create /etc/systemd/system/pixlpay-agent.service:

ini
[Unit]
Description=PixlPay Delivery Agent
After=network.target

[Service]
Type=simple
User=gameserver
WorkingDirectory=/home/gameserver/pixlpay
ExecStart=/home/gameserver/pixlpay/store-agent-linux
Restart=always
RestartSec=10
StandardOutput=journal
StandardError=journal

[Install]
WantedBy=multi-user.target

Enable and start:

bash
sudo systemctl daemon-reload
sudo systemctl enable pixlpay-agent
sudo systemctl start pixlpay-agent

Manage the service:

bash
sudo systemctl status pixlpay-agent   # Check status
sudo systemctl stop pixlpay-agent     # Stop service
sudo systemctl restart pixlpay-agent  # Restart service
journalctl -u pixlpay-agent -f        # Follow logs

Directory Structure

Recommended setup:

/home/gameserver/pixlpay/
├── store-agent-linux       # The agent executable
├── pixlpay-config.json     # Your configuration
├── data/
│   └── agent_data.json     # Persistent data (auto-created)
└── logs/
    ├── pixlpay-general_2025-01-15.log
    ├── pixlpay-deliveries_2025-01-15.log
    └── pixlpay-errors_2025-01-15.log

Timing Constants

These values are hardcoded and not user-configurable:

ConstantValuePurpose
Poll Interval60 secondsTime between API polls
Heartbeat Interval2 minutesTime between status updates
Initial Retry Delay5 secondsInitial RCON retry delay
Max Retry Delay5 minutesMaximum RCON retry delay
Request Timeout10 secondsHTTP request timeout

Notification Types

The agent handles three notification types:

TypeDescriptionExecution
purchase_notificationPlayer purchased itemExecute immediately or queue
refund_notificationRefund issuedExecute immediately
chargeback_notificationPayment disputedExecute immediately

Security Considerations

  1. Run as non-root user - Create a dedicated user for the agent
  2. Secure config file - Restrict permissions on pixlpay-config.json
  3. Use localhost for RCON - If running on same machine, use 127.0.0.1
  4. Strong RCON password - Use at least 16 random characters
  5. Never commit config - Add pixlpay-config.json to .gitignore

Game-Specific Guides

Troubleshooting

See the Troubleshooting Guide for common issues and solutions.

Built for game developers, by game developers.