Authentication

How to authenticate your application to use SAAS First API?

Tamas Ham-Szabo Written by Tamas Ham-Szabo I

Currently, we have very limited API access. We will publish API documentation in early 2024. Thank ou for your patience.


Base URL

https://api.saasfirst.com


Authentication

Authentication is handled via OAuth2.0


Firstly, to be able to make requests to the API an access token needs to be acquired. The token request follows client credentials flow. To get an access token make sure to do the following steps:

  • Enable the API access for your workspace
  • Copy the Client ID and Client Secret
  • Make a POST request with the following details:
    • Url: https://api.saasfirst.com/oauth/token
    • Form data:
      • grant_type: client_credentials
      • client_id: paste the previously copied client ID
      • client_secret: paste the previously copied client secret
    • The response should have the following structure:
      { "access_token": "your-access-token", "expires_in": 900, "token_type": "Bearer" }
  • Using the access token acquired, you will be able to make requests to the API endpoints.
  • If the token expires, just repeat the previous steps to get a new access token. It is generally advised to store the access token somewhere in a database and once it is close to expire, request a new access token

Did this answer your question?

🙁 🙂 😀