Skip to main content
SalesOS has two environments. They run the same API — same endpoints, actions, fields and errors — with separate data and separate keys.
Keys never cross environments. A sk_live_ key sent to Staging, or a sk_test_ key sent to Production, gets 401 with code: "api_key_not_found".

Choose the environment by its base URL

Only the base URL changes. Paths, bodies and signatures are identical, so keep the base URL and the key in configuration, never in code:
Every example in this documentation uses the production URL. To run it in Staging, swap https://api.play2sell.com for https://api-staging.play2sell.com and use a sk_test_ key.
The signature covers the path, not the host, so the same request signed for one environment is valid in the other only with that environment’s key. Never reuse a production key in test tools.

Get a key for each environment

1

Staging

Ask your Play2sell contact for access to a test company in Staging. Then, in https://app-staging.play2sell.com, go to Admin > Integrations > API Keys and create a key with the scopes your integration needs. It starts with sk_test_.
2

Production

When your integration passes the checklist below, an admin of your company creates the key in https://app.play2sell.com, same menu, same scopes. It starts with sk_live_.
The secret is shown only once, when the key is created. Store it in a secret manager.

What to test in Staging

Go-live checklist

  • Base URL and key come from configuration; nothing environment-specific in code
  • A sk_live_ key with only the scopes you use
  • The secret is in a secret manager, not in the repository or logs
  • Your server clock is synchronized (signatures are valid for 30 seconds)
  • Retries with backoff on 429 and 5xx; writes carry an idempotency_key
  • The request ID of every answer is logged (meta.request_id, or instance in Payments errors), so support can find any call
  • Webhook endpoint in production is https://, public, verifies the signature and answers 2xx quickly
  • The first production calls are monitored for a day

Good practices

  • Use Staging for anything that writes. Exploring with reads in production is fine; trying writes is not.
  • Test data stays in Staging. Do not copy real people’s data into Staging.
  • Expect new versions in Staging first. If something changes, you see it there before it reaches production.