Documentation Index
Fetch the complete documentation index at: https://trunk-4cab4936-sam-gutentag-flaky-tests-new-monitors.mintlify.app/llms.txt
Use this file to discover all available pages before exploring further.
REST API Overview
Trunk provides HTTP REST APIs for each of our features. The APIs use status codes to indicate the success or failure of requests, return JSON from all requests, and use standard HTTP response codes. All API requests must be authenticated.Available APIs
- Flaky Tests: for accessing information like quarantined tests in your repo.
- Merge API : for controlling the Trunk Merge Queue.
Authentication
Authenticate to the API with an API token using the headerx-api-token.
Finding your API token
You can find your API token in the Trunk App by navigating to Settings > Organization > General and scrolling to the API section. The API Token field displays your token. Click the eye icon to reveal the token, then the copy icon to copy it to your clipboard. Pass it in thex-api-token header on any request to Trunk’s REST APIs.
If you are an admin, a Rotate button is available next to the API Token field. Rotating immediately invalidates the previous token, so any integrations using the old token will need to be updated.
If you are not an admin, the Rotate button is disabled. Only administrators can rotate the API token.