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

# Introduction

> Learn how to integrate with the PERSCOM API.

The PERSCOM API provides programmatic access to your personnel data, enabling integration with third-party services and custom applications.

## Getting Started

Jumpstart your integration using our official Postman collection.

<a href="https://app.getpostman.com/run-collection/7901103-9c9e8242-21b0-47ef-ba7b-7c712162c256?action=collection%2Ffork&source=rip_markdown&collection-url=entityId%3D7901103-9c9e8242-21b0-47ef-ba7b-7c712162c256%26entityType%3Dcollection%26workspaceId%3D1f6492d8-21a2-4e2f-b2a8-55c55f80e062" target="_blank">
  <img noZoom src="https://run.pstmn.io/button.svg" alt="Run in Postman" />
</a>

<Card title="OpenAPI Specification" icon="code" href="https://api.perscom.io/spec.json">
  View the PERSCOM API OpenAPI specification file.
</Card>

## Base URL

All API requests use the following base URL:

```
https://api.perscom.io/{version}
```

Replace `{version}` with the API version. The current version is `v2`.

## Request Format

The PERSCOM API uses a RESTful interface. Requests require:

* An HTTP method: `GET`, `POST`, `PUT`, `PATCH`, or `DELETE`
* An API key passed as a Bearer token in the `Authorization` header
* The `Accept: application/json` header

## Authentication

API requests require authentication via an API key. Pass your key as a Bearer token in the `Authorization` header:

```
Authorization: Bearer YOUR_API_KEY
```

Manage your API keys in the PERSCOM dashboard under **Integrations** > **API Keys**.

For more details, see [Authentication](/api-reference/authentication).

## Caching

The PERSCOM API uses a worldwide CDN to deliver fast responses. When you update data through the dashboard, the cache refreshes automatically.

If you encounter stale data, you can purge the cache from the **Integrations** > **API Keys** section in your dashboard.

## Examples

<CodeGroup>
  ```php PHP theme={"system"}
  use GuzzleHttp\Client;

  $client = new Client();

  $headers = [
      'Accept' => 'application/json',
      'Authorization' => "Bearer {$apiKey}"
  ];

  $response = $client->request('GET', 'https://api.perscom.io/v2/users', [
      'headers' => $headers
  ]);

  echo 'Status code: ' . $response->getStatusCode();
  ```

  ```js JavaScript theme={"system"}
  fetch('https://api.perscom.io/v2/users', {
    method: 'GET',
    headers: {
      Authorization: 'Bearer YOUR_API_KEY',
      Accept: 'application/json'
    }
  })
    .then((response) => {
      console.log('Status code:', response.status)
    })
    .catch((error) => {
      console.error('Error:', error)
    })
  ```

  ```python Python theme={"system"}
  import requests

  url = 'https://api.perscom.io/v2/users'
  headers = {
      'Authorization': 'Bearer YOUR_API_KEY',
      'Accept': 'application/json',
  }
  response = requests.get(url, headers=headers)

  print(f'Status code: {response.status_code}')
  print(f'Response body: {response.text}')
  ```
</CodeGroup>
