Getting started
The 360insights Platform APIs let your systems work directly with your 360insights programs. You can send in users, accounts, claims and sales data, and pull back claims, rewards and program data. Every API on this site works the same way:
- One gateway. Every API is reached through
https://api.test.360insights.io. - One sign-in. A single Auth0 access token works for every API you’ve been granted.
- One reference. Each API has an interactive page where you can read the details and Try it from your browser.
This page takes you from zero to your first successful call, then covers what you need before you go live.
Before you begin
You’ll need:
- Credentials from 360insights. These are a client ID, a client secret and an organization ID. Each environment has its own set. To request them, [TBD: contact your 360insights Customer Success Manager / submit the API access request form].
- Access to the APIs you need. Access is granted per API. Your credentials only work with the APIs that 360insights has
enabled for your organization. Each API has its own access scope, for example
access:platform:provisioningfor the APSSO API. - A server-side environment. This is where your integration runs and where the client secret is kept. Never call the APIs with your client secret from a browser or mobile app.
Quickstart: your first call in four steps
1. Find your API
Open the API catalogue and note the base URL of the API you want to use. Base URLs follow one pattern:
https://api.test.360insights.io/{domain}/{api}
For example, the APSSO API is at https://api.test.360insights.io/platform/provisioning.
2. Get an access token
Exchange your credentials for a token at the Auth0 token endpoint. Always set audience to the gateway (https://api.test.360insights.io).
Authentication explains every field and has a form you can use instead.
curl -s -X POST https://360insights-org-qa.us.auth0.com/oauth/token \
-H 'content-type: application/json' \
-d '{
"grant_type": "client_credentials",
"client_id": "YOUR_CLIENT_ID",
"client_secret": "YOUR_CLIENT_SECRET",
"organization": "YOUR_ORGANIZATION_ID",
"audience": "https://api.test.360insights.io"
}'
Copy the access_token from the response. It’s valid for 24 hours. Reuse it until shortly before it expires, rather than
requesting a new token for every call.
3. Make your first call
Send the token in the Authorization header. This example lists the first five users in the APSSO API. Any read-only endpoint
of an API you have access to works the same way.
curl -s "https://api.test.360insights.io/platform/provisioning/Users?limit=5" \
-H 'Authorization: Bearer YOUR_ACCESS_TOKEN'
A 200 OK with a JSON body means you’re connected. If you get a different response, these are the usual causes:
| Response | Usual cause | What to do |
|---|---|---|
401 Unauthorized |
The token is missing, expired, malformed, or was issued for the wrong audience. |
Request a new token with audience: https://api.test.360insights.io. Send it as Bearer <token>. |
403 Forbidden |
Your token doesn’t carry this API’s scope, or you’re asking for another organization’s data. | Check the token’s scope field. Ask 360insights to grant access if it’s missing. |
404 Not Found |
The base URL or route is wrong. | Compare it with the API’s page and the catalogue. Routes may be case-sensitive. |
4. Explore in your browser
Every API page has a Try it button on each endpoint. To use it, paste your token into the API’s Authentication section. Alternatively, on the Authentication page, tick Use this token with ‘Try it’ to use the token on every API page in the current tab. Each endpoint page shows the request fields, response shapes and models.
How the platform APIs fit together
| Topic | Details |
|---|---|
| Gateway | Every request goes through the central API gateway. The gateway checks your token and forwards the request to the right service. You never call the services behind it directly, and you never need their internal scopes. |
| Environments | Nonprod (this site): https://api.test.360insights.io, with the Auth0 token endpoint https://360insights-org-qa.us.auth0.com/oauth/token.The Production environment is separate: it has its own gateway URL, Auth0 tenant and audience, so each environment needs its own credentials and tokens. |
| Identity | Your credentials belong to your organization. Some APIs also scope data to a client or program, which is identified in the route or in your token. The API’s page explains how. |
| Format | JSON over HTTPS. Send Content-Type: application/json on requests that have a body. |
Conventions and good practice
Each API documents its own details, but these hold true across the platform.
Identifiers
Many APIs identify records by your IDs (for example userExternalId and accountExternalId), so you don’t have to store
ours. When an API returns its own reference, such as a correlationId, store it. You’ll need it for updates and for support.
Errors
Standard HTTP status codes tell you whether to retry:
| Status | Meaning | Retry? |
|---|---|---|
2xx |
Success. 201 Created for creates. |
— |
400 |
Validation failed. The body explains what’s wrong. | No. Fix the request first. |
401 / 403 |
Authentication or permission problem. See step 3. | For a 401, retry once with a new token. For a 403, don’t retry. |
404 / 409 |
Not found, or conflicts with the current state (for example, a duplicate or a stale version). | No. Re-read the data and decide what to do. |
429 |
Too many requests. [TBD: confirm gateway rate limits] | Yes. Back off, honouring Retry-After if present. |
5xx |
A temporary problem on our side. | Yes, with exponential backoff. |
Many APIs return error details as RFC 7807 problem details, often including a correlation or trace ID. Log that ID: it’s the fastest way for us to find your request.
Retries and duplicates
Before you retry a POST that timed out, check the API’s page to see whether it deduplicates. If it doesn’t, look the record
up first (for example by your external ID) so you don’t create it twice.
Volume and paging
Many write endpoints accept batches (a JSON array), and list endpoints are paged. For example, the APSSO API uses
skip and limit, with a maximum of 1000 per page. Send reasonably sized batches and page through large result sets, rather
than requesting everything at once.
Security
- Keep the client secret in a vault or secrets manager. Never commit it, log it, or ship it to a browser or device.
- Cache tokens on the server, and never log full tokens.
- Request narrower scopes if a component only needs some of your APIs.
- Use test data in nonprod. [TBD: confirm the data policy for nonprod]
- Tell 360insights straight away if you think a secret has been exposed, so it can be rotated.
Going-live checklist
- Your integration works end to end in nonprod, including error handling, retries and the
401token-refresh path. - You have production credentials and API access. [TBD: request process]
- The production gateway URL, Auth0 tenant and
audienceare in configuration, not hard-coded. - Tokens are cached and refreshed before they expire.
- Correlation or trace IDs and response status codes are logged, so you can raise precise support requests.
- Monitoring alerts you to sustained
4xxor5xxrates. - A technical contact is registered with 360insights to receive change and deprecation notices.
Changes and versioning
We add new endpoints and fields without notice, so make sure your integration ignores fields it doesn’t recognise.
[TBD: how breaking changes are versioned (for example a /v2 path) and how much notice is given, for example 90 days]
Getting help
[TBD: support channel, for example a support portal link or email address, and support hours]. Include the following in your request:
- the API name and environment
- the request method and path
- the time of the request (UTC)
- the HTTP status, and any correlation or trace ID from the response
Never send your client secret or a full access token.
Glossary
| Term | Meaning |
|---|---|
| Gateway | The single entry point (api.test.360insights.io) for every platform API. |
| Client ID / client secret | The credentials 360insights issues to your application. The secret works like a password. |
| Organization | Your company’s identity in Auth0. You send it when requesting a token. |
| Audience | Which API a token is for. On this platform it’s always the gateway. |
| Scope | A permission carried by a token. There’s one per API, for example access:platform:provisioning. |
| Access token | A short-lived JWT you send as Authorization: Bearer <token>. |
| External ID | Your own identifier for a record (user, account and so on), used as its key in the API. |
