Login

Use /auths endpoint to log in the user. Customer authorization is based on JWT, which contains customerId, publisherId and expiration date.

There are two ways of login, by offerId (if a customer has already chosen an offer) or by publisherId (in case a customer will choose an offer after authorization).

Recent Requests
Log in to see full request history
TimeStatusUser Agent
Retrieving recent requests…
LoadingLoading…
🚧

Important

It is recommended that customerIP is passed as it is required for correct price calculation because tax rate depends on the country. If customerIP is NOT given, the price will be calculated for request source IP address.

Please note that when using Cleeng Merchant, customerIP should be available for the purpose of proper tax calculation in the US and Canada. It is recommended that customerIP is passed in the register, login, and create order methods.

Response description

ResponseDescription
jwtToken used for authorization. It is required for endpoints related to customers. JWT is valid for 15 minutes. It includes customerId, publisherId, and expiration date (to decode use package like jwt-decode).
refreshTokenA token to generate a new access JWT. Read more about refresh token HERE.
customerTokenSession/authentication token for JSON RPC API.
customerIdCustomer identifier at Cleeng.

Errors

HTTP Status codeError codeMessage
400REQ0001Invalid request body
401USER0001Wrong email or password
422USER0003Customer is not associated with this publisher
500SXXXX (X - number)Internal Server Error
Body Params
string
required

The email address of the customer (valid RFC2822 email address).

string
required

The password of the customer. String containing at least one letter and one digit or special character (!@#$%^&), length - 8-80 characters.

string
required

ID of Cleeng offer, e.g. S565568989_US. Required conditionally, when publisherId is not given.

string
required

ID of publisher (broadcaster). It consists of 9 digits. Required conditionally, when offerId is not given.

string

Customer IP address. This field is used for geo restrictions (stored as last user IP).

Responses

Language
LoadingLoading…
Response
Click Try It! to start a request and see the response here! Or choose an example:
application/json