Obtaining an API Token
Please reach out to Customer Success team in order to obtain access to the SalesWings public API. The Customer Success team will provide you with the API token you will need to authorize the API calls.
Authorizing API Calls
Once you have the token, you can access the API methods.
In order to call any method, you need to provide the API token with the Bearer Authorization.
An example request might look like:
curl -X 'GET' \
'https://helium.saleswings.pro/api/core/project/account' \
-H 'accept: application/json' \
-H 'Authorization: Bearer $YOUR_API_TOKEN'
API Documentation
You can explore the API documentation available in the OpenAPI format here. The documentation lists all the available endpoints, describes required parameters and method output and provides request and response examples.
If you click the Authorize
button seen on the screenshot above, a dialog will prompt you for the API token.
If you paste your API token and click Authorize
, you will be able to make the calls to the API methods from the OpenAPI UI:
Authorizing with Cockpit Login and Password for Testing
If a member of your team does not have access to the API token, it’s possible to use the special POST /auth
method to generate a temporary token.
curl -X 'POST' \
'https://helium.saleswings.pro/api/core/auth' \
-H 'accept: application/json' \
-H 'Content-Type: application/json' \
-d '{
"username": "$COCKPIT_USERNAME",
"password": "$COCKPIT_PASSWORD"
}'
The endpoint will return a temporary token for you:
{
"token": "b9926dda101767f9af9ad72471e9b12dfd3e4cd7806",
"expiresOn": "2022-22-10T12:22:20Z",
"apiUrl": "https://helium.saleswings.pro"
}
You can use the returned token instead of your permanent API token, but we recommend to restrict its usage only to the OpenAPI UI for testing purposes. You production integration should use the API token provided to you by the Customer Success team.