Returns an OAuth 2.0 access token and related metadata. Tokens should be used in subsequent requests to Optoro APIs.
Auth (1.0.0)
The Auth API provides access to other Optoro APIs using the OAuth 2.0 client credentials flow. Optoro's Client Success team will provide the credentials used when requesting an access token. The access token returned from the oauth/tokens endpoint will be used in subsequent requests to Optoro APIs.
Download OpenAPI description
Languages
Servers
Mock server
https://developer.optoro.com/_mock/openapi/auth/openapi
Production
https://auth.optiturn.com
Sandbox
https://auth.sandbox.optiturn.com
Bodyapplication/jsonrequired
The name of the OAuth flow used to create a token. Use 'client_credentials'.
- Mock serverhttps://developer.optoro.com/_mock/openapi/auth/openapi/oauth/token
- Productionhttps://auth.optiturn.com/oauth/token
- Sandboxhttps://auth.sandbox.optiturn.com/oauth/token
- curl
- JavaScript
- Node.js
- Python
- Java
- C#
- PHP
- Go
- Ruby
- R
- Payload
curl -i -X POST \
https://developer.optoro.com/_mock/openapi/auth/openapi/oauth/token \
-H 'Content-Type: application/json' \
-d '{
"grant_type": "string",
"client_id": "string",
"client_secret": "string"
}'Response
application/json
{ "access_token": "G0ybScDl_7CA3tWVou", "token_type": "Bearer", "expires_in": 90000, "scope": "read write", "created_at": 1656518368 }