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

# Authentication

Sohar uses the [OAuth 2.0](https://oauth.net/2/) bearer token authentication scheme. Retrieve a bearer token via the [Get Token](/api-reference/auth/get-token) endpoint. This call requires your `client_id` and `client_secret`, which an organization admin can generate from the Sohar [dashboard](https://app.soharhealth.com/settings). Your credentials determine whether requests use the [sandbox or production environment](/api-reference/api-reference/environments).

The `/oauth/token` endpoint expects a JSON body with your credentials:

```json theme={null}
{
  "client_id": "YOUR_CLIENT_ID",
  "client_secret": "YOUR_CLIENT_SECRET"
}
```

Include the token in the `Authorization` header as `Bearer <token>` when calling other APIs.


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