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

# Create Staking Configuration

> Creates a new versioned staking configuration for the org and marks all previous versions not current.

Not available to API keys yet. It will need `grants:write`.

## OpenAPI

````yaml api-reference/openapi.json POST /tga/create-staking-configuration
openapi: 3.1.0
info:
  title: Toku API
  version: 1.0.0
servers:
  - url: https://api.toku.com
security:
  - bearerAuth: []
paths:
  /tga/create-staking-configuration:
    post:
      operationId: createStakingConfiguration
      summary: Create Staking Configuration
      description: >-
        Creates a new versioned staking configuration for the org and marks all
        previous versions not current.


        Not available to API keys yet. It will need `grants:write`.
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/CreateStakingConfigurationRequest'
      responses:
        '200':
          description: Successful response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/CreateStakingConfigurationResponse'
        '400':
          description: Bad request
        '401':
          description: Unauthorized
        '403':
          description: Forbidden
        '404':
          description: Not found
        '409':
          description: Conflict
        '429':
          description: Response 429
components:
  schemas:
    CreateStakingConfigurationRequest:
      type: object
      properties:
        maxStakePercentage:
          type: string
          pattern: ^\d+(?:\.\d+)?$
          description: >-
            NOTE(ck): a .transform() rule is not mirrored here; TGA still
            enforces it
        bufferPeriod:
          type: integer
          minimum: 0
        cooldownPeriod:
          type: integer
          minimum: 0
        stakingTypesEnabled:
          type: array
          items:
            type: string
            minLength: 1
          maxItems: 50
      required:
        - maxStakePercentage
        - bufferPeriod
        - cooldownPeriod
        - stakingTypesEnabled
    CreateStakingConfigurationResponse:
      type: object
      properties:
        stakingConfigurationID:
          type: string
        orgID:
          type: string
        maxStakePercentage:
          type: string
          pattern: ^-?\d+(?:\.\d+)?(?:e[+-]?\d+)?$
        bufferPeriod:
          type: integer
        cooldownPeriod:
          type: integer
        versionNumber:
          type: integer
        createdAt:
          type: string
        updatedAt:
          type: string
        isCurrent:
          type: boolean
        stakingTypesEnabled:
          type: array
          items:
            type: string
            enum:
              - UNVESTED_LOCKED_TOKENS
              - UNVESTED_UNLOCKED_TOKENS
              - VESTED_LOCKED_TOKENS
      required:
        - stakingConfigurationID
        - orgID
        - maxStakePercentage
        - bufferPeriod
        - cooldownPeriod
        - versionNumber
        - createdAt
        - updatedAt
        - isCurrent
        - stakingTypesEnabled
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
````
