Authentication and API keys
Authenticate Laws.Africa API requests with an API token.
Authorization: Bearer <YOUR_AUTH_TOKEN>curl -H "Authorization: Bearer <YOUR_AUTH_TOKEN>" \
https://api.laws.africa/ai/v1/knowledge-basesLast updated
Authenticate Laws.Africa API requests with an API token.
Calls to the Laws.Africa APIs must be authenticated with an API token.
Sign up for a Laws.Africa platform account at https://platform.laws.africa/.
Create or copy your API token from https://platform.laws.africa/api-keys/.
Include the token in the Authorization header for API requests.
Authorization: Bearer <YOUR_AUTH_TOKEN>For example:
curl -H "Authorization: Bearer <YOUR_AUTH_TOKEN>" \
https://api.laws.africa/ai/v1/knowledge-basesKeep your API token private. Do not commit it to source control or expose it in browser-side code.
Your API token is tied to your platform account. Your active plan and services control which Knowledge Bases, countries, localities and Content API endpoints the token can access. See manage your plan and subscription for plan, country and usage management.
If you are logged into your platform account, you can also browse some API endpoints directly in your web browser.
Last updated