API Reference
Now you can start using our API Reference. It's a great way to get familiar with the available endpoints, requests, and responses.
Remember that your client credentials (that will go into the Authorization header in certain requests) should be a base64 encoded string (in UTF-8 encoding) consisting of a concatenation of your client ID and Secret separated by a colon with the word "Basic" in front of it.
Authorization
As explained earlier in these docs, in order to execute actions on behalf of application users, you need an access token. So, provided that you have:
- An application with a Client ID, Client Secret and API Key
- An active test account on the Portal you want to integrate with
Then you can start by getting an authorization code by manually visiting this URL, logging in to the Portal, and authorizing your app:
https://<OUR RE SITE>/<LOCALE>/crm/authorization/?response_type=code&client_id=<YOUR CLIENT ID>&state=<A USER ID>
To learn more about each parameter, see Authorization Flow.
After doing all that you'll be redirected to your Authorization Callback URL. Now you have to copy the authorization code from that URL, go back to Request Access Token and replace the code
in the body.
After sending this request you'll get your access and refresh tokens. If your access token got expired and you need a new one, just use the Refresh Token request.
Posting ads
To post an advert just use the Create an Advert request. Remember to choose a proper one depending on the market.
If you haven't set up a callback URL in your application then you need to manually get the status of your operation. After posting the advert, the advert_uuid
will be returned in a response. To check the advert's status, simply use the Get Advert Metadata request (see more: Get advert metadata).
There are a few other endpoints available for you. We'll be updating this regularly so make sure you come back to check the latest version.
Updated 3 months ago