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

# 키 업데이트

> API Key 속성을 업데이트합니다.



## OpenAPI

````yaml /ko/_specs/cloud-openapi.json patch /v1/organizations/{organizationId}/keys/{keyId}
openapi: 3.0.1
info:
  contact:
    email: support@clickhouse.com
    name: ClickHouse Support
    url: >-
      https://clickhouse.com/docs/en/cloud/manage/openapi?referrer=openapi-299828
  title: OpenAPI spec for ClickHouse Cloud
  version: '1.0'
servers:
  - url: https://api.clickhouse.cloud
security:
  - basicAuth: []
tags:
  - name: Organization
  - name: User management
  - name: Billing
  - name: Service
  - name: Backup
  - name: OpenAPI
  - name: Prometheus
  - name: ClickPipes
paths:
  /v1/organizations/{organizationId}/keys/{keyId}:
    patch:
      tags:
        - OpenAPI
      summary: 키 업데이트
      description: API Key 속성을 업데이트합니다.
      parameters:
        - description: 키를 소유한 조직의 ID입니다.
          in: path
          name: organizationId
          required: true
          schema:
            format: uuid
            type: string
        - description: 업데이트할 키의 ID입니다.
          in: path
          name: keyId
          required: true
          schema:
            format: uuid
            type: string
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/ApiKeyPatchRequest'
      responses:
        '200':
          content:
            application/json:
              schema:
                properties:
                  requestId:
                    description: 각 요청에 할당되는 고유 ID입니다. UUIDv4
                    format: uuid
                    type: string
                  result:
                    $ref: '#/components/schemas/ApiKey'
                  status:
                    description: HTTP 상태 코드입니다.
                    example: 200
                    type: number
                type: object
          description: 성공 응답
        '400':
          content:
            application/json:
              schema:
                properties:
                  error:
                    description: 상세 오류 설명입니다.
                    type: string
                  status:
                    description: HTTP 상태 코드입니다.
                    example: 400
                    type: number
                type: object
          description: 서버가 클라이언트 오류로 간주한 문제로 인해 요청을 처리할 수 없거나 처리하지 않습니다.
components:
  schemas:
    ApiKeyPatchRequest:
      properties:
        expireAt:
          description: 키의 만료 timestamp입니다. `null`이거나 비어 있으면 키는 만료되지 않습니다. ISO-8601 형식입니다.
          format: date-time
          nullable: true
          type: string
        ipAccessList:
          description: 이 키를 사용해 API에 액세스할 수 있도록 허용된 IP 주소 목록
          items:
            $ref: '#/components/schemas/IpAccessListEntry'
          type: array
        name:
          description: 키 이름
          type: string
        roles:
          description: 키에 할당된 역할 목록입니다. 최소 1개의 요소를 포함합니다.
          items:
            enum:
              - admin
              - developer
              - query_endpoints
            type: string
          type: array
        state:
          description: '키 상태입니다: ''enabled'', ''disabled''.'
          enum:
            - enabled
            - disabled
          type: string
    ApiKey:
      properties:
        createdAt:
          description: 키가 생성된 시각입니다. ISO-8601 형식입니다.
          format: date-time
          type: string
        expireAt:
          description: 키가 만료되는 시각입니다. 값이 없거나 `null`이거나 비어 있으면 키는 만료되지 않습니다. ISO-8601 형식입니다.
          format: date-time
          nullable: true
          type: string
        id:
          description: 고유한 API Key ID입니다.
          format: uuid
          type: string
        ipAccessList:
          description: 이 키를 사용해 API에 액세스할 수 있도록 허용된 IP 주소 목록
          items:
            $ref: '#/components/schemas/IpAccessListEntry'
          type: array
        keySuffix:
          description: 키의 마지막 4자입니다.
          type: string
        name:
          description: 키 이름입니다.
          type: string
        roles:
          description: 키에 할당된 역할 목록입니다. 최소 1개의 요소를 포함합니다.
          items:
            enum:
              - admin
              - developer
              - query_endpoints
            type: string
          type: array
        state:
          description: '키 상태입니다: ''enabled'', ''disabled''.'
          enum:
            - enabled
            - disabled
          type: string
        usedAt:
          description: 키가 마지막으로 사용된 시각입니다. 값이 없으면 키는 한 번도 사용되지 않았습니다. ISO-8601 형식입니다.
          format: date-time
          type: string
    IpAccessListEntry:
      properties:
        description:
          description: 액세스를 허용할 IPv4 주소 또는 IPv4 CIDR에 대한 선택적 설명
          type: string
        source:
          description: IP 또는 CIDR
          type: string
  securitySchemes:
    basicAuth:
      description: >-
        ClickHouse Cloud 콘솔에서 발급받은 key ID와 key secret을 사용합니다:
        https://clickhouse.com/docs/cloud/manage/openapi
      scheme: basic
      type: http

````