Skip to main content

API Key Management

This guide walks you through creating and using API keys to authenticate with the Allfly Connect API.

Overview

API keys are required to authenticate requests to the Allfly Connect API. This guide covers:

  • Navigating to the Integrations settings
  • Creating a new API key
  • Securely storing your API key
  • Testing your API key with the Swagger documentation
  • Making your first authenticated API request
warning

API keys are displayed only once during creation. Make sure to copy and store your API key securely before closing the dialog.

Prerequisites

  • Administrator or Owner role in Allfly Quest
  • Access to your organization's Allfly Quest account

Step-by-Step Guide

1. Navigate to Integrations Settings

  1. Log into your Allfly Quest account
  2. Click on Settings in the navigation menu
  3. Select the Integrations tab
Integration Settings

2. Create a New API Key

  1. Click the Create API Key button
  2. Enter a descriptive name for your API key (e.g., "Production Integration", "Development", "Partner Integration")
  3. Click Create
Create API Key

3. Copy and Store Your API Key

danger

This is the only time your API key will be displayed. If you lose it, you'll need to create a new one.

  1. Click the Copy button to copy your API key to the clipboard
  2. Store the API key securely in your password manager or secrets management system
  3. Check the acknowledgment box confirming you've saved the API key
  4. Click Done
Copy API Key

4. Access the Swagger Documentation

  1. Navigate to the Allfly Connect API Swagger documentation

  2. The Swagger UI provides interactive API documentation where you can test endpoints

Swagger Documentation

5. Authorize with Your API Key

  1. Click the Authorize button at the top of the Swagger UI
  2. In the authorization dialog, paste your API key into the Value field
  3. Click Authorize
  4. Click Close to return to the documentation
Authorize in Swagger

6. Test with the GET Events Endpoint

  1. Scroll to the Events section in the Swagger UI
  2. Click on the GET /events endpoint to expand it
  3. Click the Try it out button
  4. Click Execute to send the request
  5. Verify that you receive a successful response (HTTP 200) with your events data

If you see event data in the response, your API key is working correctly.

Troubleshooting

401 Unauthorized Error

If you receive a 401 Unauthorized error:

  • Verify that you've authorized in Swagger with your API key
  • Check that you copied the complete API key without extra spaces
  • Ensure your API key hasn't been deleted from the Integrations settings

No Events Returned

If the request succeeds but returns an empty array:

  • This is normal if you haven't created any events yet
  • Try creating a test event in Quest and re-running the request

Best Practices

  • Use descriptive names: Name your API keys based on their purpose or environment
  • Rotate regularly: Create new API keys periodically and delete old ones
  • Limit exposure: Only share API keys with team members who need them
  • Monitor usage: Regularly review last used date of your API keys in the Integrations settings
  • Delete unused keys: Remove API keys that are no longer needed

Next Steps

Now that you have a working API key, you can:

  • Explore other API endpoints in the Swagger documentation
  • Set up webhook integrations to receive real-time event notifications
  • Integrate the API into your application or service

Managing Existing API Keys

To view or delete existing API keys:

  1. Go to Settings > Integrations
  2. View the list of active API keys
  3. Click the delete icon next to any key you want to remove
  4. Confirm the deletion
tip

Deleting an API key immediately revokes access for any applications using that key.