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

# Rotate Password

> Rotate the database password. The old password stops working immediately.



## OpenAPI

````yaml /openapi.json post /v1/orgs/{orgId}/projects/{projectId}/databases/{databaseId}/rotate
openapi: 3.1.0
info:
  title: Korve API
  version: 0.1.0
  description: >-
    Typed control plane for deploying applications and explicitly provisioning
    their managed infrastructure.
servers:
  - url: https://api.korve.dev
security: []
paths:
  /v1/orgs/{orgId}/projects/{projectId}/databases/{databaseId}/rotate:
    post:
      tags:
        - databases
      summary: Rotate Password
      description: >-
        Rotate the database password. The old password stops working
        immediately.
      operationId: databases.rotatePassword
      parameters:
        - name: orgId
          in: path
          required: true
          schema:
            type: string
          description: The organization's id (UUID) or slug — either form is accepted.
        - name: projectId
          in: path
          required: true
          schema:
            type: string
          description: The project's id (UUID) or slug — either form is accepted.
        - name: databaseId
          in: path
          required: true
          schema:
            type: string
          description: The database's id (UUID), from databases.list.
      responses:
        '200':
          description: >-
            New credentials issued. The connection string is shown once; store
            it securely. Rotate to obtain a new one.
          content:
            application/json:
              schema:
                type: object
                properties:
                  connectionString:
                    type: string
                    description: >-
                      Full postgres:// connection string including the password.
                      Shown exactly once — it is never retrievable later.
                required:
                  - connectionString
        '404':
          description: No such database in this project.
      security:
        - apiKey: []
        - session: []
components:
  securitySchemes:
    apiKey:
      type: http
      scheme: bearer
      bearerFormat: korve_api_key
    session:
      type: apiKey
      in: cookie
      name: korve.session_token

````