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

> ## Agent Instructions
> This is the Sevalla REST API reference. Base URL: https://api.sevalla.com/v3. Authenticate with an API key in the Authorization header as a Bearer token.
> The OpenAPI spec is at https://api.sevalla.com/v3/openapi.json. Concepts and dashboard guides are at https://docs.sevalla.com (index: https://docs.sevalla.com/llms.txt).
> To act on a Sevalla account from an AI agent, prefer the Sevalla MCP server (https://mcp.sevalla.com/mcp, see https://docs.sevalla.com/ai-agents/overview.md) or the Sevalla CLI (https://api-docs.sevalla.com/v3/cli.md).

# Get application deployment build metrics

> Retrieve the memory, CPU and network a deployment's build used, measured every 20 seconds from the start of the build until the deployment finished (or until now while it is still running), together with the build's memory and CPU limits. `out_of_memory` tells you whether the build ran out of memory, which often fails a build with an unclear error. Measurements are kept for one month: older deployments return empty series. Deployments without a build step (a Docker image or a restart) return 404.



## OpenAPI

````yaml https://api.sevalla.com/v3/openapi.json get /applications/{id}/deployments/{deployment_id}/metrics
openapi: 3.1.0
info:
  title: Sevalla API docs
  version: 1.0.0
servers:
  - url: https://api.sevalla.com/v3
security:
  - bearerAuth: []
paths:
  /applications/{id}/deployments/{deployment_id}/metrics:
    get:
      tags:
        - Applications
      summary: Get application deployment build metrics
      description: >-
        Retrieve the memory, CPU and network a deployment's build used, measured
        every 20 seconds from the start of the build until the deployment
        finished (or until now while it is still running), together with the
        build's memory and CPU limits. `out_of_memory` tells you whether the
        build ran out of memory, which often fails a build with an unclear
        error. Measurements are kept for one month: older deployments return
        empty series. Deployments without a build step (a Docker image or a
        restart) return 404.
      operationId: getApplicationDeploymentMetricsV3
      parameters:
        - schema:
            example: fb5e5168-4281-4bec-94c5-0d1584e9e657
            type: string
            format: uuid
            pattern: >-
              ^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$
          in: path
          name: id
          required: true
          description: Application identifier
        - schema:
            example: fb5e5168-4281-4bec-94c5-0d1584e9e657
            type: string
            format: uuid
            pattern: >-
              ^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$
          in: path
          name: deployment_id
          required: true
          description: Deployment identifier
      responses:
        '200':
          description: Default Response
          content:
            application/json:
              schema:
                type: object
                properties:
                  deployment_id:
                    type: string
                    description: Deployment identifier
                    example: fb5e5168-4281-4bec-94c5-0d1584e9e657
                  from:
                    type: string
                    description: >-
                      Start of the measured range: when the build started (or
                      was queued, if it has not started yet)
                    example: '2026-11-26T12:10:00.000Z'
                  to:
                    type: string
                    description: >-
                      End of the measured range: when the deployment finished,
                      or now while it is still running
                    example: '2026-11-26T12:14:00.000Z'
                  step_seconds:
                    type: integer
                    minimum: -9007199254740991
                    maximum: 9007199254740991
                    description: >-
                      Seconds between two measurements. The build container is
                      measured every 20 seconds
                    example: 20
                  out_of_memory:
                    type: boolean
                    description: >-
                      Whether the build ran out of memory: a process in the
                      build container was stopped for using more than the memory
                      limit, which often fails the build with an unclear error
                    example: false
                  memory_usage:
                    type: array
                    items:
                      type: object
                      properties:
                        time:
                          type: string
                          description: When the measurement was taken, in ISO 8601 format
                          example: '2026-11-26T12:10:20.000Z'
                        value:
                          type: number
                          description: The measured value
                          example: 1.5
                      required:
                        - time
                        - value
                      additionalProperties: false
                    description: Memory the build container used, in bytes
                  memory_limit:
                    type: array
                    items:
                      type: object
                      properties:
                        time:
                          type: string
                          description: When the measurement was taken, in ISO 8601 format
                          example: '2026-11-26T12:10:20.000Z'
                        value:
                          type: number
                          description: The measured value
                          example: 1.5
                      required:
                        - time
                        - value
                      additionalProperties: false
                    description: Memory limit of the build container, in bytes
                  cpu_usage:
                    type: array
                    items:
                      type: object
                      properties:
                        time:
                          type: string
                          description: When the measurement was taken, in ISO 8601 format
                          example: '2026-11-26T12:10:20.000Z'
                        value:
                          type: number
                          description: The measured value
                          example: 1.5
                      required:
                        - time
                        - value
                      additionalProperties: false
                    description: >-
                      CPU the build container used, in cores (1.5 means one and
                      a half CPUs)
                  cpu_limit:
                    type: array
                    items:
                      type: object
                      properties:
                        time:
                          type: string
                          description: When the measurement was taken, in ISO 8601 format
                          example: '2026-11-26T12:10:20.000Z'
                        value:
                          type: number
                          description: The measured value
                          example: 1.5
                      required:
                        - time
                        - value
                      additionalProperties: false
                    description: CPU limit of the build container, in cores
                  network_received:
                    type: array
                    items:
                      type: object
                      properties:
                        time:
                          type: string
                          description: When the measurement was taken, in ISO 8601 format
                          example: '2026-11-26T12:10:20.000Z'
                        value:
                          type: number
                          description: The measured value
                          example: 1.5
                      required:
                        - time
                        - value
                      additionalProperties: false
                    description: Network traffic the build received, in bytes per second
                  network_sent:
                    type: array
                    items:
                      type: object
                      properties:
                        time:
                          type: string
                          description: When the measurement was taken, in ISO 8601 format
                          example: '2026-11-26T12:10:20.000Z'
                        value:
                          type: number
                          description: The measured value
                          example: 1.5
                      required:
                        - time
                        - value
                      additionalProperties: false
                    description: Network traffic the build sent, in bytes per second
                required:
                  - deployment_id
                  - from
                  - to
                  - step_seconds
                  - out_of_memory
                  - memory_usage
                  - memory_limit
                  - cpu_usage
                  - cpu_limit
                  - network_received
                  - network_sent
                additionalProperties: false
        '401':
          description: Default Response
          content:
            application/json:
              schema:
                type: object
                properties:
                  message:
                    type: string
                    description: Error message
                    example: Unauthorized
                  status:
                    type: integer
                    minimum: -9007199254740991
                    maximum: 9007199254740991
                    description: HTTP status code
                    example: 401
                  data:
                    type: object
                    properties:
                      code:
                        description: Error tracking code for support reference
                        example: err-abc-123
                        type: string
                      message:
                        description: Additional error details or instructions
                        example: >-
                          If you need assistance, please contact support and
                          provide this error code.
                        type: string
                    additionalProperties: false
                required:
                  - message
                  - status
                additionalProperties: false
        '403':
          description: Default Response
          content:
            application/json:
              schema:
                type: object
                properties:
                  message:
                    type: string
                    description: Error message
                    example: >-
                      This API key is missing the <RESOURCE>:<ACTION>
                      permission. Grant it to the key or use a key that has it.
                  status:
                    type: integer
                    minimum: -9007199254740991
                    maximum: 9007199254740991
                    description: HTTP status code
                    example: 403
                  data:
                    type: object
                    properties:
                      code:
                        description: Error tracking code for support reference
                        example: err-abc-123
                        type: string
                      message:
                        description: Additional error details or instructions
                        example: >-
                          If you need assistance, please contact support and
                          provide this error code.
                        type: string
                    additionalProperties: false
                required:
                  - message
                  - status
                additionalProperties: false
        '404':
          description: Default Response
          content:
            application/json:
              schema:
                type: object
                properties:
                  message:
                    type: string
                    description: Error message
                    example: Not found
                  status:
                    type: integer
                    minimum: -9007199254740991
                    maximum: 9007199254740991
                    description: HTTP status code
                    example: 404
                  data:
                    type: object
                    properties:
                      code:
                        description: Error tracking code for support reference
                        example: err-abc-123
                        type: string
                      message:
                        description: Additional error details or instructions
                        example: >-
                          If you need assistance, please contact support and
                          provide this error code.
                        type: string
                    additionalProperties: false
                required:
                  - message
                  - status
                additionalProperties: false
        '429':
          description: Default Response
          content:
            application/json:
              schema:
                type: object
                properties:
                  message:
                    type: string
                    description: Error message
                    example: Too many requests
                  status:
                    type: integer
                    minimum: -9007199254740991
                    maximum: 9007199254740991
                    description: HTTP status code
                    example: 429
                  data:
                    type: object
                    properties:
                      code:
                        description: Error tracking code for support reference
                        example: err-abc-123
                        type: string
                      message:
                        description: Additional error details or instructions
                        example: >-
                          If you need assistance, please contact support and
                          provide this error code.
                        type: string
                    additionalProperties: false
                required:
                  - message
                  - status
                additionalProperties: false
        '500':
          description: Default Response
          content:
            application/json:
              schema:
                type: object
                properties:
                  message:
                    type: string
                    description: Error message
                    example: Internal Server Error
                  status:
                    type: integer
                    minimum: -9007199254740991
                    maximum: 9007199254740991
                    description: HTTP status code
                    example: 500
                  data:
                    type: object
                    properties:
                      code:
                        description: Error tracking code for support reference
                        example: err-abc-123
                        type: string
                      message:
                        description: Additional error details or instructions
                        example: >-
                          If you need assistance, please contact support and
                          provide this error code.
                        type: string
                    additionalProperties: false
                required:
                  - message
                  - status
                additionalProperties: false
components:
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: >-
        API key authentication. Pass your API key as a Bearer token in the
        Authorization header.

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.