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

# Scale Endpoint Replicas



## OpenAPI

````yaml openapi.json POST /endpoints/{endpoint_id}/scale
openapi: 3.1.0
info:
  title: AirCloud External API
  description: Public REST API for managing AirCloud endpoints programmatically.
  version: 1.0.0
  contact:
    name: support
    url: https://aieev.com
    email: support@aieev.cloud
servers:
  - url: https://external.aieev.cloud:5007/external/api/v1
security:
  - bearerAuth: []
tags:
  - name: Authentication
    description: Verify API key context.
  - name: Endpoints
    description: 'Manage endpoints: list, start, stop, scale, and patch.'
  - name: Replicas
    description: View live replica status.
  - name: Logs
    description: Access endpoint log files.
paths:
  /endpoints/{endpoint_id}/scale:
    post:
      tags:
        - Endpoints
      summary: Scale Endpoint Replicas
      description: >-
        Scale the number of replicas for an active endpoint. Autoscaling must be
        disabled.
      operationId: scaleEndpoint
      parameters:
        - name: endpoint_id
          in: path
          required: true
          description: Unique endpoint ID.
          schema:
            type: string
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/ScaleReplicasInput'
      responses:
        '200':
          description: Scale result.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ScaleReplicasResponse'
        '400':
          description: Endpoint is inactive or autoscaling is enabled.
components:
  schemas:
    ScaleReplicasInput:
      type: object
      required:
        - num_replicas
      properties:
        num_replicas:
          type: integer
          minimum: 1
          maximum: 100
          description: Desired number of replicas (1-100).
          example: 3
    ScaleReplicasResponse:
      type: object
      properties:
        endpoint_id:
          type: string
          description: Unique endpoint ID.
          example: 51c910f7-ecde-4c6c-88f8-d8e37ca9d598
        previous_replicas:
          type: integer
          description: Replica count before scaling.
          example: 1
        current_replicas:
          type: integer
          description: Replica count after scaling.
          example: 3
        message:
          type: string
          description: Result message.
          example: Successfully scaled from 1 to 3 replicas
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: >-
        Pass your API key as a Bearer token. Create API keys in the project
        overview.

````