Overview
The Keysender API lets your own software do what the panel does: create inventory databases, upload codes, record sales that deliver a code to a buyer, manage customers, and buy from the Supply catalog. You authenticate once with your API key and secret, receive a bearer token, and send that token with every request afterwards.
TL;DR
- Get your API Key and API Secret from Account, Settings, Security in the panel.
- Exchange them for a bearer token at
POST /login, then send it asAuthorization: Bearer ...on every call. - Page with
page/pagesize, filter with a JSONfilterparam, and stay under 600 requests a minute.
Before you start
Make sure you have:
- Access to your Keysender vendor account.
- Your API key and API secret. Both live in the panel under Account, Settings, Security (see Managing your account settings), in the API Information card. They are issued when you sign up; there is nothing to request.
- A tool that can send HTTP requests with a JSON body, such as curl, Postman, or your own code.
Keep the secret private. Anyone who has both values can read and change everything in your account.
Steps
Know the base URL
- Every request goes to
https://panel.keysender.com/api/v1.0, followed by the endpoint path. The full reference, generated from the same definition the API runs on, is at panel.keysender.com/api. - Send JSON with the header
Content-Type: application/json, and read JSON back.
Exchange your key and secret for a token
- Send
POST /loginwith your two values in the body:
curl -X POST "https://panel.keysender.com/api/v1.0/login" \
-H "Content-Type: application/json" \
-d '{"api_key": "YOUR_API_KEY", "api_secret": "YOUR_API_SECRET"}'
- Read
access_tokenfrom the response. It also returnstoken_type(Bearer) andexpires_at.
{"access_token": "eyJ0eXAiOiJKV1QiLCJhbGciOi...", "token_type": "Bearer", "expires_at": "2027-08-26 10:15:00"}
- Send the token on every other call as
Authorization: Bearer YOUR_ACCESS_TOKEN. Logging in again issues another token; the earlier one stays valid until it expires or you callGET /logoutwith it.
Make your first call
- List your inventory databases:
curl "https://panel.keysender.com/api/v1.0/databases" \
-H "Authorization: Bearer YOUR_ACCESS_TOKEN"
- The response is an array of databases plus the paging fields
pageandpagesize.
Page and filter lists
- List endpoints (
/databases,/codes,/customers) acceptpage(starting at 0) andpagesize(default 100, maximum 1000). - Filter with a JSON array in the
filterquery parameter, for examplefilter=[{"name":"Steam keys"}]on/databases. Each endpoint's guide lists the fields it can filter on. - The API allows 600 requests per minute per account. Above that you receive HTTP 429; wait a minute and retry.
Read errors
401with{"message": "Unauthorized"}means the token is missing, expired, or logged out. Log in again.422means the request was understood but rejected. The body is{"ack": "Failure", "message": "...", "code": 1001}; the message says which field is wrong.- Supply catalog endpoints use
{"status": "...", "error_code": "...", "message": "..."}instead; see Buying from the Supply catalog with the API.
Confirm it works
GET /databases returns HTTP 200 and a JSON array (empty if you have no databases yet) with page and pagesize at the end. If you see the same databases you see under Inventory in the panel, your token works. For the full path from a fresh key to a delivered code, see Connecting your own app to Keysender.
Troubleshooting
| Symptom | Cause | Action |
|---|---|---|
401 or a generic server error on /login itself |
The key or secret has a typo or a stray space | Copy both again from the API Information card |
401 on every other call |
The Authorization header is missing the word Bearer and a space before the token |
Send Authorization: Bearer YOUR_ACCESS_TOKEN exactly |
| Every call logs in first | The token is not being reused | Keep one token per integration and reuse it until it expires |
If it still is not working
Submit a ticket with the endpoint, the exact response body, and the time of the call. Never include your API secret in a ticket.
Quick answers
Where do I find my Keysender API key and secret?
In the panel under Account > Settings, in the API Information card. Both values are issued when you sign up, so there is nothing to request. Copy them exactly; a stray space is the most common reason a login is rejected.
Do I send the API key on every request?
No. You send the key and secret once to POST /login, receive an access token, and send that token as an Authorization: Bearer header on every other call. Reuse the token until it expires or you log it out.
What does a 422 response mean?
The request reached the API but was rejected. The body carries ack, message, and code; the message names the field that is missing or wrong. A 401 means the token is missing, expired, or logged out.
Was this helpful?