Fluz API Explorer

The API explorer allows you to test out different requests and see the responses they return. It's a place for you to practice using the API before you go into the real environment.

Accessing API Explorer on Dashboard

You can access the API explorer from your developer dashboard.

  1. Go to 'Apps and Integrations' and click the API Explorer tab.
  2. Hit "Open staging environment".
  3. Log in.
  4. You're free to start testing and exploring the API!

Authentication and API Key Usage

Getting Your Fluz API Key [Reference]

An API key is required to use the Fluz API. Follow these steps to begin using it:

  1. Copy the API key to the Authorization header.
  2. Format: Basic <API_KEY> (Ensure that the word "Basic" precedes the API key).
  3. Make sure the Authorization header is checked.

Generate User Access Token [Reference]

To access all the features of the API, use the mutation generateUserAccessToken. The following arguments are required for this mutation:

  • userId
  • accountId
  • seatId (optional)
  • scopes

Scopes should only auto-populate three scopes [‘LIST_OFFERS’, ‘LIST_PURCHASES’, ‘LIST_PAYMENT’][‘LIST_OFFERS’, ‘LIST_PURCHASES’, ‘LIST_PAYMENT’]. If you need any more, you need to add manually. The getApplicationUser query will provide a list of scopes available to that user

Fetching Available Scopes: Reference

Use the query getApplicationScope to retrieve a list of available scopes (tokens).
Each API query will specify if a token is required, and which type of token is necessary.

Fetching Available Account Ids: Reference

Use the query getAccountsByUserId to retrieve a list of available seats for each account.

Using Tokens in API Requests: Reference

After generating a token, copy it and use it for your queries.
When you run a query (e.g., getGiftCard), you will receive the data allowed by your user permissions.

In the Headers section of your request, add a new header:
Set the Authorization header with the format: Bearer <TOKEN> (Ensure that the word "Bearer" precedes the token).

Error Handling:

498 Error: This error indicates that the token is incorrect, expired, or inapplicable. You will need to generate a new token in this case.

Query and Mutation Arguments
Some queries and mutations require arguments. Required arguments will be marked with an exclamation point (!).
Non-required arguments are optional, but supplying them may affect the response.

Response Format
Responses can be viewed in either table format or JSON format, depending on your preference or the tool being used.

Using the Fluz API Key


Closing the API Explorer tab

You can close the current page API explorer tab by clicking the 'x' on the tab you're in.