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

# Check API access

> Verify that your deployment API key can reach Sutro Batch.

Configure your [deployment URL and API key](/reference/authentication) before
using this example. `SUTRO_API_URL` is the deployment origin; curl appends
`/v1` explicitly.

This read-only check verifies the request through your Sutro deployment
and the Batch service. It does not submit work or consume inference quota.

<ParamField header="Authorization" type="string" required>
  Deployment API key in the form `Key YOUR_SUTRO_API_KEY`.
</ParamField>

```bash theme={null}
curl --fail-with-body "${SUTRO_API_URL%/}/v1/try-authentication" \
  -H "Authorization: Key $SUTRO_API_KEY"
```

## Response

```json theme={null}
{"authenticated": true}
```

## Troubleshooting

If this check fails, validate the key against your deployment:

```bash theme={null}
curl --fail-with-body "${SUTRO_API_URL%/}/v1/auth/check" \
  -H "Authorization: Key $SUTRO_API_KEY"
```

`/v1/auth/check` returns `authenticated: true` and the key's principal when the
key is valid. It does not verify that Batch can accept requests. Imported keys
are also checked against their original key authority.

| Result                                                 | Next step                                                                                                                |
| ------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------ |
| `/auth/check` returns `401`                            | Check that the URL and key belong to the same deployment and that the key has not been revoked.                          |
| `/auth/check` succeeds but `/try-authentication` fails | Contact the Sutro team to check the deployment's Batch connection and account authorization.                             |
| `503`                                                  | The deployment or a required service is unavailable or not configured. Retry after the administrator resolves the issue. |
| An HTML sign-in page or redirect                       | Check the hostname and `/v1` path. If they are correct, ask your administrator to enable API access for that deployment. |

After this check succeeds, [inspect your quotas](/reference/api/get-quotas) or
[submit a Batch job](/reference/api/running-batch-inference).
