Authentication

Introduction

Everything you need to integrate Sovyx stock delivery into your app, bot, or storefront.

REST API v1 JSON
Quick start
Make your first API call and receive stock in under 5 minutes.
Authentication
API keys, rate limits, and security best practices.
Reseller guide
Place bulk orders, manage credit, and use the reseller panel.
Webhook events
Get notified the moment an order is fulfilled or stock runs low.

Authentication

Sovyx uses Bearer token authentication. All API requests must include your API key in the Authorization header.

HTTP header
Authorization: Bearer svx_live_xxxxxxxxxxxxxxxxxxxxxxxxxxxx

You can generate and manage API keys from your dashboard under Settings → API Keys. Keys are scoped — a reseller key can only access reseller endpoints.

Keep your key secret. Never expose it in client-side code, browser requests, or version control. Use environment variables in production.

Rate limits

PlanRequests / minuteRequests / day
Free10500
Sovyx Pro10010,000
Sovyx Ultra1,000100,000
Sovyx EliteUnlimitedUnlimited

When you exceed your rate limit the API returns 429 Too Many Requests with a Retry-After header indicating when to retry.

Quick Start

The simplest way to place an order. Everything runs automatically — authenticate, pick stock, and receive keys.

order.js
// npm install sovyx
import { Sovyx } from 'sovyx';

const client = new Sovyx({
  apiKey: process.env.SOVYX_API_KEY
});

// 1. Check available stock
const stock = await client.stock.list({
  category: 'accounts',
  available: true
});

// 2. Place an order
const order = await client.orders.create({
  product_id: stock[0].id,
  quantity: 1,
  deliver_to: 'discord:123456789'
});

console.log(order.keys);  // ['xxxx-yyyy-zzzz']
console.log(order.status); // 'delivered'

Or use the REST API directly from any language:

curl
curl -X POST https://api.sovyx.cc/v1/orders \
  -H "Authorization: Bearer $SOVYX_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"product_id":"prod_netflix_4k","quantity":1}'

Error Codes

The API returns standard HTTP status codes. All error responses include a JSON body with error.code and error.message.

StatusCodeDescription
400bad_requestMissing or invalid parameters
401unauthorizedInvalid or missing API key
403forbiddenInsufficient plan permissions
404not_foundResource does not exist
409out_of_stockProduct temporarily unavailable
429rate_limitedToo many requests — back off and retry
500internal_errorServer error — contact support

Webhooks

Webhooks let your server receive real-time notifications when orders are fulfilled, keys are delivered, or stock runs low. Register an HTTPS endpoint and we'll POST events to it.

Event types

EventTriggered when
order.fulfilledAn order is completed and keys are ready
order.failedAn order could not be completed
key.deliveredA key is sent to the recipient
stock.lowA product falls below its alert threshold
stock.emptyA product goes out of stock
webhook-handler.js
import { verifySignature } from 'sovyx';

app.post('/webhooks/sovyx', (req, res) => {
  // Verify the request is from Sovyx
  const sig = req.headers['svx-signature'];
  if (!verifySignature(req.body, sig, process.env.SOVYX_WEBHOOK_SECRET)) {
    return res.status(401).end();
  }

  const { event, data } = req.body;

  if (event === 'order.fulfilled') {
    console.log(`Order ${data.id} fulfilled — keys: ${data.keys.join(', ')}`);
  }

  res.status(200).end();
});

API Reference

Base URL: https://api.sovyx.cc/v1

All requests and responses use JSON. Timestamps are in ISO 8601 format (UTC).

Create order

POST /v1/orders

Place a new order for one or more units of a product. Keys are delivered automatically on fulfillment.

Body parameters
product_id string required The ID of the product to order. Use GET /v1/stock to list available products.
quantity integer required Number of units to purchase. Must be ≥ 1. Reseller plans allow up to 500 per request.
deliver_to string optional Delivery target. Format: discord:USER_ID, telegram:CHAT_ID, or email:addr@example.com. Defaults to your account's registered Discord.
metadata object optional Arbitrary key-value pairs attached to the order. Useful for correlating with your own records.
Response · 201 Created
{
  "id": "ord_01HXYZ",
  "status": "delivered",
  "product_id": "prod_netflix_4k",
  "quantity": 1,
  "keys": ["email@example.com:password123"],
  "delivered_at": "2026-11-22T14:03:12Z",
  "created_at": "2026-11-22T14:03:10Z"
}

List stock

GET /v1/stock

Returns all available products with their current stock levels and pricing.

Query parameters
category string optional Filter by category. One of: accounts, keys, tools.
available boolean optional When true, only return products currently in stock.
limit integer optional Number of results per page (default: 20, max: 100).
Response · 200 OK
{
  "data": [
    {
      "id": "prod_netflix_4k",
      "name": "Netflix Premium 4K",
      "category": "accounts",
      "price": 4.99,
      "reseller_price": 2.49,
      "stock": 143,
      "warranty_days": 30
    }
  ],
  "total": 42,
  "page": 1
}

Get balance

GET /v1/account/balance

Returns your current credit balance and usage for the billing period.

Response · 200 OK
{
  "balance": 47.50,
  "currency": "USD",
  "plan": "pro",
  "orders_this_month": 34,
  "orders_limit": 50,
  "reset_at": "2026-12-01T00:00:00Z"
}