> ## Documentation Index
> Fetch the complete documentation index at: https://developer.affinity.co/llms.txt
> Use this file to discover all available pages before exploring further.

# Authentication

Affinity API v2 uses API keys and **bearer authentication**.

To generate an API key, navigate to the Manage Apps Page in your Affinity Settings. You will need the
"Generate an API key" role-based permission controlled by your Affinity admin. See
[this Help Center article](https://support.affinity.co/s/article/How-to-Create-and-Manage-API-Keys)
for full instructions on API key generation, and
[this article](https://support.affinity.co/hc/en-us/articles/360015976732-Account-Level-Permissions)
for more information on role-based permissions in Affinity.

Provide your API key as your bearer authentication token to start making calls to Affinity API v2.

You can create multiple API keys and provide a name and description for each. Your API key is able to read data and
perform actions in Affinity on your behalf, so keep it safe as you would a password. To further secure an API key,
you can define an IP Allowlist to limit which IP addresses or ranges can make API calls using that key.
