Project API key for sending traces and accessing project-scoped resources. Format: sk-lw-... (no underscore). Obtain one by creating a project via the Admin API or the LangWatch UI.
Read one test suite
Read one test suite with the scenarios filed in it, named. An id the project does not hold, and a run plan id, both answer 404 suite_not_found.
Try this endpoint
app.langwatch.ai
API key · X-Auth-Token
Kept in this tab. Cleared when you reload.
The test suite id.
The response appears below.
Request and response examples
import osimport requestsorigin = "https://app.langwatch.ai"path = "/api/v1/test-suites/<id>"api_key = os.environ["LANGWATCH_API_KEY"]headers = { "X-Auth-Token": api_key,}response = requests.get( origin + path, headers=headers,)print(response.json())const url = "https://app.langwatch.ai/api/v1/test-suites/<id>";const response = await fetch(url, { method: "GET", headers: { "X-Auth-Token": process.env.LANGWATCH_API_KEY!, },});const data = await response.json();curl --request GET \ --url 'https://app.langwatch.ai/api/v1/test-suites/<id>' \ --header "X-Auth-Token: $LANGWATCH_API_KEY"Call the LangWatch API from this project: Read one test suite.Request: GET https://app.langwatch.ai/api/v1/test-suites/<id>Reference: https://langwatch.ai/docs/api-reference/test-suites/read-one-test-suite.mdAuthentication: send the X-Auth-Token header, read from the LANGWATCH_API_KEY environment variable. Never hard-code the key.Use the HTTP client this project already uses, handle non-2xx responses, and show me the parsed result.Success
application/json · Generated from schema
{ "id": "string", "name": "string", "slug": "string", "scenarioIds": [ "string" ], "scenarioCount": 0, "fields": [ { "identifier": "string", "type": "text" } ], "evaluators": [ { "id": "string", "evaluatorId": "string", "required": false, "mappings": {} } ], "archivedAt": "string", "createdAt": "string", "updatedAt": "string", "platformUrl": "string", "scenarios": [ { "id": "string", "name": "string" } ]}Not Found
application/json · Generated from schema
{ "error": "string", "message": "string", "code": "string"}Path parameters
idstringrequiredThe test suite id.
Responses
200Success
application/json
idstringrequiredThe test suite id.
namestringrequiredThe test suite name.
slugstringrequiredThe suite's address in the platform. It is kept when the suite is renamed.
scenarioIdsstring[]requiredThe scenarios filed in this suite, in the order it shows them.
scenarioCountnumberrequiredHow many scenarios are filed in it.
fieldsobject[]The fields the test suite declares. Absent on servers that predate fields on this family.
evaluatorsobject[]The evaluators attached to the test suite. Absent on servers that predate evaluators on this family.
archivedAtstring | nullrequiredWhen the suite was archived, or null while it is active.
createdAtstringrequiredWhen the suite was created.
updatedAtstringrequiredWhen the suite was last written.
platformUrlstring (uri)requiredWhere to open this test suite in the LangWatch platform.
scenariosobject[]requiredThe active scenarios filed in this suite. An archived scenario is left out.
404Not Found
application/json
errorstringrequiredmessagestringcodestringrequired