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

# Authentication

> Authenticate Procuros API requests with an API token sent as a bearer token in the Authorization header, test your connection, and use HTTPS only.

The Procuros API uses API tokens to authenticate requests. Please contact `[email protected]` to request an API token.

In order to perform an authenticated request, use the `Authorization` header to provide your API token as a "bearer token" like this: `Authorization: Bearer <YOUR-API-TOKEN>`.

All requests to all endpoints of our API have to be made using the above authentication method. Unauthenticated calls will fail with a `401` status code.

## Testing your Connection

Below are examples of how to ping the API to ensure your credentials are correct.

If you get a successful response from the enpoint, your authorization is confirmed. If you receive a `401 Unauthorized` error then your API key is not correct for this environment.

```bash bash theme={null}
curl --request GET \
     --url 'https://api.procuros.io/v2/ping' \
     --header 'Accept: application/json' \
     --header 'Authorization: Bearer <YOUR-API-TOKEN>'
```

```php php theme={null}
$client = new \GuzzleHttp\Client();
$client->request('POST', 'https://api.procuros.io/v2/ping', [
  'headers' => [
     'Accept' => 'application/json',
     'Authorization' => 'Bearer <YOUR-API-TOKEN>'
  ]
]);

$response->getStatusCode(); // => 200
```

## SSL Encryption

Requests to the Procuros API can only be made over HTTPS. Unsecured requests using HTTP will fail.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.