{"files":{"SKILL.md":"---\nname: runscope-api\ndescription: \"Runscope API skill. Use when working with Runscope for account, teams, buckets. Covers 29 endpoints.\"\nversion: 1.0.0\ngenerator: lapsh\n---\n\n# Runscope API\nAPI version: 1.0.0\n\n## Auth\nOAuth2\n\n## Base URL\nhttps://api.runscope.com/\n\n## Setup\n1. Configure auth: OAuth2\n2. GET /account -- account resource\n3. POST /buckets -- create first bucket\n\n## Endpoints\n29 endpoints across 3 groups. See references/api-spec.lap for full details.\n\n### Account\n| Method | Path | Description |\n|--------|------|-------------|\n| GET | /account | Account Resource |\n\n### Teams\n| Method | Path | Description |\n|--------|------|-------------|\n| GET | /teams/{teamId}/people | Teams Resource |\n| GET | /teams/{teamId}/integrations | Team integrations list |\n| GET | /teams/{teamId}/agents | Team agents list |\n\n### Buckets\n| Method | Path | Description |\n|--------|------|-------------|\n| GET | /buckets | Returns a list of buckets. |\n| POST | /buckets | Create a new bucket |\n| GET | /buckets/{bucketKey} | Returns a single bucket resource. |\n| DELETE | /buckets/{bucketKey} | Delete a single bucket resource. |\n| GET | /buckets/{bucketKey}/messages | Retrieve a list of messages in a bucket |\n| DELETE | /buckets/{bucketKey}/messages | Clear a bucket (remove all messages). |\n| POST | /buckets/{bucketKey}/messages | Create a message |\n| GET | /buckets/{bucketKey}/errors | Retrieve a list of error messages in a bucket |\n| GET | /buckets/{bucketKey}/messages/{messageId} | Retrieve the details for a single message. |\n| GET | /buckets/{bucketKey}/tests | Returns a list of tests. |\n| POST | /buckets/{bucketKey}/tests | Create a test. |\n| GET | /buckets/{bucketKey}/tests/{testId} | Retrieve the details of a given test by ID. |\n| PUT | /buckets/{bucketKey}/tests/{testId} | Modify a test's name, description, default environment and its steps. To modify other individual properties of a test, make requests to the steps, environments, and schedules subresources of the test. |\n| DELETE | /buckets/{bucketKey}/tests/{testId} | Delete a test, including all steps, schedules, test-specific environments and results. |\n| GET | /buckets/{bucketKey}/tests/{testId}/steps | List test steps for a test. |\n| POST | /buckets/{bucketKey}/tests/{testId}/steps | Add new test step. |\n| PUT | /buckets/{bucketKey}/tests/{testId}/steps/{stepId} | Update the details of a single test step. |\n| DELETE | /buckets/{bucketKey}/tests/{testId}/steps/{stepId} | Delete a step from a test. |\n| GET | /buckets/{bucketKey}/tests/{testId}/environments | Return details of the test's environments (only those that belong to the specified test) |\n| POST | /buckets/{bucketKey}/tests/{testId}/environments | Create new test environment. |\n| PUT | /buckets/{bucketKey}/tests/{testId}/environments/{environmentId} | Update the details of a test environment. |\n| GET | /buckets/{bucketKey}/tests/{testId}/metrics | Return details of the test metrics for the specified timeframe. |\n| GET | /buckets/{bucketKey}/environments | Returns list of shared environments for a specified bucket. |\n| POST | /buckets/{bucketKey}/environments | Create new shared environment. |\n| PUT | /buckets/{bucketKey}/environments/{environmentId} | Update the details of a shared environment. |\n\n## Common Questions\nMatch user requests to endpoints in references/api-spec.lap. Key patterns:\n- \"List all account?\" -> GET /account\n- \"List all people?\" -> GET /teams/{teamId}/people\n- \"List all integrations?\" -> GET /teams/{teamId}/integrations\n- \"List all agents?\" -> GET /teams/{teamId}/agents\n- \"List all buckets?\" -> GET /buckets\n- \"Create a bucket?\" -> POST /buckets\n- \"Get bucket details?\" -> GET /buckets/{bucketKey}\n- \"Delete a bucket?\" -> DELETE /buckets/{bucketKey}\n- \"List all messages?\" -> GET /buckets/{bucketKey}/messages\n- \"Create a message?\" -> POST /buckets/{bucketKey}/messages\n- \"List all errors?\" -> GET /buckets/{bucketKey}/errors\n- \"Get message details?\" -> GET /buckets/{bucketKey}/messages/{messageId}\n- \"List all tests?\" -> GET /buckets/{bucketKey}/tests\n- \"Create a test?\" -> POST /buckets/{bucketKey}/tests\n- \"Get test details?\" -> GET /buckets/{bucketKey}/tests/{testId}\n- \"Update a test?\" -> PUT /buckets/{bucketKey}/tests/{testId}\n- \"Delete a test?\" -> DELETE /buckets/{bucketKey}/tests/{testId}\n- \"List all steps?\" -> GET /buckets/{bucketKey}/tests/{testId}/steps\n- \"Create a step?\" -> POST /buckets/{bucketKey}/tests/{testId}/steps\n- \"Update a step?\" -> PUT /buckets/{bucketKey}/tests/{testId}/steps/{stepId}\n- \"Delete a step?\" -> DELETE /buckets/{bucketKey}/tests/{testId}/steps/{stepId}\n- \"List all environments?\" -> GET /buckets/{bucketKey}/tests/{testId}/environments\n- \"Create a environment?\" -> POST /buckets/{bucketKey}/tests/{testId}/environments\n- \"Update a environment?\" -> PUT /buckets/{bucketKey}/tests/{testId}/environments/{environmentId}\n- \"List all metrics?\" -> GET /buckets/{bucketKey}/tests/{testId}/metrics\n- \"How to authenticate?\" -> See Auth section above\n\n## Response Tips\n- Check response schemas in references/api-spec.lap for field details\n- Create/update endpoints return the modified resource on success\n- Error responses include status codes and descriptions in the spec\n\n## References\n- Full spec: See references/api-spec.lap for complete endpoint details, parameter tables, and response schemas\n\n> Generated from the official API spec by [LAP](https://lap.sh)\n","references/api-spec.lap":"@lap v0.3\n# Machine-readable API spec. Each @endpoint block is one API call.\n@api Runscope API\n@base https://api.runscope.com/\n@version 1.0.0\n@auth OAuth2\n@endpoints 29\n@hint download_for_search\n@toc account(1), teams(3), buckets(25)\n\n@group account\n@endpoint GET /account\n@desc Account Resource\n@returns(200) Account owner and team information.\n\n@endgroup\n\n@group teams\n@endpoint GET /teams/{teamId}/people\n@desc Teams Resource\n@required {teamId: any # Unique identifier for team}\n@returns(200) List of people associated with the team.\n\n@endpoint GET /teams/{teamId}/integrations\n@desc Team integrations list\n@required {teamId: any # Unique identifier for team}\n@returns(200) List of integrations associated with the team.\n\n@endpoint GET /teams/{teamId}/agents\n@desc Team agents list\n@required {teamId: any # Unique identifier for team}\n@returns(200) List of the team’s currently connected agents.\n\n@endgroup\n\n@group buckets\n@endpoint GET /buckets\n@desc Returns a list of buckets.\n@returns(200) List of buckets associated with this authenticated account.\n\n@endpoint POST /buckets\n@desc Create a new bucket\n@required {NewBucket: any}\n@returns(200) Bucket details.\n\n@endpoint GET /buckets/{bucketKey}\n@desc Returns a single bucket resource.\n@required {bucketKey: any # Unique identifier for a bucket}\n@returns(200) Bucket details.\n\n@endpoint DELETE /buckets/{bucketKey}\n@desc Delete a single bucket resource.\n@required {bucketKey: any # Unique identifier for a bucket}\n@returns(204) No content with no body.\n\n@endpoint GET /buckets/{bucketKey}/messages\n@desc Retrieve a list of messages in a bucket\n@required {bucketKey: any # Unique identifier for a bucket}\n@optional {count: any # Maxiumum number of messages to return. Default 50, max 1000., since: any # Only return messages after the given Unix timestamp, before: any # Only return messages before the given Unix timestamp}\n@returns(200) List of messages in a bucket\n\n@endpoint DELETE /buckets/{bucketKey}/messages\n@desc Clear a bucket (remove all messages).\n@required {bucketKey: any # Unique identifier for a bucket}\n@returns(204) No content with no body.\n\n@endpoint POST /buckets/{bucketKey}/messages\n@desc Create a message\n@required {bucketKey: any # Unique identifier for a bucket, NewMessage: any}\n@returns(200) The response includes a list of result objects for the message(s) submitted. It will always return an array, even if only one message was created. The order of the result objects corresponds to the order of messages submitted.\n\n@endpoint GET /buckets/{bucketKey}/errors\n@desc Retrieve a list of error messages in a bucket\n@required {bucketKey: any # Unique identifier for a bucket}\n@optional {count: any # Maxiumum number of messages to return. Default 50, max 1000., since: any # Only return messages after the given Unix timestamp, before: any # Only return messages before the given Unix timestamp}\n@returns(200) List of error messages in a bucket\n\n@endpoint GET /buckets/{bucketKey}/messages/{messageId}\n@desc Retrieve the details for a single message.\n@required {bucketKey: any # Unique identifier for a bucket, messageId: any # The unique identifier for this message}\n@returns(200) List of messages in a bucket\n\n@endpoint GET /buckets/{bucketKey}/tests\n@desc Returns a list of tests.\n@required {bucketKey: any # Unique identifier for a bucket}\n@returns(200) List of tests for this bucket\n\n@endpoint POST /buckets/{bucketKey}/tests\n@desc Create a test.\n@required {bucketKey: any # Unique identifier for a bucket, NewTest: any}\n@returns(200) List of tests for this bucket\n\n@endpoint GET /buckets/{bucketKey}/tests/{testId}\n@desc Retrieve the details of a given test by ID.\n@required {bucketKey: any # Unique identifier for a bucket, testId: any # Unique identifier for a test}\n@returns(200) Returns an object with the details of the given test.\n\n@endpoint PUT /buckets/{bucketKey}/tests/{testId}\n@desc Modify a test's name, description, default environment and its steps. To modify other individual properties of a test, make requests to the steps, environments, and schedules subresources of the test.\n@required {bucketKey: any # Unique identifier for a bucket, testId: any # Unique identifier for a test}\n@returns(201) Returns 201 and the updated test's JSON description if the test is successfully updated.\n\n@endpoint DELETE /buckets/{bucketKey}/tests/{testId}\n@desc Delete a test, including all steps, schedules, test-specific environments and results.\n@required {bucketKey: any # Unique identifier for a bucket, testId: any # Unique identifier for a test}\n@returns(204) No content with no body.\n\n@endpoint GET /buckets/{bucketKey}/tests/{testId}/steps\n@desc List test steps for a test.\n@required {bucketKey: any # Unique identifier for a bucket, testId: any # Unique identifier for a test}\n@returns(200) List of test steps for a test\n\n@endpoint POST /buckets/{bucketKey}/tests/{testId}/steps\n@desc Add new test step.\n@required {bucketKey: any # Unique identifier for a bucket, testId: any # Unique identifier for a test, TestStep: any}\n@returns(201) Details of the new test step.\n@errors {400: Must send valid JSON object to create a new test step}\n\n@endpoint PUT /buckets/{bucketKey}/tests/{testId}/steps/{stepId}\n@desc Update the details of a single test step.\n@required {bucketKey: any # Unique identifier for a bucket, testId: any # Unique identifier for a test, stepId: any # Unique identifier for a test step, TestStep: any}\n@returns(200) List of test steps for a test\n@errors {400: Unable to update template '{stepId}' for test '{testId}'}\n\n@endpoint DELETE /buckets/{bucketKey}/tests/{testId}/steps/{stepId}\n@desc Delete a step from a test.\n@required {bucketKey: any # Unique identifier for a bucket, testId: any # Unique identifier for a test, stepId: any # Unique identifier for a test step}\n@returns(204) No content with no body.\n\n@endpoint GET /buckets/{bucketKey}/tests/{testId}/environments\n@desc Return details of the test's environments (only those that belong to the specified test)\n@required {bucketKey: any # Unique identifier for a bucket, testId: any # Unique identifier for a test}\n@returns(200) List of environments belonging to this test.\n\n@endpoint POST /buckets/{bucketKey}/tests/{testId}/environments\n@desc Create new test environment.\n@required {bucketKey: any # Unique identifier for a bucket, testId: any # Unique identifier for a test, NewEnvironment: map}\n@returns(201) Details of the new test environment.\n\n@endpoint PUT /buckets/{bucketKey}/tests/{testId}/environments/{environmentId}\n@desc Update the details of a test environment.\n@required {bucketKey: any # Unique identifier for a bucket, testId: any # Unique identifier for a test, environmentId: any # Unique identifier for a test environment, ModifiedEnvironment: map}\n@returns(201) Details of the modified test environment.\n\n@endpoint GET /buckets/{bucketKey}/tests/{testId}/metrics\n@desc Return details of the test metrics for the specified timeframe.\n@required {bucketKey: any # Unique identifier for a bucket, testId: any # Unique identifier for a test}\n@returns(200) List of average response times and additional performance metrics belonging to this test.\n\n@endpoint GET /buckets/{bucketKey}/environments\n@desc Returns list of shared environments for a specified bucket.\n@required {bucketKey: any # Unique identifier for a bucket}\n@returns(200) List of shared environments belonging to this bucket.\n\n@endpoint POST /buckets/{bucketKey}/environments\n@desc Create new shared environment.\n@required {bucketKey: any # Unique identifier for a bucket, NewEnvironment: map}\n@returns(201) Details of the new test environment.\n\n@endpoint PUT /buckets/{bucketKey}/environments/{environmentId}\n@desc Update the details of a shared environment.\n@required {bucketKey: any # Unique identifier for a bucket, environmentId: any # Unique identifier for a test environment, ModifiedEnvironment: map}\n@returns(201) Details of the modified test environment.\n\n@endgroup\n\n@end\n"}}