> For the complete documentation index, see [llms.txt](https://docs.podplay.app/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.podplay.app/api/configuration/api-keys-configuration.md).

# API Keys Configuration

API key policies and permissions.

## GET /tenants/{tenantId}/integrations/api-keys

>

```json
{"openapi":"3.0.0","info":{"title":"PodPlay Inc API","version":"2.0"},"tags":[{"name":"API Keys Configuration","description":"API key policies and permissions."}],"servers":[{"url":"/apis/v2","description":"Current Server"}],"security":[{"bearer":[]}],"components":{"securitySchemes":{"bearer":{"scheme":"bearer","bearerFormat":"JWT","type":"http"}},"schemas":{"ApiKeysConfigDto":{"type":"object","properties":{"publicKey":{"type":"string","description":"RSA public key for verifying API key authentication tokens"},"privateKey":{"type":"string","description":"RSA private key preview for signing API key authentication tokens"},"keysSource":{"type":"string","description":"Source of the keys (tenant, environment, or none)","enum":["tenant","environment","none"]},"_links":{"$ref":"#/components/schemas/LinksDto"}},"required":["publicKey","privateKey","keysSource","_links"]},"LinksDto":{"type":"object","properties":{"self":{"description":"A `LinkDto` to the resource itself","allOf":[{"$ref":"#/components/schemas/LinkDto"}]}},"required":["self"]},"LinkDto":{"type":"object","properties":{"href":{"type":"string","description":"A URL"}},"required":["href"]}}},"paths":{"/tenants/{tenantId}/integrations/api-keys":{"get":{"operationId":"ApiKeysConfigController_getConfig","parameters":[],"responses":{"200":{"description":"Returns the API Keys configuration","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ApiKeysConfigDto"}}}},"403":{"description":"Forbidden: You are not allowed to read API Keys configuration"},"404":{"description":"API Keys configuration not found"}},"tags":["API Keys Configuration"]}}}}
```

## PATCH /tenants/{tenantId}/integrations/api-keys

>

```json
{"openapi":"3.0.0","info":{"title":"PodPlay Inc API","version":"2.0"},"tags":[{"name":"API Keys Configuration","description":"API key policies and permissions."}],"servers":[{"url":"/apis/v2","description":"Current Server"}],"security":[{"bearer":[]}],"components":{"securitySchemes":{"bearer":{"scheme":"bearer","bearerFormat":"JWT","type":"http"}},"schemas":{"ApiKeysConfigPatchDto":{"type":"object","properties":{"publicKey":{"type":"string","description":"RSA public key for verifying API key authentication tokens"},"privateKey":{"type":"string","description":"RSA private key preview for signing API key authentication tokens"}}},"ApiKeysConfigDto":{"type":"object","properties":{"publicKey":{"type":"string","description":"RSA public key for verifying API key authentication tokens"},"privateKey":{"type":"string","description":"RSA private key preview for signing API key authentication tokens"},"keysSource":{"type":"string","description":"Source of the keys (tenant, environment, or none)","enum":["tenant","environment","none"]},"_links":{"$ref":"#/components/schemas/LinksDto"}},"required":["publicKey","privateKey","keysSource","_links"]},"LinksDto":{"type":"object","properties":{"self":{"description":"A `LinkDto` to the resource itself","allOf":[{"$ref":"#/components/schemas/LinkDto"}]}},"required":["self"]},"LinkDto":{"type":"object","properties":{"href":{"type":"string","description":"A URL"}},"required":["href"]}}},"paths":{"/tenants/{tenantId}/integrations/api-keys":{"patch":{"operationId":"ApiKeysConfigController_setConfig","parameters":[],"requestBody":{"required":true,"description":"The API Keys configuration to update","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ApiKeysConfigPatchDto"}}}},"responses":{"200":{"description":"Returns the updated API Keys configuration","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ApiKeysConfigDto"}}}},"403":{"description":"Forbidden: You are not allowed to update API Keys configuration"},"422":{"description":"Unprocessable Entity: Returns an `ErrorDto` in case of validation errors or failures.<br/>"}},"tags":["API Keys Configuration"]}}}}
```

## GET /tenants/{tenantId}/integrations/api-keys/status

>

```json
{"openapi":"3.0.0","info":{"title":"PodPlay Inc API","version":"2.0"},"tags":[{"name":"API Keys Configuration","description":"API key policies and permissions."}],"servers":[{"url":"/apis/v2","description":"Current Server"}],"security":[{"bearer":[]}],"components":{"securitySchemes":{"bearer":{"scheme":"bearer","bearerFormat":"JWT","type":"http"}},"schemas":{"ApiKeysConfigStatusDto":{"type":"object","properties":{"availableScenarios":{"type":"array","description":"Available scenarios based on current state","items":{"type":"string","enum":["create tenant keys","migrate to tenant keys","re-enable existing tenant keys","re-enable existing environment keys","generate fresh tenant keys"]}},"canChangeSource":{"type":"boolean","description":"Whether scenario selector should be disabled"},"keysSource":{"type":"string","description":"Current source of the keys","enum":["tenant","environment","none"]},"_links":{"$ref":"#/components/schemas/LinksDto"}},"required":["availableScenarios","canChangeSource","keysSource","_links"]},"LinksDto":{"type":"object","properties":{"self":{"description":"A `LinkDto` to the resource itself","allOf":[{"$ref":"#/components/schemas/LinkDto"}]}},"required":["self"]},"LinkDto":{"type":"object","properties":{"href":{"type":"string","description":"A URL"}},"required":["href"]}}},"paths":{"/tenants/{tenantId}/integrations/api-keys/status":{"get":{"operationId":"ApiKeysConfigController_getStatus","parameters":[],"responses":{"200":{"description":"Returns the API Keys configuration status","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ApiKeysConfigStatusDto"}}}},"403":{"description":"Forbidden: You are not allowed to read API Keys configuration status"}},"tags":["API Keys Configuration"]}}}}
```

## POST /tenants/{tenantId}/integrations/api-keys/change-source

>

```json
{"openapi":"3.0.0","info":{"title":"PodPlay Inc API","version":"2.0"},"tags":[{"name":"API Keys Configuration","description":"API key policies and permissions."}],"servers":[{"url":"/apis/v2","description":"Current Server"}],"security":[{"bearer":[]}],"components":{"securitySchemes":{"bearer":{"scheme":"bearer","bearerFormat":"JWT","type":"http"}},"schemas":{"ApiKeysChangeSourceDto":{"type":"object","properties":{"scenario":{"type":"string","description":"Scenario to execute for changing API keys source","enum":["create tenant keys","migrate to tenant keys","re-enable existing tenant keys","re-enable existing environment keys","generate fresh tenant keys"]}},"required":["scenario"]},"ApiKeysConfigDto":{"type":"object","properties":{"publicKey":{"type":"string","description":"RSA public key for verifying API key authentication tokens"},"privateKey":{"type":"string","description":"RSA private key preview for signing API key authentication tokens"},"keysSource":{"type":"string","description":"Source of the keys (tenant, environment, or none)","enum":["tenant","environment","none"]},"_links":{"$ref":"#/components/schemas/LinksDto"}},"required":["publicKey","privateKey","keysSource","_links"]},"LinksDto":{"type":"object","properties":{"self":{"description":"A `LinkDto` to the resource itself","allOf":[{"$ref":"#/components/schemas/LinkDto"}]}},"required":["self"]},"LinkDto":{"type":"object","properties":{"href":{"type":"string","description":"A URL"}},"required":["href"]}}},"paths":{"/tenants/{tenantId}/integrations/api-keys/change-source":{"post":{"operationId":"ApiKeysConfigController_changeSource","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ApiKeysChangeSourceDto"}}}},"responses":{"200":{"description":"Returns the updated API Keys configuration after changing source","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ApiKeysConfigDto"}}}},"403":{"description":"Forbidden: You are not allowed to change API Keys source"},"422":{"description":"Unprocessable Entity: Returns an `ErrorDto` in case of validation errors or failures.<br/>"}},"tags":["API Keys Configuration"]}}}}
```


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.podplay.app/api/configuration/api-keys-configuration.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
