> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://docs.a1.uk.astutepayroll.in/llms.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://docs.a1.uk.astutepayroll.in/_mcp/server.

# Deel. PayAndBill API

> Get started with the Deel. PayAndBill API

Welcome to the Deel. PayAndBill API documentation. Our API allows you to access your employee and customer data to integrate with your business environment. You can also push data into PayAndBill from third-party systems.

## Base URLs

All API requests should be made to one of the following base URLs depending on your environment:

| Environment    | Base URL                              |
| -------------- | ------------------------------------- |
| **Production** | `https://api.astutepayroll.com`       |
| **Staging**    | `https://stage.api.astutepayroll.com` |

> **Warn**
>
> Use the **Staging** base URL when testing or developing your integration. Switch to **Production** only when you are ready to go live.

## Quick Start

To start using the Deel. PayAndBill API:

### Get your credentials

Register your application and obtain your `clientId` and `clientSecret`.

### Authenticate

Use the [OAuth Authorization](/api-reference/authentication/o-auth-authorization) endpoint to initiate the authorization flow, then exchange the code for an access token via the [OAuth Token](/api-reference/authentication/o-auth-token) endpoint.

### Make API requests

Include the access token as a `Bearer` token in the `Authorization` header of all subsequent requests.

```bash
curl -X GET https://api.astutepayroll.com/employees/list \
  -H "Authorization: Bearer YOUR_ACCESS_TOKEN" \
  -H "Accept: application/json"
```

## Available Resources

The API currently provides access to the following resources:

#### [Employees](/api-reference/employee/get-employees)

Create, list, search, update, and manage employee records with full pagination support.

#### [Customers](/api-reference/customer/get-customer-by-uuid)

Create, list, retrieve, and update customer records including billing groups and jobs.

#### [Companies](/api-reference/company/get-company-by-uuid)

Retrieve company records, accounts, purchase details, and invoicing configuration.

#### [Billing Groups](/api-reference/billing-group/get-billing-group-by-uuid)

Create and manage billing groups linked to customers.

#### [Holiday Groups](/api-reference/holiday-group/get-holiday-group-by-uuid)

Retrieve holiday groups configured for your tenant.

#### [GL Configuration](/api-reference/gl-configuration/get-gl-group-by-uuid)

Manage General Ledger groups and configuration.

## Headers

Most endpoints require the following headers in addition to the `Authorization` bearer token:

| Header             | Required    | Description                                     |
| ------------------ | ----------- | ----------------------------------------------- |
| `Authorization`    | Yes         | `Bearer YOUR_ACCESS_TOKEN`                      |
| `Accept`           | Recommended | `application/json`                              |
| `vnd.a1.tenant-id` | Depends     | Tenant identifier for multi-tenant environments |