Environments and credentials

Oscar API has two environments: the test environment (sandbox) and production. You get separate credentials for each.

Environments

  • Test environment (sandbox): https://testapi.oscar.fi. Calls go to a test database, not to production data. Build and test your integration here first.
  • Production: https://api.oscar.fi. Take it into use when the integration is tested in the test environment.

An API address is the environment address followed by the API path:

  • Sales API: https://testapi.oscar.fi/sales and https://api.oscar.fi/sales

The paths and endpoints of all APIs are in the API Catalog.

Write calls also change data in the test database.

Credentials

Each integration gets its own credentials for each environment:

  • Client ID and Client Secret: for getting an access token
  • x-api-key: sent with every API call
  • the token endpoint address

Test environment credentials do not work in production, and production credentials do not work in the test environment.

What the credentials cover

The credentials give you access to all published v2 APIs, see the API Catalog. New resources are announced in the Changelog.

How to get credentials

Tell us your need at . When it is confirmed that APIs for your need are available, Oscar delivers credentials for the test environment and production. More: Getting access.

Keeping credentials safe

  • Keep Client Secret and x-api-key on a server, for example in a secrets manager. Do not put them in code that runs in a browser or a mobile app, and do not commit them to version control.
  • If a credential has leaked, tell support immediately so it can be replaced.

Trying calls in the portal

The API Catalog documentation can be read without credentials. You can try calls in the portal only in the test environment: add x-api-key and an access token with the Authorize button. Production documentation is read-only.

Your first call from the command line or Postman: Quickstart.