openapi: 3.0.0 info: version: 0.1.0 title: E2B access-tokens auth API servers: - url: https://api.e2b.app tags: - name: auth paths: /teams: get: description: List all teams tags: - auth security: - AccessTokenAuth: [] - Supabase1TokenAuth: [] responses: '200': description: Successfully returned all teams content: application/json: schema: type: array items: allOf: - $ref: '#/components/schemas/Team' '401': $ref: '#/components/responses/401' '500': $ref: '#/components/responses/500' /teams/{teamID}/metrics: get: description: Get metrics for the team tags: - auth security: - ApiKeyAuth: [] - Supabase1TokenAuth: [] Supabase2TeamAuth: [] parameters: - $ref: '#/components/parameters/teamID' - in: query name: start schema: type: integer format: int64 minimum: 0 description: Unix timestamp for the start of the interval, in seconds, for which the metrics - in: query name: end schema: type: integer format: int64 minimum: 0 description: Unix timestamp for the end of the interval, in seconds, for which the metrics responses: '200': description: Successfully returned the team metrics content: application/json: schema: type: array items: $ref: '#/components/schemas/TeamMetric' '400': $ref: '#/components/responses/400' '401': $ref: '#/components/responses/401' '403': $ref: '#/components/responses/403' '500': $ref: '#/components/responses/500' /teams/{teamID}/metrics/max: get: description: Get the maximum metrics for the team in the given interval tags: - auth security: - ApiKeyAuth: [] - Supabase1TokenAuth: [] Supabase2TeamAuth: [] parameters: - $ref: '#/components/parameters/teamID' - in: query name: start schema: type: integer format: int64 minimum: 0 description: Unix timestamp for the start of the interval, in seconds, for which the metrics - in: query name: end schema: type: integer format: int64 minimum: 0 description: Unix timestamp for the end of the interval, in seconds, for which the metrics - in: query name: metric required: true schema: type: string enum: - concurrent_sandboxes - sandbox_start_rate description: Metric to retrieve the maximum value for responses: '200': description: Successfully returned the team metrics content: application/json: schema: $ref: '#/components/schemas/MaxTeamMetric' '400': $ref: '#/components/responses/400' '401': $ref: '#/components/responses/401' '403': $ref: '#/components/responses/403' '500': $ref: '#/components/responses/500' components: schemas: MaxTeamMetric: description: Team metric with timestamp required: - timestamp - timestampUnix - value properties: timestamp: type: string format: date-time deprecated: true description: Timestamp of the metric entry timestampUnix: type: integer format: int64 description: Timestamp of the metric entry in Unix time (seconds since epoch) value: type: number description: The maximum value of the requested metric in the given interval Team: required: - teamID - name - apiKey - isDefault properties: teamID: type: string description: Identifier of the team name: type: string description: Name of the team apiKey: type: string description: API key for the team isDefault: type: boolean description: Whether the team is the default team Error: required: - code - message properties: code: type: integer format: int32 description: Error code message: type: string description: Error TeamMetric: description: Team metric with timestamp required: - timestamp - timestampUnix - concurrentSandboxes - sandboxStartRate properties: timestamp: type: string format: date-time deprecated: true description: Timestamp of the metric entry timestampUnix: type: integer format: int64 description: Timestamp of the metric entry in Unix time (seconds since epoch) concurrentSandboxes: type: integer format: int32 description: The number of concurrent sandboxes for the team sandboxStartRate: type: number format: float description: Number of sandboxes started per second parameters: teamID: name: teamID in: path required: true schema: type: string responses: '403': description: Forbidden content: application/json: schema: $ref: '#/components/schemas/Error' '400': description: Bad request content: application/json: schema: $ref: '#/components/schemas/Error' '500': description: Server error content: application/json: schema: $ref: '#/components/schemas/Error' '401': description: Authentication error content: application/json: schema: $ref: '#/components/schemas/Error' securitySchemes: ApiKeyAuth: type: apiKey in: header name: X-API-Key AccessTokenAuth: type: http scheme: bearer bearerFormat: access_token Supabase1TokenAuth: type: apiKey in: header name: X-Supabase-Token Supabase2TeamAuth: type: apiKey in: header name: X-Supabase-Team AdminTokenAuth: type: apiKey in: header name: X-Admin-Token