> For the complete documentation index, see [llms.txt](https://docs.frends.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.frends.com/reference/frends-platform-api/platform-api-reference/api-access-management.md).

# Api Access Management

## GET /api/v1/api-management/access/api-keys

> List API keys

```json
{"openapi":"3.1.1","info":{"title":"Frends API","version":"1.0.0"},"tags":[{"name":"ApiAccessManagement"}],"servers":[{"url":"https://example.v64.frendsapp.com/"}],"security":[{}],"paths":{"/api/v1/api-management/access/api-keys":{"get":{"tags":["ApiAccessManagement"],"summary":"List API keys","operationId":"GetApiKeys","parameters":[{"name":"PageNumber","in":"query","description":"Current page number. Default value is 1.","schema":{"pattern":"^-?(?:0|[1-9]\\d*)$","type":["integer","string"],"format":"int32"}},{"name":"PageSize","in":"query","description":"Maximum page size is 200. Default page size is 30.","schema":{"pattern":"^-?(?:0|[1-9]\\d*)$","type":["integer","string"],"format":"int32"}},{"name":"environmentId","in":"query","description":"Optional environment id to filter by","schema":{"pattern":"^-?(?:0|[1-9]\\d*)$","type":["integer","string"],"format":"int64"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResponseOfDtoApiKeyGet"}}}},"404":{"description":"Not Found","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}}}}}},"components":{"schemas":{"ResponseOfDtoApiKeyGet":{"required":["data"],"type":"object","properties":{"data":{"oneOf":[{"type":"null"},{"description":"Response data","$ref":"#/components/schemas/DtoApiKeyGet"}]}}},"DtoApiKeyGet":{"type":"object","properties":{"id":{"pattern":"^-?(?:0|[1-9]\\d*)$","type":["integer","string"],"description":"Unique identifier for the API key","format":"int64"},"value":{"type":"string","description":"Value of the API key","format":"uuid"},"modified":{"type":"string","description":"The date and time when the API key was last modified","format":"date-time"},"modifier":{"type":["null","string"],"description":"The user who last modified the API key"},"environment":{"description":"Environment of the API key","$ref":"#/components/schemas/DtoEnvironmentBase"},"name":{"type":["null","string"],"description":"Name of the API key"}}},"DtoEnvironmentBase":{"type":"object","properties":{"id":{"pattern":"^-?(?:0|[1-9]\\d*)$","type":["integer","string"],"description":"Unique identifier for the Environment","format":"int64"},"displayName":{"type":["null","string"],"description":"Display name for the Environment"}}},"ProblemDetails":{"type":"object","properties":{"type":{"type":["null","string"]},"title":{"type":["null","string"]},"status":{"pattern":"^-?(?:0|[1-9]\\d*)$","type":["null","integer","string"],"format":"int32"},"detail":{"type":["null","string"]},"instance":{"type":["null","string"]}}}}}}
```

## POST /api/v1/api-management/access/api-keys

> Create API key

```json
{"openapi":"3.1.1","info":{"title":"Frends API","version":"1.0.0"},"tags":[{"name":"ApiAccessManagement"}],"servers":[{"url":"https://example.v64.frendsapp.com/"}],"security":[{}],"paths":{"/api/v1/api-management/access/api-keys":{"post":{"tags":["ApiAccessManagement"],"summary":"Create API key","requestBody":{"description":"API key to create","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DtoApiKeyCreate"}}},"required":true},"responses":{"201":{"description":"Created","headers":{"Location":{"description":"Location of the created API key","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResponseOfDtoApiKeyGet"}}}},"400":{"description":"Bad Request","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}}}}}},"components":{"schemas":{"DtoApiKeyCreate":{"type":"object","properties":{"environmentId":{"pattern":"^-?(?:0|[1-9]\\d*)$","type":["integer","string"],"description":"Identifier of the Environment of the API key","format":"int64"},"name":{"type":["null","string"],"description":"Name of the API key"}}},"ResponseOfDtoApiKeyGet":{"required":["data"],"type":"object","properties":{"data":{"oneOf":[{"type":"null"},{"description":"Response data","$ref":"#/components/schemas/DtoApiKeyGet"}]}}},"DtoApiKeyGet":{"type":"object","properties":{"id":{"pattern":"^-?(?:0|[1-9]\\d*)$","type":["integer","string"],"description":"Unique identifier for the API key","format":"int64"},"value":{"type":"string","description":"Value of the API key","format":"uuid"},"modified":{"type":"string","description":"The date and time when the API key was last modified","format":"date-time"},"modifier":{"type":["null","string"],"description":"The user who last modified the API key"},"environment":{"description":"Environment of the API key","$ref":"#/components/schemas/DtoEnvironmentBase"},"name":{"type":["null","string"],"description":"Name of the API key"}}},"DtoEnvironmentBase":{"type":"object","properties":{"id":{"pattern":"^-?(?:0|[1-9]\\d*)$","type":["integer","string"],"description":"Unique identifier for the Environment","format":"int64"},"displayName":{"type":["null","string"],"description":"Display name for the Environment"}}},"ProblemDetails":{"type":"object","properties":{"type":{"type":["null","string"]},"title":{"type":["null","string"]},"status":{"pattern":"^-?(?:0|[1-9]\\d*)$","type":["null","integer","string"],"format":"int32"},"detail":{"type":["null","string"]},"instance":{"type":["null","string"]}}}}}}
```

## GET /api/v1/api-management/access/api-keys/{id}

> Get a single API key

```json
{"openapi":"3.1.1","info":{"title":"Frends API","version":"1.0.0"},"tags":[{"name":"ApiAccessManagement"}],"servers":[{"url":"https://example.v64.frendsapp.com/"}],"security":[{}],"paths":{"/api/v1/api-management/access/api-keys/{id}":{"get":{"tags":["ApiAccessManagement"],"summary":"Get a single API key","operationId":"SingleApiKey","parameters":[{"name":"id","in":"path","description":"API key identifier","required":true,"schema":{"pattern":"^-?(?:0|[1-9]\\d*)$","type":"integer","format":"int64"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResponseOfDtoApiKeyGet"}}}},"404":{"description":"Not Found","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}}}}}},"components":{"schemas":{"ResponseOfDtoApiKeyGet":{"required":["data"],"type":"object","properties":{"data":{"oneOf":[{"type":"null"},{"description":"Response data","$ref":"#/components/schemas/DtoApiKeyGet"}]}}},"DtoApiKeyGet":{"type":"object","properties":{"id":{"pattern":"^-?(?:0|[1-9]\\d*)$","type":["integer","string"],"description":"Unique identifier for the API key","format":"int64"},"value":{"type":"string","description":"Value of the API key","format":"uuid"},"modified":{"type":"string","description":"The date and time when the API key was last modified","format":"date-time"},"modifier":{"type":["null","string"],"description":"The user who last modified the API key"},"environment":{"description":"Environment of the API key","$ref":"#/components/schemas/DtoEnvironmentBase"},"name":{"type":["null","string"],"description":"Name of the API key"}}},"DtoEnvironmentBase":{"type":"object","properties":{"id":{"pattern":"^-?(?:0|[1-9]\\d*)$","type":["integer","string"],"description":"Unique identifier for the Environment","format":"int64"},"displayName":{"type":["null","string"],"description":"Display name for the Environment"}}},"ProblemDetails":{"type":"object","properties":{"type":{"type":["null","string"]},"title":{"type":["null","string"]},"status":{"pattern":"^-?(?:0|[1-9]\\d*)$","type":["null","integer","string"],"format":"int32"},"detail":{"type":["null","string"]},"instance":{"type":["null","string"]}}}}}}
```

## PUT /api/v1/api-management/access/api-keys/{id}

> Update API key

```json
{"openapi":"3.1.1","info":{"title":"Frends API","version":"1.0.0"},"tags":[{"name":"ApiAccessManagement"}],"servers":[{"url":"https://example.v64.frendsapp.com/"}],"security":[{}],"paths":{"/api/v1/api-management/access/api-keys/{id}":{"put":{"tags":["ApiAccessManagement"],"summary":"Update API key","parameters":[{"name":"id","in":"path","description":"API key identifier","required":true,"schema":{"pattern":"^-?(?:0|[1-9]\\d*)$","type":"integer","format":"int64"}}],"requestBody":{"description":"Updated API key information","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DtoApiKeyUpdate"}}},"required":true},"responses":{"204":{"description":"No Content"},"404":{"description":"Not Found","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}}}}}},"components":{"schemas":{"DtoApiKeyUpdate":{"type":"object","properties":{"name":{"type":["null","string"],"description":"Name of the API key"}}},"ProblemDetails":{"type":"object","properties":{"type":{"type":["null","string"]},"title":{"type":["null","string"]},"status":{"pattern":"^-?(?:0|[1-9]\\d*)$","type":["null","integer","string"],"format":"int32"},"detail":{"type":["null","string"]},"instance":{"type":["null","string"]}}}}}}
```

## DELETE /api/v1/api-management/access/api-keys/{id}

> Delete API key

```json
{"openapi":"3.1.1","info":{"title":"Frends API","version":"1.0.0"},"tags":[{"name":"ApiAccessManagement"}],"servers":[{"url":"https://example.v64.frendsapp.com/"}],"security":[{}],"paths":{"/api/v1/api-management/access/api-keys/{id}":{"delete":{"tags":["ApiAccessManagement"],"summary":"Delete API key","operationId":"DeleteApiKey","parameters":[{"name":"id","in":"path","description":"API key identifier","required":true,"schema":{"pattern":"^-?(?:0|[1-9]\\d*)$","type":"integer","format":"int64"}}],"responses":{"204":{"description":"No Content"},"404":{"description":"Not Found","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}}}}}},"components":{"schemas":{"ProblemDetails":{"type":"object","properties":{"type":{"type":["null","string"]},"title":{"type":["null","string"]},"status":{"pattern":"^-?(?:0|[1-9]\\d*)$","type":["null","integer","string"],"format":"int32"},"detail":{"type":["null","string"]},"instance":{"type":["null","string"]}}}}}}
```

## GET /api/v1/api-management/access/api-keys/name/{name}

> Get a single API key by name

```json
{"openapi":"3.1.1","info":{"title":"Frends API","version":"1.0.0"},"tags":[{"name":"ApiAccessManagement"}],"servers":[{"url":"https://example.v64.frendsapp.com/"}],"security":[{}],"paths":{"/api/v1/api-management/access/api-keys/name/{name}":{"get":{"tags":["ApiAccessManagement"],"summary":"Get a single API key by name","operationId":"SingleApiKeyByName","parameters":[{"name":"name","in":"path","description":"API key name (case-insensitive)","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResponseOfDtoApiKeyGet"}}}},"404":{"description":"Not Found","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}}}}}},"components":{"schemas":{"ResponseOfDtoApiKeyGet":{"required":["data"],"type":"object","properties":{"data":{"oneOf":[{"type":"null"},{"description":"Response data","$ref":"#/components/schemas/DtoApiKeyGet"}]}}},"DtoApiKeyGet":{"type":"object","properties":{"id":{"pattern":"^-?(?:0|[1-9]\\d*)$","type":["integer","string"],"description":"Unique identifier for the API key","format":"int64"},"value":{"type":"string","description":"Value of the API key","format":"uuid"},"modified":{"type":"string","description":"The date and time when the API key was last modified","format":"date-time"},"modifier":{"type":["null","string"],"description":"The user who last modified the API key"},"environment":{"description":"Environment of the API key","$ref":"#/components/schemas/DtoEnvironmentBase"},"name":{"type":["null","string"],"description":"Name of the API key"}}},"DtoEnvironmentBase":{"type":"object","properties":{"id":{"pattern":"^-?(?:0|[1-9]\\d*)$","type":["integer","string"],"description":"Unique identifier for the Environment","format":"int64"},"displayName":{"type":["null","string"],"description":"Display name for the Environment"}}},"ProblemDetails":{"type":"object","properties":{"type":{"type":["null","string"]},"title":{"type":["null","string"]},"status":{"pattern":"^-?(?:0|[1-9]\\d*)$","type":["null","integer","string"],"format":"int32"},"detail":{"type":["null","string"]},"instance":{"type":["null","string"]}}}}}}
```


---

# 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 by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.frends.com/reference/frends-platform-api/platform-api-reference/api-access-management.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

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.
