> For the complete documentation index, see [llms.txt](https://docs.sypht.com/sypht/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.sypht.com/sypht/api-docs/authentication.md).

# Authentication

### OAuth2

We use an Oauth2 authentication flow. Users can create a `client_id` and `client_secret` upon signing up with Sypht. Use these to generate your reusable bearer token, which must be included in the Authorization header of each request. You can store and reuse these tokens for up to an hour.

To get a token you need to POST to the tokenUrl with the `client_id` and `grant_type` in the request body and colon separated, base64 encoded `client_id` and `client_secret` in a basic Authorization header. For example `Basic {Base64(client_id:client_secret)}`

| Security Scheme Type         | OAuth2                                                                                                                                                                                                                                                                                                                                                                                                          |
| ---------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| clientCredentials OAuth Flow | <p><strong>Token URL:</strong> <https://auth.sypht.com/oauth2/token><strong>Scopes:</strong></p><ul><li><p><code>fileupload:all</code> - </p><p>Provides access to Fileupload Service</p></li><li><p><code>result:all</code> - </p><p>Provides access to Result Service</p></li><li><p><code>validate:annotation</code> - </p><p>Upload annotation data for your documents for training purposes.</p></li></ul> |
