Ungesicherte Verbindung erkannt SICHERE VERBINDUNG IP:Unknown IP SIE SIND NICHT SICHER GESCHÜTZT DURCH COLONELVPN

ColonelVPN

ColonelVPN reseller API

Erstellen, renew and manage VPN services for your customers from your own system.

Ein API-Terminal mit einem strukturierten Anforderungs- und Antwortpfad. Dies ist eine konzeptionelle Entwicklerillustration, kein funktionierender Endpunkt oder Live-Integration.

For approved resellers. The API does what the reseller panel does, paid from your reseller balance. You make your keys in the panel under Einstellungen, API keys. Not a reseller yet? Beginnen Sie mit dem reseller programme.

Basics

Addresshttps://colonelvpn.com/wp-json/cvpn-reseller/v1/
FormatJSON in, JSON out. Times are Unix seconds; expires_iso gives the same end date as text.
MoneyEuro, without VAT. Every paid call is taken from your reseller balance at your own price level. Nothing is refunded.
Limit120 requests a minute for each key. Above that the answer is 429.
User-AgentSend a User-Agent that names your own software. It must not contain the word “colonel”.

Keys

Send your key in the header X-API-Key, or as Authorization: Bearer. A key is shown once, when you create it.

Three permissions

read only looks. sell also creates customers, adds time and makes codes. manage also stops access and changes devices and names.

Test keys

A test key checks your input and answers like the real call, with "test": true. It creates nothing and charges nothing.

Limits you set

A key can be limited to your own IP addresses or IPv4 ranges. Revoking a key in the panel stops it at once.

Never pay twice

Send external_id, your own order number, with every call that costs money, or the header Idempotency-Key. If you repeat the call with the same value, you get the first result back with "repeated": true and nothing is charged again.

Calls

Method and pathNeedsWhat it does
GET /melesenBalance, currency, price level, active customers, permission and kind of the key
GET /priceslesenEvery period and device count on sale, with your price
GET /locationslesenLocations for WireGuard files
GET /balance/historylesenBalance rows, newest first. Takes limit Und offset
GET /serviceslesenYour customers. Takes state (active, expiring, expired, suspended), search, limit, offset
POST /servicessellNew customer. Body: label, days, devices, optional device_name, external_id
GET /services/{id}lesenOne customer with devices and links. usage=1 adds the data used per device
POST /services/{id}manageChange label oder auto_renew
POST /services/{id}/renewsellAdd time. Body: days, external_id
POST /services/{id}/suspendmanageStop access. The end date keeps running
POST /services/{id}/resumemanageRestore access
POST /services/{id}/devicesmanageFügen Sie ein Gerät hinzu. Body: name. The answer holds its link
DELETE /services/{id}/devices/{device}manageRemove a device. Its link stops working
POST /services/{id}/devices/{device}/relinkmanageNew link for a device. The old one stops working
GET /services/{id}/devices/{device}/wireguardlesenOne WireGuard configuration as text. Takes location
POST /codessellA batch of codes. Body: count (1 to 500), days, devices, optional note, external_id
GET /codeslesenYour batches. With batch, the codes of one batch and whether each was used

A customer in the answers

{
  "id": 41,
  "label": "Anna",
  "status": "active",
  "expires": 1798761600,
  "expires_iso": "2027-01-01T00:00:00+00:00",
  "device_limit": 3,
  "device_count": 1,
  "auto_renew": false,
  "held_by_you": true,
  "created": 1796169600,
  "devices": [
    { "id": "aB3dE5fG7hJ9", "name": "phone", "link": "https://...", "created": 1796169600 }
  ]
}

status is active, expired oder suspended. held_by_you is false for a service that sits in a customer’s own account because it was made from one of your codes; that customer manages its devices, not the API.

POST /services answers 201 with the service, the price and your new balance. If the first device could not be set up at that moment the answer also carries warning: the customer is paid for, and adding the device later costs nothing.

Errors

Every error has the same shape: { "code": "...", "message": "...", "data": { "status": 422 } }.

HTTPCodeMeaning
401no_key, bad_keyNo key, or a wrong or revoked key
402fundsThe balance does not cover the price. Nothing was charged
403ip_not_allowed, not_permitted, account_closed, closedWrong IP address, a key without this permission, or a reseller account that cannot be used now
404no_service, no_deviceNot found, or it belongs to somebody else
409limit, inactive, not_managed, busyDevice limit reached, service not active, service in the customer’s own account, or the balance is busy
422input, not_on_saleA missing or wrong field, or this period and device count has no price
429too_many_requestsMore than 120 requests in a minute
503vpn_unreachableThe VPN service could not be reached. Nothing was lost; try again

Example

curl -s https://colonelvpn.com/wp-json/cvpn-reseller/v1/services \
  -H "X-API-Key: cvr_test_..." -H "Content-Type: application/json" -A "my-shop/1.0" \
  -d '{"label":"Anna","days":30,"devices":3,"external_id":"order-1001"}'

Keep keys on your server. Never put a key in a web page or in a mobile app.

Ready-made connections

You do not have to write the integration yourself. Ready-made connections for WordPress, WooCommerce, WHMCS, Blesta, HostBill (beta) and Shopify use this API with your key. See what each one does on the Reseller-Seite.

Good to know

  • Money. Every amount is in the currency of your reseller account (EUR or USD), without VAT. GET /me Und GET /prices name it in the field currency; read it from there.
  • Services that are about to end. Your software asks for them with GET /services?state=expiring; nothing is sent to your address by itself.
  • Free test codes are made in the panel only.

Reseller programme Kontaktieren Sie uns

API-Fragen

Who can use the ColonelVPN API?

Approved resellers. The API does what the reseller panel does and is paid from the reseller balance.

How do I get an API key?

Sign in as a reseller, open Settings in the reseller panel and create a key under API keys. The key is shown once.

Can I test without spending money?

Ja. A test key checks your input and answers like the real call, but creates nothing and charges nothing.

What happens if my request is sent twice?

Send your own order number as external_id, or an Idempotency-Key header. A repeated call returns the first result and is not charged again.

Is there a WooCommerce or WHMCS plugin?

Ja. There are ready-made connections for WordPress, WooCommerce, WHMCS, Blesta, HostBill (beta) and Shopify. They use this same API.