> ## Documentation Index
> Fetch the complete documentation index at: https://private-7c7dfe99-postgresql-tls-support.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Get service upgrade window

> Returns the configured upgrade window for a service.

Errors:
- 401: missing, invalid, or disabled API key.
- 403: caller lacks `control-plane:service:view` on the service.
- 404: service does not exist, is not visible to the caller, or no upgrade window has been configured.

Returns the configured upgrade window for a service.

Errors:

* 401: missing, invalid, or disabled API key.
* 403: caller lacks `control-plane:service:view` on the service.
* 404: service does not exist, is not visible to the caller, or no upgrade window has been configured.


## OpenAPI

````yaml /_specs/cloud-openapi.json get /v1/organizations/{organizationId}/services/{serviceId}/upgradeWindow
openapi: 3.1.2
info:
  title: OpenAPI spec for ClickHouse Cloud
  version: '1.0'
  contact:
    name: ClickHouse Support
    url: >-
      https://clickhouse.com/docs/en/cloud/manage/openapi?referrer=openapi-910487
    email: support@clickhouse.com
servers:
  - url: https://api.clickhouse.cloud
security:
  - basicAuth: []
tags:
  - name: Organization
  - name: User management
  - name: Billing
  - name: Role Management
  - name: Service
  - name: Backup
  - name: OpenAPI
  - name: Prometheus
  - name: ClickPipes
  - name: ClickStack
  - name: Postgres
paths:
  /v1/organizations/{organizationId}/services/{serviceId}/upgradeWindow:
    get:
      tags:
        - Service
      summary: Get service upgrade window
      description: >-
        Returns the configured upgrade window for a service.


        Errors:

        - 401: missing, invalid, or disabled API key.

        - 403: caller lacks `control-plane:service:view` on the service.

        - 404: service does not exist, is not visible to the caller, or no
        upgrade window has been configured.
      operationId: upgradeWindowGet
      parameters:
        - in: path
          name: organizationId
          description: ID of the organization that owns the service.
          required: true
          schema:
            type: string
            format: uuid
        - in: path
          name: serviceId
          description: ID of the service.
          required: true
          schema:
            type: string
            format: uuid
      responses:
        '200':
          description: Successful response
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: number
                    description: HTTP status code.
                    example: 200
                  requestId:
                    type: string
                    description: Unique id assigned to every request. UUIDv4
                    format: uuid
                  result:
                    $ref: '#/components/schemas/UpgradeWindow'
        '400':
          description: >-
            The request cannot be processed due to a client error. Please verify
            your request parameters and try again.
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: number
                    description: HTTP status code.
                    example: 400
                  error:
                    type: string
                    description: Detailed error description.
                  requestId:
                    type: string
                    description: Unique id assigned to every request. UUIDv4
                    format: uuid
        '500':
          description: >-
            An internal server error has occurred. If this issue persists,
            please contact ClickHouse Cloud support for assistance.
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: integer
                    description: HTTP status code.
                    example: 500
                  error:
                    type: string
                    description: Detailed error description.
                  requestId:
                    type: string
                    description: Unique id assigned to every request. UUIDv4
                    format: uuid
components:
  schemas:
    UpgradeWindow:
      properties:
        weekday:
          description: >-
            Day of the week the upgrade window starts. 0 = Sunday, 1 = Monday,
            …, 6 = Saturday.
          type: integer
          minimum: 0
          maximum: 6
          example: 3
        startHourUtc:
          description: >-
            UTC hour when the upgrade window starts. Must be one of 0, 6, 12, or
            18.
          type: integer
          enum:
            - 0
            - 6
            - 12
            - 18
          example: 12
        duration:
          description: >-
            Length of the upgrade window in hours. Currently only a 6-hour
            window is supported.
          type: integer
          enum:
            - 6
          example: 6
      required:
        - weekday
        - startHourUtc
        - duration
  securitySchemes:
    basicAuth:
      type: http
      scheme: basic
      description: >-
        Use key ID and key secret obtained in ClickHouse Cloud console:
        https://clickhouse.com/docs/cloud/manage/openapi

````