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

# Update bare metal server

> Use [PATCH /v1/projects/{`project_id`}/baremetal/servers/{`server_id`}](/api-reference/cloud/bare-metal/update-bare-metal-server) instead. This route continues to work. Later, we will deprecate it and then remove it. We will tell you in advance.

Rename bare metal server or update tags



## OpenAPI

````yaml /api-reference/services_docs_mintlify_enriched/cloud_api.yaml patch /cloud/v1/bminstances/{project_id}/{region_id}/{server_id}
openapi: 3.1.0
info:
  title: Gcore OpenAPI – Cloud API
  description: >-
    This OpenAPI is an aggregated OpenAPI specification that unifies all Gcore
    products into a single file. It covers Cloud, CDN, DNS, WAAP, DDoS
    Protection, Object Storage, Streaming, and FastEdge services.
  version: 6f694ac41f91
servers:
  - url: https://api.gcore.com
security:
  - APIKey: []
tags:
  - name: Bare Metal
  - name: Basic VMs
  - name: Container as a Service
  - name: Cost Reports
  - name: DDoS Protection
  - name: Everywhere Inference
  - name: Everywhere Inference Apps
  - name: File Shares
  - name: Floating IPs
  - name: Function as a Service
  - name: GPU Bare Metal
  - name: GPU Virtual
  - name: IP Ranges
  - name: Images
  - name: Instances
  - name: Load Balancers
  - name: Logging
  - name: Managed Kubernetes
  - name: Managed PostgreSQL
  - name: Networks
  - name: Placement Groups
  - name: Ports
  - name: Pricing
  - name: Projects
  - name: Quotas
  - name: Regions
  - name: Registry
  - name: Reservations
  - name: Reserved IPs
  - name: Routers
  - name: SSH Keys
  - name: Secrets
  - name: Security Groups
  - name: Snapshot Schedules
  - name: Snapshots
  - name: Tasks
  - name: User Actions
  - name: User Role Assignments
  - name: Volumes
paths:
  /cloud/v1/bminstances/{project_id}/{region_id}/{server_id}:
    patch:
      tags:
        - Bare Metal
      summary: Update bare metal server
      description: >-
        Use [PATCH
        /v1/projects/{`project_id`}/baremetal/servers/{`server_id`}](/api-reference/cloud/bare-metal/update-bare-metal-server)
        instead. This route continues to work. Later, we will deprecate it and
        then remove it. We will tell you in advance.


        Rename bare metal server or update tags
      operationId: BMInstancesViewSet.patch
      parameters:
        - in: path
          name: project_id
          required: true
          description: Project ID
          schema:
            description: Project ID
            example: 1
            examples:
              - 1
            title: Project Id
            type: integer
        - in: path
          name: region_id
          required: true
          description: Region ID
          schema:
            description: Region ID
            example: 1
            examples:
              - 1
            title: Region Id
            type: integer
        - in: path
          name: server_id
          required: true
          description: Server ID
          schema:
            description: Server ID
            example: 024a29e-b4b7-4c91-9a46-505be123d9f8
            examples:
              - 024a29e-b4b7-4c91-9a46-505be123d9f8
            format: uuid4
            title: Server Id
            type: string
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/UpdateBareMetalServerSerializer'
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/BareMetalServerSerializer'
        '400':
          $ref: '#/components/responses/ProblemBadRequestWithLegacyKeys'
        '401':
          $ref: '#/components/responses/ProblemUnauthorizedWithLegacyKeys'
        '403':
          $ref: '#/components/responses/ProblemForbiddenWithLegacyKeys'
        '404':
          $ref: '#/components/responses/ProblemNotFoundWithLegacyKeys'
        '409':
          $ref: '#/components/responses/ProblemConflictWithLegacyKeys'
        '500':
          $ref: '#/components/responses/ProblemInternalServerErrorWithLegacyKeys'
        '503':
          $ref: '#/components/responses/ProblemServiceUnavailableWithLegacyKeys'
      x-codeSamples:
        - lang: Python
          source: |-
            import os
            from gcore import Gcore

            client = Gcore(
                api_key=os.environ.get("GCORE_API_KEY"),  # This is the default and can be omitted
            )
            baremetal_server = client.cloud.baremetal.servers.update(
                server_id="024a29e-b4b7-4c91-9a46-505be123d9f8",
                project_id=1,
                region_id=1,
            )
            print(baremetal_server.id)
        - lang: Go
          source: "package main\n\nimport (\n\t\"context\"\n\t\"fmt\"\n\n\t\"github.com/G-Core/gcore-go\"\n\t\"github.com/G-Core/gcore-go/cloud\"\n\t\"github.com/G-Core/gcore-go/option\"\n)\n\nfunc main() {\n\tclient := gcore.NewClient(\n\t\toption.WithAPIKey(\"My API Key\"),\n\t)\n\tbaremetalServer, err := client.Cloud.Baremetal.Servers.Update(\n\t\tcontext.TODO(),\n\t\t\"024a29e-b4b7-4c91-9a46-505be123d9f8\",\n\t\tcloud.BaremetalServerUpdateParams{\n\t\t\tProjectID: gcore.Int(1),\n\t\t\tRegionID:  gcore.Int(1),\n\t\t},\n\t)\n\tif err != nil {\n\t\tpanic(err.Error())\n\t}\n\tfmt.Printf(\"%+v\\n\", baremetalServer.ID)\n}\n"
components:
  schemas:
    UpdateBareMetalServerSerializer:
      properties:
        name:
          description: Name
          example: server_name
          examples:
            - server_name
          pattern: ^[a-zA-Z0-9][a-zA-Z 0-9._\-]{1,61}[a-zA-Z0-9._]$
          title: Name
          type: string
        tags:
          anyOf:
            - $ref: '#/components/schemas/UpdateTagsSerializer'
            - type: 'null'
          description: >-
            Update key-value tags using JSON Merge Patch semantics (RFC 7396).
            Provide key-value pairs to add or update tags. Set tag values to
            `null` to remove tags. Unspecified tags remain unchanged. Read-only
            tags are always preserved and cannot be modified.


            **Examples:**


            - **Add/update tags:** `{'tags': {'environment': 'production',
            'team': 'backend'}}` adds new tags or updates existing ones.

            - **Delete tags:** `{'tags': {'old_tag': null}}` removes specific
            tags.

            - **Remove all tags:** `{'tags': null}` removes all user-managed
            tags (read-only tags are preserved).

            - **Partial update:** `{'tags': {'environment': 'staging'}}` only
            updates specified tags.

            - **Mixed operations:** `{'tags': {'environment': 'production',
            'cost_center': 'engineering', 'deprecated_tag': null}}` adds/updates
            'environment' and 'cost_center' while removing 'deprecated_tag',
            preserving other existing tags.

            - **Replace all:** first delete existing tags with null values, then
            add new ones in the same request.
          examples:
            - my-tag: my-tag-value
              my-tag-to-remove: null
      title: UpdateBareMetalServerSerializer
      type: object
    BareMetalServerSerializer:
      properties:
        addresses:
          additionalProperties:
            items:
              anyOf:
                - $ref: '#/components/schemas/BareMetalFloatingAddressSerializer'
                - $ref: '#/components/schemas/BareMetalFixedAddressSerializer'
            type: array
          description: Map of `network_name` to list of addresses in that network
          title: Addresses
          type: object
        blackhole_ports:
          description: >-
            IP addresses of the instances that are blackholed by DDoS mitigation
            system
          items:
            $ref: '#/components/schemas/BlackholePortSerializer'
          title: Blackhole Ports
          type: array
        created_at:
          description: Datetime when bare metal server was created
          example: '2023-11-29T10:56:49Z'
          examples:
            - '2023-11-29T10:56:49Z'
          format: date-time
          title: Created At
          type: string
        creator_task_id:
          anyOf:
            - type: string
            - type: 'null'
          description: Task that created this entity
          title: Creator Task Id
        ddos_profile:
          anyOf:
            - $ref: '#/components/schemas/GetClientProfileSerializer'
            - type: 'null'
          description: >-
            Bare metal advanced DDoS protection profile. It is always `null` if
            query parameter `with_ddos=true` is not set.
        fixed_ip_assignments:
          description: Fixed IP assigned to instance
          items:
            $ref: '#/components/schemas/IpAssignmentsSerializer'
          title: Fixed Ip Assignments
          type: array
        flavor:
          $ref: '#/components/schemas/BareMetalFlavorSerializer'
          description: Flavor details
        id:
          description: Bare metal server ID
          example: 6c6aa80f-7836-4dc2-a2ae-125e248be476
          examples:
            - 6c6aa80f-7836-4dc2-a2ae-125e248be476
          format: uuid4
          title: Id
          type: string
        instance_isolation:
          anyOf:
            - $ref: '#/components/schemas/IsolationSerializer'
            - type: 'null'
          description: Instance isolation information
        name:
          description: Bare metal server name
          example: my-server-1
          examples:
            - my-server-1
          title: Name
          type: string
        project_id:
          description: Project ID
          example: 1
          examples:
            - 1
          title: Project Id
          type: integer
        region:
          description: Region name
          example: Luxembourg
          examples:
            - Luxembourg
          title: Region
          type: string
        region_id:
          description: Region ID
          example: 1
          examples:
            - 1
          title: Region Id
          type: integer
        ssh_key_name:
          anyOf:
            - type: string
            - type: 'null'
          description: SSH key assigned to bare metal server
          title: Ssh Key Name
        status:
          $ref: '#/components/schemas/InstanceStatus'
          description: Bare metal server status
          examples:
            - ACTIVE
        tags:
          description: >-
            List of key-value tags associated with the resource. A tag is a
            key-value pair that can be associated with a resource, enabling
            efficient filtering and grouping for better organization and
            management. Some tags are read-only and cannot be modified by the
            user. Tags are also integrated with cost reports, allowing cost data
            to be filtered based on tag keys or values.
          example:
            - key: my-tag
              read_only: false
              value: my-tag-value
          examples:
            - - key: my-tag
                read_only: false
                value: my-tag-value
          items:
            $ref: '#/components/schemas/TagSerializer'
          title: Tags
          type: array
        task_id:
          anyOf:
            - type: string
            - type: 'null'
          description: >-
            The UUID of the active task that currently holds a lock on the
            resource. This lock prevents concurrent modifications to ensure
            consistency. If `null`, the resource is not locked.
          examples:
            - null
          title: Task Id
        task_state:
          anyOf:
            - type: string
            - type: 'null'
          description: Task state
          title: Task State
        vm_state:
          $ref: '#/components/schemas/InstanceVMState'
          description: Bare metal server state
          examples:
            - active
      required:
        - id
        - name
        - created_at
        - status
        - vm_state
        - flavor
        - tags
        - addresses
        - ssh_key_name
        - creator_task_id
        - task_state
        - task_id
        - blackhole_ports
        - fixed_ip_assignments
        - instance_isolation
        - ddos_profile
        - region
        - region_id
        - project_id
      title: Bare metal server
      type: object
    UpdateTagsSerializer:
      propertyNames:
        description: >-
          Tag key. Maximum 255 characters. Cannot contain spaces, tabs,
          newlines, empty string or '=' character. Cannot contain characters
          from U+0080 to U+00FF. Trailing or leading whitespaces will be
          stripped.
        examples:
          - my-tag
        maxLength: 255
        minLength: 1
        pattern: ^[^\s=]+$
      title: UpdateTagsSerializer
      type: object
      additionalProperties:
        anyOf:
          - maxLength: 255
            minLength: 1
            pattern: ^[^ \t\n\r\f\v]([^\t\n\r\f\v]*[^ \t\n\r\f\v])?$
            type: string
          - type: 'null'
        description: >-
          Tag value. Maximum 255 characters. Cannot contain tabs, newlines,
          empty string or start/end with whitespace. Cannot contain characters
          from U+0080 to U+00FF. Trailing or leading whitespaces will be
          stripped. Set to `null` in order to delete this tag.
        examples:
          - my-tag-value
    BareMetalFloatingAddressSerializer:
      properties:
        addr:
          description: Address
          example: 10.0.0.17
          examples:
            - 10.0.0.17
          title: Addr
          type: string
        type:
          const: floating
          description: Type of the address
          example: floating
          examples:
            - floating
          title: Type
          type: string
      required:
        - type
        - addr
      title: Floating IP Address
      type: object
    BareMetalFixedAddressSerializer:
      description: IP addresses of the trunk port and its subports.
      properties:
        addr:
          description: Address
          example: 10.0.0.17
          examples:
            - 10.0.0.17
          title: Addr
          type: string
        interface_name:
          anyOf:
            - type: string
            - type: 'null'
          description: >-
            Interface name. This field will be `null` if
            `with_interfaces_name=true` is not set in the request when listing
            servers. It will also be `null` if the `interface_name` was not
            specified during server creation or when attaching the interface.
          examples:
            - my-interface
          title: Interface Name
        subnet_id:
          description: The unique identifier of the subnet associated with this address.
          example: ba83aec4-7bc1-4979-b934-a11fc1d36cf3
          examples:
            - ba83aec4-7bc1-4979-b934-a11fc1d36cf3
          title: Subnet Id
          type: string
        subnet_name:
          description: The name of the subnet associated with this address.
          example: my-subnet
          examples:
            - my-subnet
          title: Subnet Name
          type: string
        type:
          const: fixed
          description: Type of the address
          example: fixed
          examples:
            - fixed
          title: Type
          type: string
      required:
        - type
        - addr
        - interface_name
        - subnet_name
        - subnet_id
      title: Fixed IP Address
      type: object
    BlackholePortSerializer:
      properties:
        AlarmEnd:
          description: >-
            A date-time string giving the time that the alarm ended. If not yet
            ended, time will be given as 0001-01-01T00:00:00Z
          example: '2025-02-05 12:04:30'
          examples:
            - '2025-02-05 12:04:30'
          format: date-time
          title: Alarmend
          type: string
        AlarmStart:
          description: A date-time string giving the time that the alarm started
          example: '2025-02-05 12:04:11'
          examples:
            - '2025-02-05 12:04:11'
          format: date-time
          title: Alarmstart
          type: string
        AlarmState:
          $ref: '#/components/schemas/BlackholePortAlarmState'
          description: Current state of alarm
          examples:
            - alarm
        AlertDuration:
          description: Total alert duration
          example: 2 hours
          examples:
            - 2 hours
          title: Alertduration
          type: string
        DestinationIP:
          description: Notification destination IP address
          example: 80.240.114.116
          examples:
            - 80.240.114.116
          title: Destinationip
          type: string
        ID:
          description: ''
          title: Id
          type: integer
      required:
        - ID
        - AlarmState
        - AlarmStart
        - AlarmEnd
        - AlertDuration
        - DestinationIP
      title: BlackholePortSerializer
      type: object
    GetClientProfileSerializer:
      properties:
        fields:
          description: List of configured field values for the protection profile
          items:
            $ref: '#/components/schemas/ClientProfileFieldSerializer'
          title: Fields
          type: array
        id:
          description: Unique identifier for the DDoS protection profile
          example: 0
          examples:
            - 0
          title: Id
          type: integer
        options:
          $ref: '#/components/schemas/ProfileOptionsSerializer'
          description: Configuration options controlling profile activation and BGP routing
          examples:
            - active: true
              bgp: true
        profile_template:
          anyOf:
            - $ref: '#/components/schemas/ClientProfileTemplateSerializer'
            - type: 'null'
          description: Complete template configuration data used for this profile
        profile_template_description:
          anyOf:
            - type: string
            - type: 'null'
          description: >-
            Detailed description of the protection template used for this
            profile
          examples:
            - ARK server ports. Valid port values are in range 1000-65535
          title: Profile Template Description
        protocols:
          description: List of network protocols and ports configured for protection
          example:
            - port: '80'
              protocols:
                - TCP
                - HTTP
            - port: '53'
              protocols:
                - UDP
          examples:
            - - port: '80'
                protocols:
                  - TCP
                  - HTTP
              - port: '53'
                protocols:
                  - UDP
          items:
            $ref: '#/components/schemas/ProtocolsOnPortSerializer'
          title: Protocols
          type: array
        site:
          description: Geographic site identifier where the protection is deployed
          example: ED
          examples:
            - ED
          maxLength: 50
          title: Site
          type: string
        status:
          $ref: '#/components/schemas/DdosProfileStatusSerializer'
          description: Current operational status and any error information for the profile
          examples:
            - error_description: ''
              status: Updated
      required:
        - id
        - options
        - site
        - protocols
        - status
        - profile_template_description
        - profile_template
        - fields
      title: GetClientProfileSerializer
      type: object
    IpAssignmentsSerializer:
      properties:
        external:
          description: Is network external
          title: External
          type: boolean
        ip_address:
          description: Ip address
          example: 123.123.123.1
          examples:
            - 123.123.123.1
          title: Ip Address
          type: string
        subnet_id:
          description: Interface subnet id
          example: eaafdc3c-f48b-4eb4-826f-057dfc7d6476
          examples:
            - eaafdc3c-f48b-4eb4-826f-057dfc7d6476
          title: Subnet Id
          type: string
      required:
        - subnet_id
        - ip_address
        - external
      title: IpAssignmentsSerializer
      type: object
    BareMetalFlavorSerializer:
      description: Bare metal flavor schema embedded into instance schema
      properties:
        architecture:
          description: CPU architecture
          example: x86_64
          examples:
            - x86_64
          title: Architecture
          type: string
        flavor_id:
          description: Flavor ID is the same as name
          example: g2-standard-32-64
          examples:
            - g2-standard-32-64
          title: Flavor Id
          type: string
        flavor_name:
          description: Flavor name
          example: g2-standard-32-64
          examples:
            - g2-standard-32-64
          title: Flavor Name
          type: string
        hardware_description:
          $ref: '#/components/schemas/BareMetalFlavorHardwareDescriptionSerializer'
          description: Additional hardware description
        os_type:
          description: Operating system
          example: linux
          examples:
            - linux
          title: Os Type
          type: string
        ram:
          description: RAM size in MiB
          example: 2048
          examples:
            - 2048
          title: Ram
          type: integer
        resource_class:
          description: Flavor resource class for mapping to hardware capacity
          example: bm2-hf-medium
          examples:
            - bm2-hf-medium
          title: Resource Class
          type: string
        vcpus:
          description: Virtual CPU count. For bare metal flavors, it's a physical CPU count
          example: 1
          examples:
            - 1
          title: Vcpus
          type: integer
      required:
        - flavor_id
        - flavor_name
        - vcpus
        - ram
        - hardware_description
        - os_type
        - architecture
        - resource_class
      title: Bare metal flavor
      type: object
    IsolationSerializer:
      properties:
        reason:
          anyOf:
            - type: string
            - type: 'null'
          default: null
          description: >-
            The reason of instance isolation if it is isolated from external
            internet.
          examples:
            - Suspicious activities
          title: Reason
      title: IsolationSerializer
      type: object
    InstanceStatus:
      enum:
        - ACTIVE
        - BUILD
        - DELETED
        - ERROR
        - HARD_REBOOT
        - MIGRATING
        - PASSWORD
        - PAUSED
        - REBOOT
        - REBUILD
        - RESCUE
        - RESIZE
        - REVERT_RESIZE
        - SHELVED
        - SHELVED_OFFLOADED
        - SHUTOFF
        - SOFT_DELETED
        - SUSPENDED
        - UNKNOWN
        - VERIFY_RESIZE
      title: InstanceStatus
      type: string
    TagSerializer:
      description: >-
        A tag is a key-value pair that can be associated with a resource,

        enabling efficient filtering and grouping for better organization and
        management.

        Some tags are read-only and cannot be modified by the user.

        Tags are also integrated with cost reports, allowing cost data to be
        filtered based on tag keys or values.
      properties:
        key:
          description: >-
            Tag key. Maximum 255 characters. Cannot contain spaces, tabs,
            newlines, empty string or '=' character. Cannot contain characters
            from U+0080 to U+00FF.
          example: my-tag
          examples:
            - my-tag
          title: Key
          type: string
        read_only:
          description: If true, the tag is read-only and cannot be modified by the user
          example: false
          examples:
            - false
          title: Read Only
          type: boolean
        value:
          description: >-
            Tag value. Maximum 255 characters. Cannot contain spaces, tabs,
            newlines, empty string or '=' character. Cannot contain characters
            from U+0080 to U+00FF.
          example: my-tag-value
          examples:
            - my-tag-value
          title: Value
          type: string
      required:
        - key
        - value
        - read_only
      title: TagSerializer
      type: object
    InstanceVMState:
      enum:
        - active
        - building
        - deleted
        - error
        - paused
        - rescued
        - resized
        - shelved
        - shelved_offloaded
        - soft-deleted
        - stopped
        - suspended
      title: InstanceVMState
      type: string
    ProblemWithLegacyKeys:
      additionalProperties: false
      description: >-
        The error body of an endpoint that was released before the problem body.
        The old keys stay

        next to the problem fields until the endpoint is removed.
      properties:
        context:
          anyOf:
            - $ref: '#/components/schemas/ProblemContext'
            - type: 'null'
          default: null
          description: >-
            Data for the `type`. Absent on a type without context keys, and on a
            `not-found` for an unknown URL.
        detail:
          description: The facts of this occurrence.
          title: Detail
          type: string
        errors:
          anyOf:
            - items:
                $ref: '#/components/schemas/ProblemError'
              type: array
            - type: 'null'
          default: null
          description: >-
            One item for each invalid input. Only on `validation-error`, and
            absent when no single input is wrong.
          title: Errors
        exception_class:
          deprecated: true
          description: The old name of the error. Use `type`.
          title: Exception Class
          type: string
        hint:
          description: What to do next.
          title: Hint
          type: string
        info:
          default: null
          deprecated: true
          description: Old data about the error. Use `context`.
          title: Info
        invalid_fields:
          default: null
          deprecated: true
          description: The old list of the invalid inputs. Use `errors`.
          title: Invalid Fields
        message:
          deprecated: true
          description: The old text of the error. Use `detail`.
          title: Message
          type: string
        request_id:
          description: >-
            ID of the request. The response also sends it in the `X-Request-Id`
            header. Quote it to support.
          title: Request Id
          type: string
        status:
          description: Copy of the HTTP status code.
          title: Status
          type: integer
        title:
          description: Fixed sentence for the `type`.
          title: Title
          type: string
        trace_id:
          anyOf:
            - type: string
            - type: 'null'
          description: >-
            W3C trace ID from the `traceparent` of the request. Null when the
            request has no valid `traceparent`.
          title: Trace Id
        type:
          $ref: '#/components/schemas/ProblemType'
          description: >-
            Stable error code in kebab-case, such as `not-found`. Clients branch
            on it. It is not `errors[].code`, which names what is wrong with one
            input in `snake_case`, such as `not_found`.
      required:
        - type
        - title
        - status
        - detail
        - hint
        - request_id
        - trace_id
        - exception_class
        - message
      title: ProblemWithLegacyKeys
      type: object
    BlackholePortAlarmState:
      enum:
        - ALARM
        - CLEAR
        - MANUAL_CLEAR
        - MANUAL_START
      title: BlackholePortAlarmState
      type: string
    ClientProfileFieldSerializer:
      properties:
        base_field:
          description: ID of DDoS profile field
          example: 10
          examples:
            - 10
          title: Base Field
          type: integer
        default:
          anyOf:
            - maxLength: 100
              type: string
            - type: 'null'
          description: Predefined default value for the field if not specified
          examples:
            - null
          title: Default
        description:
          anyOf:
            - maxLength: 255
              type: string
            - type: 'null'
          description: >-
            Detailed description explaining the field's purpose and usage
            guidelines
          examples:
            - ARK server ports. Valid port values are in range 1000-65535
          title: Description
        field_type:
          anyOf:
            - type: string
            - type: 'null'
          description: Data type classification of the field (e.g., string, integer, array)
          examples:
            - null
          title: Field Type
        field_value:
          description: Complex value for the DDoS profile field
          examples:
            - 45046
            - 45047
          title: Field Value
        id:
          description: Unique identifier for the DDoS protection field
          example: 11
          examples:
            - 11
          title: Id
          type: integer
        name:
          description: Human-readable name of the protection field
          example: ARK Ports
          examples:
            - ARK Ports
          maxLength: 30
          title: Name
          type: string
        required:
          anyOf:
            - type: boolean
            - type: 'null'
          description: >-
            Indicates whether this field must be provided when creating a
            protection profile
          examples:
            - true
          title: Required
        validation_schema:
          description: >-
            JSON schema defining validation rules and constraints for the field
            value
          examples:
            - items:
                maximum: 65535
                minimum: 1000
                type: integer
              minItems: 1
              type: array
          title: Validation Schema
      required:
        - id
        - name
        - description
        - field_type
        - required
        - default
        - validation_schema
        - field_value
        - base_field
      title: ClientProfileFieldSerializer
      type: object
    ProfileOptionsSerializer:
      properties:
        active:
          description: >-
            Controls whether the DDoS protection profile is enabled and actively
            protecting the resource
          example: true
          examples:
            - true
          title: Active
          type: boolean
        bgp:
          description: >-
            Enables Border Gateway Protocol (BGP) routing for DDoS protection
            traffic
          example: true
          examples:
            - true
          title: Bgp
          type: boolean
      required:
        - active
        - bgp
      title: ProfileOptionsSerializer
      type: object
    ClientProfileTemplateSerializer:
      properties:
        description:
          anyOf:
            - type: string
            - type: 'null'
          description: Detailed description explaining the template's purpose and use cases
          examples:
            - description
          title: Description
        fields:
          description: >-
            List of configurable fields that define the template's protection
            parameters
          items:
            $ref: '#/components/schemas/ClientProfileTemplateFieldSerializer'
          title: Fields
          type: array
        id:
          description: Unique identifier for the DDoS protection template
          example: 123
          examples:
            - 123
          title: Id
          type: integer
        name:
          description: Human-readable name of the protection template
          example: ICMP port
          examples:
            - ICMP port
          maxLength: 100
          title: Name
          type: string
      required:
        - id
        - name
        - description
        - fields
      title: ClientProfileTemplateSerializer
      type: object
    ProtocolsOnPortSerializer:
      properties:
        port:
          description: Network port number for which protocols are configured
          example: '80'
          examples:
            - '80'
          title: Port
          type: string
        protocols:
          description: List of network protocols enabled on the specified port
          example:
            - TCP
            - HTTP
          examples:
            - - TCP
              - HTTP
          items:
            type: string
          title: Protocols
          type: array
      required:
        - port
        - protocols
      title: ProtocolsOnPortSerializer
      type: object
    DdosProfileStatusSerializer:
      properties:
        error_description:
          description: >-
            Detailed error message describing any issues with the profile
            operation
          example: An error occured while deleting profile
          examples:
            - An error occured while deleting profile
          title: Error Description
          type: string
        status:
          description: Current operational status of the DDoS protection profile
          example: Error Deleting
          examples:
            - Error Deleting
          maxLength: 30
          minLength: 3
          title: Status
          type: string
      required:
        - status
        - error_description
      title: DdosProfileStatusSerializer
      type: object
    BareMetalFlavorHardwareDescriptionSerializer:
      properties:
        cpu:
          description: Human-readable CPU description
          example: 1x Intel Xeon 4C/8T 3.7 GHz
          examples:
            - 1x Intel Xeon 4C/8T 3.7 GHz
          title: Cpu
          type: string
        disk:
          description: Human-readable disk description
          example: 2x 250GiB SSD
          examples:
            - 2x 250GiB SSD
          title: Disk
          type: string
        license:
          description: If the flavor is licensed, this field contains the license type
          example: Windows License
          examples:
            - Windows License
          title: License
          type: string
        network:
          description: Human-readable NIC description
          example: 1x 500Mbps
          examples:
            - 1x 500Mbps
          title: Network
          type: string
        ram:
          description: Human-readable RAM description
          example: 32 GiB
          examples:
            - 32 GiB
          title: Ram
          type: string
      required:
        - cpu
        - ram
        - disk
        - license
        - network
      title: Detailed flavor hardware description of bare metal server flavor
      type: object
    ProblemContext:
      additionalProperties: false
      description: >-
        Data for the `type`. One flat object shared by all types. Each `type`
        always sends the same keys, and a key that the server cannot fill is
        `null`. The keys of each type:

        - `resource-in-use`: `blocking_resources`, `blocking_count`

        - `quota-exceeded`: `quotas`

        - `not-available`: `reason`, `region_id`, `resource_type`, `resource_id`

        - `permission-denied`: `operation`, `client_id`, `project_id`

        - `not-found`: `resource_type`, `resource_id`

        - `method-not-allowed`: `allowed_methods`

        - `resource-busy`: `resource_type`, `resource_id`, `resource_status`

        - `rate-limited`: `retry_after`

        - `service-unavailable`: `retry_after`

        The other types send no `context`, and neither does a `not-found` for an
        unknown URL.
      properties:
        allowed_methods:
          anyOf:
            - items:
                type: string
              type: array
            - type: 'null'
          default: null
          description: Methods that the endpoint supports.
          title: Allowed Methods
        blocking_count:
          anyOf:
            - type: integer
            - type: 'null'
          default: null
          description: Total number of blocking resources.
          title: Blocking Count
        blocking_resources:
          anyOf:
            - items:
                $ref: '#/components/schemas/ProblemBlockingResource'
              type: array
            - type: 'null'
          default: null
          description: At most 50 resources that block the request.
          title: Blocking Resources
        client_id:
          anyOf:
            - type: integer
            - type: 'null'
          default: null
          description: The account of the operation.
          title: Client Id
        operation:
          anyOf:
            - type: string
            - type: 'null'
          default: null
          description: Name of the operation that the credentials lack.
          title: Operation
        project_id:
          anyOf:
            - type: integer
            - type: 'null'
          default: null
          description: The project of the operation.
          title: Project Id
        quotas:
          anyOf:
            - items:
                $ref: '#/components/schemas/ProblemQuota'
              type: array
            - type: 'null'
          default: null
          description: The quotas that the request exceeds.
          title: Quotas
        reason:
          anyOf:
            - $ref: '#/components/schemas/NotAvailableReason'
            - type: 'null'
          default: null
          description: Why the resource is not available.
        region_id:
          anyOf:
            - type: integer
            - type: 'null'
          default: null
          description: The region of the error.
          title: Region Id
        resource_id:
          anyOf:
            - type: string
            - type: 'null'
          default: null
          description: ID or name of the resource.
          title: Resource Id
        resource_status:
          anyOf:
            - type: string
            - type: 'null'
          default: null
          description: Current status of the resource.
          title: Resource Status
        resource_type:
          anyOf:
            - type: string
            - type: 'null'
          default: null
          description: >-
            Type of the resource, as the permissions name it, such as
            `instances`.
          title: Resource Type
        retry_after:
          anyOf:
            - type: integer
            - type: 'null'
          default: null
          description: >-
            Seconds to wait before the next request. `null` when the server
            cannot tell.
          title: Retry After
      title: ProblemContext
      type: object
    ProblemError:
      additionalProperties: false
      description: One invalid input.
      properties:
        code:
          description: >-
            What is wrong, as a code from a fixed list, such as `missing`,
            `int_parsing` or `less_than_equal`, or one of the shared codes:
            `not_unique`, `not_found`, `mutually_exclusive`, `missing_one_of`,
            `incompatible_value`, `invalid_format`, `duplicate_item`,
            `invalid_status`. Codes are only added, never renamed or removed.
            Treat an unknown code like `value_error`.
          type: string
        ctx:
          anyOf:
            - additionalProperties: true
              type: object
            - type: 'null'
          default: null
          description: >-
            Values of the broken constraint, such as `{"le": 4096}`. Absent when
            the check has no values.
          title: Ctx
        detail:
          description: What is wrong with the input.
          title: Detail
          type: string
        loc:
          description: >-
            Path to the input. Starts with `body`, `query`, `path` or `header`.
            A query filter is the parameter, then the operator: `name[contains]`
            is `["query", "name", "contains"]`.
          items:
            anyOf:
              - type: string
              - type: integer
          title: Loc
          type: array
      required:
        - loc
        - code
        - detail
      title: ProblemError
      type: object
    ProblemType:
      enum:
        - internal-server-error
        - method-not-allowed
        - not-available
        - not-found
        - permission-denied
        - quota-exceeded
        - rate-limited
        - resource-busy
        - resource-in-use
        - service-unavailable
        - unauthorized
        - validation-error
      title: ProblemType
      type: string
    ClientProfileTemplateFieldSerializer:
      properties:
        default:
          anyOf:
            - maxLength: 100
              type: string
            - type: 'null'
          description: Predefined default value for the field if not specified
          examples:
            - null
          title: Default
        description:
          anyOf:
            - maxLength: 255
              type: string
            - type: 'null'
          description: >-
            Detailed description explaining the field's purpose and usage
            guidelines
          examples:
            - ARK server ports. Valid port values are in range 1000-65535
          title: Description
        field_type:
          anyOf:
            - type: string
            - type: 'null'
          description: Data type classification of the field (e.g., string, integer, array)
          examples:
            - null
          title: Field Type
        id:
          description: Unique identifier for the DDoS protection field
          example: 11
          examples:
            - 11
          title: Id
          type: integer
        name:
          description: Human-readable name of the protection field
          example: ARK Ports
          examples:
            - ARK Ports
          maxLength: 30
          title: Name
          type: string
        required:
          anyOf:
            - type: boolean
            - type: 'null'
          description: >-
            Indicates whether this field must be provided when creating a
            protection profile
          examples:
            - true
          title: Required
        validation_schema:
          description: >-
            JSON schema defining validation rules and constraints for the field
            value
          examples:
            - items:
                maximum: 65535
                minimum: 1000
                type: integer
              minItems: 1
              type: array
          title: Validation Schema
      required:
        - id
        - name
        - description
        - field_type
        - required
        - default
        - validation_schema
      title: ClientProfileTemplateFieldSerializer
      type: object
    ProblemBlockingResource:
      additionalProperties: false
      description: One resource that blocks the request.
      properties:
        resource_id:
          description: ID of the blocking resource.
          title: Resource Id
          type: string
        resource_name:
          anyOf:
            - type: string
            - type: 'null'
          default: null
          description: Name of the blocking resource.
          title: Resource Name
        resource_type:
          description: >-
            Type of the blocking resource, as the permissions name it, such as
            `ports`.
          title: Resource Type
          type: string
      required:
        - resource_type
        - resource_id
      title: ProblemBlockingResource
      type: object
    ProblemQuota:
      additionalProperties: false
      description: One quota that the request exceeds.
      properties:
        available:
          anyOf:
            - type: integer
            - type: number
          description: '`limit` minus `usage`.'
          title: Available
        limit:
          anyOf:
            - type: integer
            - type: number
          description: The limit of the quota.
          title: Limit
        name:
          description: Quota name, such as `vm_count`.
          title: Name
          type: string
        overflow:
          anyOf:
            - type: integer
            - type: number
          description: 'The amount above the limit: `resulting_usage` minus `limit`.'
          title: Overflow
        region_id:
          anyOf:
            - type: integer
            - type: 'null'
          description: >-
            Region of a regional quota. `null` for a global quota, or when
            unknown.
          title: Region Id
        requested:
          anyOf:
            - type: integer
            - type: number
          description: The amount that the request adds.
          title: Requested
        resulting_usage:
          anyOf:
            - type: integer
            - type: number
          description: 'The usage after the request: `usage` plus `requested`.'
          title: Resulting Usage
        scope:
          anyOf:
            - $ref: '#/components/schemas/QuotaScope'
            - type: 'null'
          description: >-
            `regional` for a quota of one region, `global` for a quota of the
            account. `null` when the server cannot tell.
        unit:
          anyOf:
            - type: string
            - type: 'null'
          description: >-
            Unit of the numbers, such as `MiB`, `GiB` or `bytes`. `null` for a
            quota that counts items.
          title: Unit
        usage:
          anyOf:
            - type: integer
            - type: number
          description: The usage before the request.
          title: Usage
      required:
        - name
        - scope
        - region_id
        - limit
        - usage
        - available
        - requested
        - resulting_usage
        - overflow
        - unit
      title: ProblemQuota
      type: object
    NotAvailableReason:
      enum:
        - account
        - balance
        - capacity
        - plan
        - region
      title: NotAvailableReason
      type: string
    QuotaScope:
      enum:
        - global
        - regional
      title: QuotaScope
      type: string
  responses:
    ProblemBadRequestWithLegacyKeys:
      description: >-
        The request cannot succeed as it is. `type` is `validation-error`,
        `resource-in-use`, `quota-exceeded` or `not-available`.
      content:
        application/problem+json:
          schema:
            $ref: '#/components/schemas/ProblemWithLegacyKeys'
      headers:
        X-Request-Id:
          $ref: '#/components/headers/RequestId'
        Content-Language:
          $ref: '#/components/headers/ContentLanguage'
    ProblemUnauthorizedWithLegacyKeys:
      description: The request has no valid credentials. `type` is `unauthorized`.
      content:
        application/problem+json:
          schema:
            $ref: '#/components/schemas/ProblemWithLegacyKeys'
      headers:
        X-Request-Id:
          $ref: '#/components/headers/RequestId'
        Content-Language:
          $ref: '#/components/headers/ContentLanguage'
    ProblemForbiddenWithLegacyKeys:
      description: >-
        The credentials do not permit the operation, or another service manages
        the resource. `type` is `permission-denied`.
      content:
        application/problem+json:
          schema:
            $ref: '#/components/schemas/ProblemWithLegacyKeys'
      headers:
        X-Request-Id:
          $ref: '#/components/headers/RequestId'
        Content-Language:
          $ref: '#/components/headers/ContentLanguage'
    ProblemNotFoundWithLegacyKeys:
      description: The resource or the URL does not exist. `type` is `not-found`.
      content:
        application/problem+json:
          schema:
            $ref: '#/components/schemas/ProblemWithLegacyKeys'
      headers:
        X-Request-Id:
          $ref: '#/components/headers/RequestId'
        Content-Language:
          $ref: '#/components/headers/ContentLanguage'
    ProblemConflictWithLegacyKeys:
      description: >-
        The resource is in a transient state. `type` is `resource-busy`. Send
        the same request again after the `Retry-After` seconds.
      content:
        application/problem+json:
          schema:
            $ref: '#/components/schemas/ProblemWithLegacyKeys'
      headers:
        X-Request-Id:
          $ref: '#/components/headers/RequestId'
        Content-Language:
          $ref: '#/components/headers/ContentLanguage'
        Retry-After:
          $ref: '#/components/headers/RetryAfter'
    ProblemInternalServerErrorWithLegacyKeys:
      description: >-
        The server cannot complete the request. `type` is
        `internal-server-error`.
      content:
        application/problem+json:
          schema:
            $ref: '#/components/schemas/ProblemWithLegacyKeys'
      headers:
        X-Request-Id:
          $ref: '#/components/headers/RequestId'
        Content-Language:
          $ref: '#/components/headers/ContentLanguage'
    ProblemServiceUnavailableWithLegacyKeys:
      description: >-
        The service is down for a known reason, such as planned maintenance.
        `type` is `service-unavailable`. A 503 without the
        `application/problem+json` media type, and every 502 and 504, comes from
        the gateway and has no problem body.
      content:
        application/problem+json:
          schema:
            $ref: '#/components/schemas/ProblemWithLegacyKeys'
      headers:
        X-Request-Id:
          $ref: '#/components/headers/RequestId'
        Content-Language:
          $ref: '#/components/headers/ContentLanguage'
  headers:
    RequestId:
      description: The ID of the request, the same as `request_id` in the body.
      schema:
        type: string
    ContentLanguage:
      description: >-
        The language of `title`, `detail`, `hint` and `errors[].detail`, from
        the `Accept-Language` of the request. Any other field is the same in
        every language.
      schema:
        type: string
        enum:
          - en
          - de
          - ru
          - az
          - zh
          - fr
          - es
          - pt
          - ko
          - ja
          - tr
    RetryAfter:
      description: >-
        The number of seconds to wait before the client sends the same request
        again.
      schema:
        type: integer
        minimum: 0
        maximum: 60
  securitySchemes:
    APIKey:
      description: >-
        API key for authentication. Make sure to include the word `apikey`,
        followed by a single space and then your token.

        Example: `apikey 1234_abcdef`
      type: apiKey
      in: header
      name: Authorization

````