Logged-In Bearer Token
This section explains obtaining a Bearer Token for a logged-in customer and outlines how an anonymous user can register to access more exclusive functionalities for UpStart Commerce Consumer APIs.
To begin, first register as a customer to establish a more permanent customer profile through our UpStart Commerce Portal UI. Access the portal and log in using your credentials (Email and Password). If you are not already registered, you can follow this link to create your sandbox account.
For details on creating and registering Customer, go to the Customer Management Guide.
To obtain a logged-in bearer token, you need to obtain an anonymous token. If you have not obtained an anonymous token , visit Anonymous Bearer Token Guide for detailed information.
Copy the Curl below to obtain an Access and Refresh token and replace the following values in the header.
- Replace and with your specific values in the header of your request.
- Replace your "Anonymous Bearer Token" generated in Step 2 within the "Authorization" header of your request.
- Replace your "login" and "0password" with your specific values obtained while registering customers in the header.
Request:
For more information, go to the Log-In User endpoint example request.
Upon making an access and refresh token creation request, it responds with a status code indicating the outcome.
After executing the Curl above, you have successfully obtained a valid response for an "accessToken" and "refreshToken". Copy these values and paste them into the authorization field.
Response:
Access tokens serve as short-term credentials for accessing UpStart Commerce APIs, while Refresh tokens act as a mechanism to renew access tokens and maintain customer sessions over a more extended period during exploration.
To make your first call by using a Logged-In Bearer Token, you need to replace your above obtained "Logged-In Bearer Token" in the request authorization header by using the Curl below.
Request:
Response:
For more information, go to the Get Customer Profile endpoint example request.
Upon receiving the successful response to the Get Customer Profile request, you have completed your first UpStart Commerce Consumer API call, using the logged-in bearer token.