Skip to main content
POST
/
dev
/
v1
/
oauth
/
token
Exchange an OAuth code or refresh token
curl --request POST \
  --url https://api.shoppex.io/dev/v1/oauth/token \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/x-www-form-urlencoded' \
  --data grant_type=authorization_code \
  --data code=shoa_code_1 \
  --data redirect_uri=https://erp.example.com/callback \
  --data client_id=shoc_demo \
  --data client_secret=shcs_secret
{
  "access_token": "shpat_access_1",
  "token_type": "Bearer",
  "expires_in": 3600,
  "refresh_token": "shprt_refresh_1",
  "scope": "orders.read customers.read"
}

Authorizations

Authorization
string
header
required

Use your Shoppex API key in the Authorization header.

Body

application/x-www-form-urlencoded

The body is of type object.

Response

200 - application/json

Successful response

data
object