Skip to main content

API Token Authentication

The Uncash API uses API token authentication. All requests must include your API token in the Authorization header.

Header Format

Authorization: Bearer uc_your_api_token_here

Token Format

API tokens are prefixed with uc_ followed by a 40-character string:
uc_1234567890abcdef1234567890abcdef12345678
Keep your API tokens secure and never expose them in client-side code or public repositories.

Getting Your API Token

You can generate and manage your API tokens from your dashboard:
  1. Go to https://uncash.io/dashboard/developer
  2. Click “Create New Token”
  3. Give your token a descriptive name
  4. Copy the token immediately (it won’t be shown again)

Making Authenticated Requests

curl -X GET https://api.uncash.io/api/v1/health \
  -H "Authorization: Bearer uc_your_api_token_here"

Error Responses

If authentication fails, you’ll receive a 401 error:
{
  "success": false,
  "message": "Unauthorized",
  "error": "Invalid or missing API token"
}