All plans have 30% OFF For this week

Claim Discount

Authentication

Authentication

API Reference: Authentication

To access the AnswerPal API, you need to authenticate every request. AnswerPal uses HTTP Basic Authentication, allowing you to securely access API endpoints using the same credentials you use to log in to the AnswerPal dashboard.

Diagram showing an API client sending a request with Basic Authentication credentials to the AnswerPal server over HTTPS.

Authentication Overview

HTTP Basic Authentication is a simple authentication scheme built into the HTTP protocol. To authenticate, you send your AnswerPal dashboard username and password in the HTTP Authorization header of your API requests.

How to Authenticate with the AnswerPal API

  1. Obtain your AnswerPal dashboard username and password.
  2. Encode your username and password as a base64 string in the format: username:password
  3. Add an Authorization header to your API request with the value: Basic <base64-encoded string>

Authenticating an API Request

Example using Basic Authentication:

GET /api/Customers/me HTTP/1.1
Host: api.answerpal.com
Authorization: Basic ZGVtbzpwYXNzd29yZA==
Replace ZGVtbzpwYXNzd29yZA== with your own base64-encoded username:password string.

Authentication Error Handling

The API call was made without valid credentials or with an expired/invalid token. Solution: Check your Authorization header and ensure your token or credentials are correct and not expired.

The credentials are valid but lack permission to access the requested resource. Solution: Contact your admin or support to verify your access rights.

JWT tokens are time-limited. If you receive a token expiry error, re-authenticate to obtain a new token.

Security Best Practices

  • Always use HTTPS for all API requests.
  • Store API credentials and tokens securely (never in source code).
  • Rotate passwords and tokens regularly.
  • Limit permissions for each token to only what is necessary.
  • Use organization-level credentials for general access, and override only when required for specific actions or integrations.
  • Audit API access logs periodically to detect unauthorized access.
  • Never share your credentials outside your organization.

Troubleshooting Authentication

Ensure you are using the correct username and password for your AnswerPal dashboard. If you have recently changed your password, update it in your API client as well.

Check that your API requests include the Authorization header in the correct format.

Requests over HTTP (instead of HTTPS) will be rejected for security reasons.

Table of Contents

AnswerPal: AI-powered customer service solutions to elevate your support and communication effortlessly.

Contact

For all support, sales, and partnership inquiries, email us at info@answerpal.eu