YugabyteDB HA API

The HA API from YugabyteDB — 3 operation(s) for ha.

Operations 5

GET /api/v1/settings/ha/config Get high availability config #
POST /api/v1/settings/ha/config Create high availability config #
DELETE /api/v1/settings/ha/config/{cUUID} #
PUT /api/v1/settings/ha/config/{cUUID} #
GET /api/v1/settings/ha/generate_key Generate cluster key #

Documentation

Specifications

Other Resources

🔗
CLI
https://github.com/yugabyte/ybm-cli
🔗
Integrations
https://github.com/yugabyte/terraform-provider-ybm
🔗
TermsOfService
https://www.yugabyte.com/yugabytedb-managed-service-terms/
🔗
SDKs
https://github.com/yugabyte/platform-go-client
🔗
Integrations
https://github.com/yugabyte/terraform-provider-yba
🔗
Integrations
https://github.com/yugabyte/yugabyte-k8s-operator
🔗
KubernetesCRD
https://raw.githubusercontent.com/api-evangelist/yugabytedb/refs/heads/main/crd/yugabytedb-ybuniverse.yaml
🔗
KubernetesCRD
https://raw.githubusercontent.com/api-evangelist/yugabytedb/refs/heads/main/crd/yugabytedb-backup.yaml
🔗
KubernetesCRD
https://raw.githubusercontent.com/api-evangelist/yugabytedb/refs/heads/main/crd/yugabytedb-backup-schedule.yaml
🔗
KubernetesCRD
https://raw.githubusercontent.com/api-evangelist/yugabytedb/refs/heads/main/crd/yugabytedb-restore-job.yaml
🔗
KubernetesCRD
https://raw.githubusercontent.com/api-evangelist/yugabytedb/refs/heads/main/crd/yugabytedb-storage-config.yaml
🔗
KubernetesCRD
https://raw.githubusercontent.com/api-evangelist/yugabytedb/refs/heads/main/crd/yugabytedb-dr-config.yaml
🔗
KubernetesCRD
https://raw.githubusercontent.com/api-evangelist/yugabytedb/refs/heads/main/crd/yugabytedb-pitr-config.yaml
🔗
KubernetesCRD
https://raw.githubusercontent.com/api-evangelist/yugabytedb/refs/heads/main/crd/yugabytedb-release.yaml
🔗
KubernetesCRD
https://raw.githubusercontent.com/api-evangelist/yugabytedb/refs/heads/main/crd/yugabytedb-support-bundle.yaml
🔗
KubernetesCRD
https://raw.githubusercontent.com/api-evangelist/yugabytedb/refs/heads/main/crd/yugabytedb-ybcertificate.yaml
🔗
KubernetesCRD
https://raw.githubusercontent.com/api-evangelist/yugabytedb/refs/heads/main/crd/yugabytedb-ybprovider.yaml
🔗
KubernetesCRD
https://raw.githubusercontent.com/api-evangelist/yugabytedb/refs/heads/main/crd/yugabytedb-ybplatform.yaml

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/yugabytedb-ha-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Discovery needs no key. Ratings and market analysis are Pro.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

yugabytedb-ha-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  title: Yugabytedb HA API
  version: v1
  contact:
    name: https://docs.yugabyte.com
  license:
    name: Polyform Free Trial License 1.0.0
    url: https://github.com/yugabyte/yugabyte-db/blob/master/licenses/POLYFORM-FREE-TRIAL-LICENSE-1.0.0.txt
  termsOfService: TODO(chirag)
  x-refined-note:
  - x-source differs across the merged source definitions and was not carried
  - x-split-from differs across the merged source definitions and was not carried
  description: 'Operations tagged HA across 3 of this provider''s published API definitions: openapi_2.yaml, yugabytedb-anywhere-v1-full.yaml, yugabytedb-anywhere-v1-high-availability.yaml. Each path carries the servers of the definition it was published in.'
servers:
- url: /
tags:
- name: HA
paths:
  /api/v1/settings/ha/config:
    get:
      operationId: getHAConfig
      responses:
        '200':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HAConfigGetResp'
          description: successful operation
      security:
      - apiKeyAuth: []
      summary: Get high availability config
      tags:
      - HA
    post:
      description: Available since YBA version 2.20.0.
      operationId: createHAConfig
      parameters:
      - in: query
        name: request
        schema: {}
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/HAConfigFormData'
        required: true
      responses:
        '200':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HighAvailabilityConfig'
          description: successful operation
      security:
      - apiKeyAuth: []
      summary: Create high availability config
      tags:
      - HA
      x-codegen-request-body-name: HAConfigFormRequest
    servers:
    - url: /
  /api/v1/settings/ha/config/{cUUID}:
    delete:
      operationId: deleteHAConfig
      parameters:
      - in: path
        name: cUUID
        required: true
        schema:
          format: uuid
          type: string
      - in: query
        name: request
        schema: {}
      responses:
        default:
          content: {}
          description: successful operation
      security:
      - apiKeyAuth: []
      tags:
      - HA
    put:
      operationId: editHAConfig
      parameters:
      - in: path
        name: cUUID
        required: true
        schema:
          format: uuid
          type: string
      - in: query
        name: request
        schema: {}
      responses:
        default:
          content: {}
          description: successful operation
      security:
      - apiKeyAuth: []
      tags:
      - HA
    servers:
    - url: /
  /api/v1/settings/ha/generate_key:
    get:
      description: Available since YBA version 2.20.0.
      operationId: generateClusterKey
      responses:
        default:
          content: {}
          description: successful operation
      security:
      - apiKeyAuth: []
      summary: Generate cluster key
      tags:
      - HA
    servers:
    - url: /
components:
  schemas:
    PlatformInstance:
      example:
        address: address
        config_uuid: 046b6c7f-0b8a-43b9-b35d-6489e6daee91
        instance_state: Awaiting Connection to Replicas
        ybaVersion: ybaVersion
        state: LEADER
        is_local: true
        uuid: 046b6c7f-0b8a-43b9-b35d-6489e6daee91
        is_leader: true
        last_backup: 2022-12-12 13:07:18+00:00
      properties:
        address:
          type: string
        config_uuid:
          format: uuid
          type: string
        instance_state:
          enum:
          - Awaiting Connection to Replicas
          - Connected
          - Disconnected
          type: string
        is_leader:
          type: boolean
        is_local:
          type: boolean
        last_backup:
          description: Last backup time
          example: 2022-12-12 13:07:18+00:00
          format: date-time
          type: string
        state:
          enum:
          - LEADER
          - STAND_BY
          type: string
        uuid:
          format: uuid
          type: string
        ybaVersion:
          type: string
      required:
      - address
      - instance_state
      - is_leader
      - state
      - uuid
      - ybaVersion
      type: object
    HAConfigGetResp:
      description: HA config response
      example:
        cluster_key: cluster_key
        instances:
        - address: address
          config_uuid: 046b6c7f-0b8a-43b9-b35d-6489e6daee91
          instance_state: Awaiting Connection to Replicas
          ybaVersion: ybaVersion
          state: LEADER
          is_local: true
          uuid: 046b6c7f-0b8a-43b9-b35d-6489e6daee91
          is_leader: true
          last_backup: 2022-12-12 13:07:18+00:00
        - address: address
          config_uuid: 046b6c7f-0b8a-43b9-b35d-6489e6daee91
          instance_state: Awaiting Connection to Replicas
          ybaVersion: ybaVersion
          state: LEADER
          is_local: true
          uuid: 046b6c7f-0b8a-43b9-b35d-6489e6daee91
          is_leader: true
          last_backup: 2022-12-12 13:07:18+00:00
        accept_any_certificate: true
        global_state: Unknown
        last_failover: 2022-12-12 13:07:18+00:00
        uuid: 046b6c7f-0b8a-43b9-b35d-6489e6daee91
      properties:
        accept_any_certificate:
          description: HA accepts any certificate
          readOnly: true
          type: boolean
        cluster_key:
          description: HA config cluster key
          readOnly: true
          type: string
        global_state:
          description: HA config global state
          enum:
          - Unknown
          - NoReplicas
          - AwaitingReplicas
          - Operational
          - Error
          - Warning
          - StandbyConnected
          - StandbyDisconnected
          readOnly: true
          type: string
        instances:
          description: HA config platform instances
          items:
            $ref: '#/components/schemas/PlatformInstance'
          type: array
        last_failover:
          description: HA last failover
          example: 2022-12-12 13:07:18+00:00
          format: date-time
          readOnly: true
          type: string
        uuid:
          description: HA config UUID
          format: uuid
          type: string
      type: object
    HighAvailabilityConfig:
      example:
        cluster_key: cluster_key
        instances:
        - address: address
          config_uuid: 046b6c7f-0b8a-43b9-b35d-6489e6daee91
          instance_state: Awaiting Connection to Replicas
          ybaVersion: ybaVersion
          state: LEADER
          is_local: true
          uuid: 046b6c7f-0b8a-43b9-b35d-6489e6daee91
          is_leader: true
          last_backup: 2022-12-12 13:07:18+00:00
        - address: address
          config_uuid: 046b6c7f-0b8a-43b9-b35d-6489e6daee91
          instance_state: Awaiting Connection to Replicas
          ybaVersion: ybaVersion
          state: LEADER
          is_local: true
          uuid: 046b6c7f-0b8a-43b9-b35d-6489e6daee91
          is_leader: true
          last_backup: 2022-12-12 13:07:18+00:00
        accept_any_certificate: true
        last_failover: 2022-12-12 13:07:18+00:00
        uuid: 046b6c7f-0b8a-43b9-b35d-6489e6daee91
      properties:
        accept_any_certificate:
          type: boolean
        cluster_key:
          type: string
        instances:
          items:
            $ref: '#/components/schemas/PlatformInstance'
          type: array
        last_failover:
          description: HA last failover
          example: 2022-12-12 13:07:18+00:00
          format: date-time
          type: string
        uuid:
          format: uuid
          type: string
      required:
      - instances
      - uuid
      type: object
    HAConfigFormData:
      example:
        cluster_key: cluster_key
        accept_any_certificate: true
      properties:
        accept_any_certificate:
          type: boolean
        cluster_key:
          type: string
      required:
      - accept_any_certificate
      - cluster_key
      type: object
    PlatformInstance_2:
      example:
        address: address
        config_uuid: 046b6c7f-0b8a-43b9-b35d-6489e6daee91
        instance_state: Awaiting Connection to Replicas
        ybaVersion: ybaVersion
        state: LEADER
        is_local: true
        uuid: 046b6c7f-0b8a-43b9-b35d-6489e6daee91
        is_leader: true
        last_backup: 2022-12-12 13:07:18+00:00
      properties:
        address:
          type: string
          example: example-address
        config_uuid:
          format: uuid
          type: string
          example: 046b6c7f-0b8a-43b9-b35d-6489e6daee91
        instance_state:
          enum:
          - Awaiting Connection to Replicas
          - Connected
          - Disconnected
          type: string
          example: Awaiting Connection to Replicas
        is_leader:
          type: boolean
          example: true
        is_local:
          type: boolean
          example: true
        last_backup:
          description: Last backup time
          example: 2022-12-12 13:07:18+00:00
          format: date-time
          type: string
        state:
          enum:
          - LEADER
          - STAND_BY
          type: string
          example: LEADER
        uuid:
          format: uuid
          type: string
          example: 046b6c7f-0b8a-43b9-b35d-6489e6daee91
        ybaVersion:
          type: string
          example: 2.20.0.0
      required:
      - address
      - instance_state
      - is_leader
      - state
      - uuid
      - ybaVersion
      type: object
    HAConfigGetResp_2:
      description: HA config response
      example:
        cluster_key: cluster_key
        instances:
        - address: address
          config_uuid: 046b6c7f-0b8a-43b9-b35d-6489e6daee91
          instance_state: Awaiting Connection to Replicas
          ybaVersion: ybaVersion
          state: LEADER
          is_local: true
          uuid: 046b6c7f-0b8a-43b9-b35d-6489e6daee91
          is_leader: true
          last_backup: 2022-12-12 13:07:18+00:00
        - address: address
          config_uuid: 046b6c7f-0b8a-43b9-b35d-6489e6daee91
          instance_state: Awaiting Connection to Replicas
          ybaVersion: ybaVersion
          state: LEADER
          is_local: true
          uuid: 046b6c7f-0b8a-43b9-b35d-6489e6daee91
          is_leader: true
          last_backup: 2022-12-12 13:07:18+00:00
        accept_any_certificate: true
        global_state: Unknown
        last_failover: 2022-12-12 13:07:18+00:00
        uuid: 046b6c7f-0b8a-43b9-b35d-6489e6daee91
      properties:
        accept_any_certificate:
          description: HA accepts any certificate
          readOnly: true
          type: boolean
          example: true
        cluster_key:
          description: HA config cluster key
          readOnly: true
          type: string
          example: example-key
        global_state:
          description: HA config global state
          enum:
          - Unknown
          - NoReplicas
          - AwaitingReplicas
          - Operational
          - Error
          - Warning
          - StandbyConnected
          - StandbyDisconnected
          readOnly: true
          type: string
          example: Unknown
        instances:
          description: HA config platform instances
          items:
            $ref: '#/components/schemas/PlatformInstance_2'
          type: array
          example:
          - address: address
            config_uuid: 046b6c7f-0b8a-43b9-b35d-6489e6daee91
            instance_state: Awaiting Connection to Replicas
            ybaVersion: ybaVersion
            state: LEADER
            is_local: true
            uuid: 046b6c7f-0b8a-43b9-b35d-6489e6daee91
            is_leader: true
            last_backup: '2022-12-12T13:07:18+00:00'
        last_failover:
          description: HA last failover
          example: 2022-12-12 13:07:18+00:00
          format: date-time
          readOnly: true
          type: string
        uuid:
          description: HA config UUID
          format: uuid
          type: string
          example: 046b6c7f-0b8a-43b9-b35d-6489e6daee91
      type: object
    HighAvailabilityConfig_2:
      example:
        cluster_key: cluster_key
        instances:
        - address: address
          config_uuid: 046b6c7f-0b8a-43b9-b35d-6489e6daee91
          instance_state: Awaiting Connection to Replicas
          ybaVersion: ybaVersion
          state: LEADER
          is_local: true
          uuid: 046b6c7f-0b8a-43b9-b35d-6489e6daee91
          is_leader: true
          last_backup: 2022-12-12 13:07:18+00:00
        - address: address
          config_uuid: 046b6c7f-0b8a-43b9-b35d-6489e6daee91
          instance_state: Awaiting Connection to Replicas
          ybaVersion: ybaVersion
          state: LEADER
          is_local: true
          uuid: 046b6c7f-0b8a-43b9-b35d-6489e6daee91
          is_leader: true
          last_backup: 2022-12-12 13:07:18+00:00
        accept_any_certificate: true
        last_failover: 2022-12-12 13:07:18+00:00
        uuid: 046b6c7f-0b8a-43b9-b35d-6489e6daee91
      properties:
        accept_any_certificate:
          type: boolean
          example: true
        cluster_key:
          type: string
          example: example-key
        instances:
          items:
            $ref: '#/components/schemas/PlatformInstance_2'
          type: array
          example:
          - address: address
            config_uuid: 046b6c7f-0b8a-43b9-b35d-6489e6daee91
            instance_state: Awaiting Connection to Replicas
            ybaVersion: ybaVersion
            state: LEADER
            is_local: true
            uuid: 046b6c7f-0b8a-43b9-b35d-6489e6daee91
            is_leader: true
            last_backup: '2022-12-12T13:07:18+00:00'
        last_failover:
          description: HA last failover
          example: 2022-12-12 13:07:18+00:00
          format: date-time
          type: string
        uuid:
          format: uuid
          type: string
          example: 046b6c7f-0b8a-43b9-b35d-6489e6daee91
      required:
      - instances
      - uuid
      type: object
    HAConfigFormData_2:
      example:
        cluster_key: cluster_key
        accept_any_certificate: true
      properties:
        accept_any_certificate:
          type: boolean
          example: true
        cluster_key:
          type: string
          example: example-key
      required:
      - accept_any_certificate
      - cluster_key
      type: object
    PlatformInstance_3:
      example:
        address: address
        config_uuid: 046b6c7f-0b8a-43b9-b35d-6489e6daee91
        instance_state: Awaiting Connection to Replicas
        ybaVersion: ybaVersion
        state: LEADER
        is_local: true
        uuid: 046b6c7f-0b8a-43b9-b35d-6489e6daee91
        is_leader: true
        last_backup: 2022-12-12 13:07:18+00:00
      properties:
        address:
          type: string
          example: example-address
        config_uuid:
          format: uuid
          type: string
          example: 046b6c7f-0b8a-43b9-b35d-6489e6daee91
        instance_state:
          enum:
          - Awaiting Connection to Replicas
          - Connected
          - Disconnected
          type: string
          example: Awaiting Connection to Replicas
        is_leader:
          type: boolean
          example: true
        is_local:
          type: boolean
          example: true
        last_backup:
          description: Last backup time
          example: 2022-12-12 13:07:18+00:00
          format: date-time
          type: string
        state:
          enum:
          - LEADER
          - STAND_BY
          type: string
          example: LEADER
        uuid:
          format: uuid
          type: string
          example: 046b6c7f-0b8a-43b9-b35d-6489e6daee91
        ybaVersion:
          type: string
          example: 2.20.0.0
      required:
      - address
      - instance_state
      - is_leader
      - state
      - uuid
      - ybaVersion
      type: object
    HAConfigGetResp_3:
      description: HA config response
      example:
        cluster_key: cluster_key
        instances:
        - address: address
          config_uuid: 046b6c7f-0b8a-43b9-b35d-6489e6daee91
          instance_state: Awaiting Connection to Replicas
          ybaVersion: ybaVersion
          state: LEADER
          is_local: true
          uuid: 046b6c7f-0b8a-43b9-b35d-6489e6daee91
          is_leader: true
          last_backup: 2022-12-12 13:07:18+00:00
        - address: address
          config_uuid: 046b6c7f-0b8a-43b9-b35d-6489e6daee91
          instance_state: Awaiting Connection to Replicas
          ybaVersion: ybaVersion
          state: LEADER
          is_local: true
          uuid: 046b6c7f-0b8a-43b9-b35d-6489e6daee91
          is_leader: true
          last_backup: 2022-12-12 13:07:18+00:00
        accept_any_certificate: true
        global_state: Unknown
        last_failover: 2022-12-12 13:07:18+00:00
        uuid: 046b6c7f-0b8a-43b9-b35d-6489e6daee91
      properties:
        accept_any_certificate:
          description: HA accepts any certificate
          readOnly: true
          type: boolean
          example: true
        cluster_key:
          description: HA config cluster key
          readOnly: true
          type: string
          example: example-key
        global_state:
          description: HA config global state
          enum:
          - Unknown
          - NoReplicas
          - AwaitingReplicas
          - Operational
          - Error
          - Warning
          - StandbyConnected
          - StandbyDisconnected
          readOnly: true
          type: string
          example: Unknown
        instances:
          description: HA config platform instances
          items:
            $ref: '#/components/schemas/PlatformInstance_3'
          type: array
          example:
          - address: address
            config_uuid: 046b6c7f-0b8a-43b9-b35d-6489e6daee91
            instance_state: Awaiting Connection to Replicas
            ybaVersion: ybaVersion
            state: LEADER
            is_local: true
            uuid: 046b6c7f-0b8a-43b9-b35d-6489e6daee91
            is_leader: true
            last_backup: '2022-12-12T13:07:18+00:00'
        last_failover:
          description: HA last failover
          example: 2022-12-12 13:07:18+00:00
          format: date-time
          readOnly: true
          type: string
        uuid:
          description: HA config UUID
          format: uuid
          type: string
          example: 046b6c7f-0b8a-43b9-b35d-6489e6daee91
      type: object
    HighAvailabilityConfig_3:
      example:
        cluster_key: cluster_key
        instances:
        - address: address
          config_uuid: 046b6c7f-0b8a-43b9-b35d-6489e6daee91
          instance_state: Awaiting Connection to Replicas
          ybaVersion: ybaVersion
          state: LEADER
          is_local: true
          uuid: 046b6c7f-0b8a-43b9-b35d-6489e6daee91
          is_leader: true
          last_backup: 2022-12-12 13:07:18+00:00
        - address: address
          config_uuid: 046b6c7f-0b8a-43b9-b35d-6489e6daee91
          instance_state: Awaiting Connection to Replicas
          ybaVersion: ybaVersion
          state: LEADER
          is_local: true
          uuid: 046b6c7f-0b8a-43b9-b35d-6489e6daee91
          is_leader: true
          last_backup: 2022-12-12 13:07:18+00:00
        accept_any_certificate: true
        last_failover: 2022-12-12 13:07:18+00:00
        uuid: 046b6c7f-0b8a-43b9-b35d-6489e6daee91
      properties:
        accept_any_certificate:
          type: boolean
          example: true
        cluster_key:
          type: string
          example: example-key
        instances:
          items:
            $ref: '#/components/schemas/PlatformInstance_3'
          type: array
          example:
          - address: address
            config_uuid: 046b6c7f-0b8a-43b9-b35d-6489e6daee91
            instance_state: Awaiting Connection to Replicas
            ybaVersion: ybaVersion
            state: LEADER
            is_local: true
            uuid: 046b6c7f-0b8a-43b9-b35d-6489e6daee91
            is_leader: true
            last_backup: '2022-12-12T13:07:18+00:00'
        last_failover:
          description: HA last failover
          example: 2022-12-12 13:07:18+00:00
          format: date-time
          type: string
        uuid:
          format: uuid
          type: string
          example: 046b6c7f-0b8a-43b9-b35d-6489e6daee91
      required:
      - instances
      - uuid
      type: object
    HAConfigFormData_3:
      example:
        cluster_key: cluster_key
        accept_any_certificate: true
      properties:
        accept_any_certificate:
          type: boolean
          example: true
        cluster_key:
          type: string
          example: example-key
      required:
      - accept_any_certificate
      - cluster_key
      type: object
  securitySchemes:
    apiKeyAuth:
      description: API token passed as header
      in: header
      name: X-AUTH-YW-API-TOKEN
      type: apiKey
externalDocs:
  description: About YugabyteDB Anywhere
  url: https://docs.yugabyte.com/latest/yugabyte-platform/
x-refined-from:
- openapi_2.yaml
- yugabytedb-anywhere-v1-full.yaml
- yugabytedb-anywhere-v1-high-availability.yaml