Back to Documentation

API Authentication

Securely authenticate public API requests to Fortifiers with a scoped API key.

API Keys

The Fortifiers public API uses API keys. Send the key in the X-API-Key header.

Security

Requests must be made over HTTPS. Plain HTTP requests will be rejected to ensure the security of your API credentials.

Permissions

API keys are scoped to specific permissions. Ensure your key has the necessary scopes for the endpoints you are accessing.

Making Authenticated Requests

Include your API key in the X-API-Key header of all requests.

curl -X POST https://api.fortifiers.app/api/v1/sourcing/price \
 -H "X-API-Key: YOUR_API_KEY" \
 -H "Content-Type: application/json" \
 -d '{"query":"commercial flooring"}'

Obtaining an API Key

  1. 1

    Log in to your Fortifiers dashboard

  2. 2

    Navigate to Settings → API

  3. 3

    Click "Generate New API Key"

  4. 4

    Copy and securely store your API key immediately.

Important Security Warning

Your API key will only be displayed once. Store it securely and never commit it to version control (e.g., git).

Authentication Errors

Status CodeErrorDescription
401UnauthorizedMissing or invalid API key
403ForbiddenAPI key doesn't have required permissions
429Rate Limit ExceededToo many requests, try again later

Rate Limiting

Starter100 req/min
Pro500 req/min
EnterpriseCustom

Response Headers

  • X-RateLimit-LimitTotal requests allowed
  • X-RateLimit-RemainingRequests remaining
  • X-RateLimit-ResetReset timestamp

Best Practices

  • Store API keys in environment variables
  • Use different keys for dev/prod
  • Rotate keys periodically (90 days)
  • Revoke compromised keys immediately
  • Always use HTTPS