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

# Post v1projects api keys rotate



## OpenAPI

````yaml /openapi/platform.json post /v1/projects/{projectId}/api-keys/{apiKeyId}/rotate
openapi: 3.1.0
info:
  title: GOL Platform API
  description: Public control-plane API for GOL developer projects and credentials.
  version: 0.1.0
servers:
  - url: http://localhost:4100
    description: Local development
security: []
tags:
  - name: system
  - name: authentication
  - name: projects
  - name: api-keys
  - name: audit
paths:
  /v1/projects/{projectId}/api-keys/{apiKeyId}/rotate:
    post:
      tags:
        - api-keys
      operationId: rotateApiKey
      parameters:
        - schema:
            format: uuid
            type: string
          in: path
          name: projectId
          required: true
        - schema:
            format: uuid
            type: string
          in: path
          name: apiKeyId
          required: true
      requestBody:
        required: true
        content:
          application/json:
            schema:
              additionalProperties: false
              type: object
              required:
                - overlapSeconds
              properties:
                overlapSeconds:
                  minimum: 0
                  maximum: 86400
                  default: 3600
                  type: integer
      responses:
        '201':
          description: Default Response
          content:
            application/json:
              schema:
                additionalProperties: false
                type: object
                required:
                  - apiKey
                  - secret
                  - previousKeyValidUntil
                properties:
                  apiKey:
                    additionalProperties: false
                    type: object
                    required:
                      - id
                      - name
                      - environment
                      - hint
                      - scopes
                      - createdAt
                      - expiresAt
                      - revokedAt
                      - lastUsedAt
                    properties:
                      id:
                        format: uuid
                        type: string
                      name:
                        type: string
                      environment:
                        anyOf:
                          - type: string
                            enum:
                              - test
                          - type: string
                            enum:
                              - live
                      hint:
                        type: string
                      scopes:
                        type: array
                        items:
                          anyOf:
                            - type: string
                              enum:
                                - project:read
                            - type: string
                              enum:
                                - accounts:read
                            - type: string
                              enum:
                                - mandates:read
                            - type: string
                              enum:
                                - mandates:write
                            - type: string
                              enum:
                                - actions:submit
                            - type: string
                              enum:
                                - webhooks:manage
                      createdAt:
                        format: date-time
                        type: string
                      expiresAt:
                        anyOf:
                          - format: date-time
                            type: string
                          - type: 'null'
                      revokedAt:
                        anyOf:
                          - format: date-time
                            type: string
                          - type: 'null'
                      lastUsedAt:
                        anyOf:
                          - format: date-time
                            type: string
                          - type: 'null'
                  secret:
                    type: string
                  previousKeyValidUntil:
                    format: date-time
                    type: string
        '400':
          description: Default Response
          content:
            application/json:
              schema:
                additionalProperties: false
                type: object
                required:
                  - error
                properties:
                  error:
                    additionalProperties: false
                    type: object
                    required:
                      - code
                      - message
                      - correlationId
                    properties:
                      code:
                        type: string
                      message:
                        type: string
                      correlationId:
                        format: uuid
                        type: string
        '401':
          description: Default Response
          content:
            application/json:
              schema:
                additionalProperties: false
                type: object
                required:
                  - error
                properties:
                  error:
                    additionalProperties: false
                    type: object
                    required:
                      - code
                      - message
                      - correlationId
                    properties:
                      code:
                        type: string
                      message:
                        type: string
                      correlationId:
                        format: uuid
                        type: string
        '403':
          description: Default Response
          content:
            application/json:
              schema:
                additionalProperties: false
                type: object
                required:
                  - error
                properties:
                  error:
                    additionalProperties: false
                    type: object
                    required:
                      - code
                      - message
                      - correlationId
                    properties:
                      code:
                        type: string
                      message:
                        type: string
                      correlationId:
                        format: uuid
                        type: string
        '404':
          description: Default Response
          content:
            application/json:
              schema:
                additionalProperties: false
                type: object
                required:
                  - error
                properties:
                  error:
                    additionalProperties: false
                    type: object
                    required:
                      - code
                      - message
                      - correlationId
                    properties:
                      code:
                        type: string
                      message:
                        type: string
                      correlationId:
                        format: uuid
                        type: string
        '409':
          description: Default Response
          content:
            application/json:
              schema:
                additionalProperties: false
                type: object
                required:
                  - error
                properties:
                  error:
                    additionalProperties: false
                    type: object
                    required:
                      - code
                      - message
                      - correlationId
                    properties:
                      code:
                        type: string
                      message:
                        type: string
                      correlationId:
                        format: uuid
                        type: string
        '429':
          description: Default Response
          content:
            application/json:
              schema:
                additionalProperties: false
                type: object
                required:
                  - error
                properties:
                  error:
                    additionalProperties: false
                    type: object
                    required:
                      - code
                      - message
                      - correlationId
                    properties:
                      code:
                        type: string
                      message:
                        type: string
                      correlationId:
                        format: uuid
                        type: string
        '500':
          description: Default Response
          content:
            application/json:
              schema:
                additionalProperties: false
                type: object
                required:
                  - error
                properties:
                  error:
                    additionalProperties: false
                    type: object
                    required:
                      - code
                      - message
                      - correlationId
                    properties:
                      code:
                        type: string
                      message:
                        type: string
                      correlationId:
                        format: uuid
                        type: string
        '503':
          description: Default Response
          content:
            application/json:
              schema:
                additionalProperties: false
                type: object
                required:
                  - error
                properties:
                  error:
                    additionalProperties: false
                    type: object
                    required:
                      - code
                      - message
                      - correlationId
                    properties:
                      code:
                        type: string
                      message:
                        type: string
                      correlationId:
                        format: uuid
                        type: string
      security:
        - bearerAuth: []
components:
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer

````