Getting Started with Authentication

Sparkfly's platform uses a central authentication service shared across all public APIs. Authentication begins with obtaining an auth token via the Authentication API, which is then used to authorize requests to other APIs.

Obtaining Access Credentials

To interact with Sparkfly's APIs, you need to have valid credentials provided by Sparkfly. These include:

  • API Identity: A unique identifier for your application.
  • API Key: A secret key used to authenticate your application.

Requesting an Auth Token

To obtain an auth token, you must request a token from the Authentication API using your API Identity and API Key. See the Authentication API Reference for detailed information on how to make this request.

Auth Token Lifetime

Auth tokens have a limited lifetime, typically expiring after a 24-hour period. After expiration, you will need to request a new auth token using the same process. Your application should anticipate token expiration and handle it gracefully to ensure uninterrupted access to the APIs. This can be achieved through a combination of proactive token renewal and error handling for expired tokens.

Using the Auth Token

Once you have obtained an auth token, the token must be included in the X-Auth-Token header of all subsequent API requests to authorize access.