Merge remote-tracking branch 'origin/feat/dataset-api-key-scope' into feat/dataset-api-key-scope

This commit is contained in:
YungLe 2026-06-18 17:55:36 +09:00
commit 1bb3e360e3
6 changed files with 15 additions and 10 deletions

View File

@ -5835,7 +5835,7 @@ Check if dataset is in use
| 200 | Dataset use status retrieved successfully | **application/json**: [UsageCheckResponse](#usagecheckresponse)<br> |
### [GET] /datasets/{resource_id}/api-keys
**Get all API keys for a dataset**
**Get all API keys that can access a dataset**
#### Parameters
@ -5850,7 +5850,7 @@ Check if dataset is in use
| 200 | API keys retrieved successfully | **application/json**: [ApiKeyList](#apikeylist)<br> |
### [POST] /datasets/{resource_id}/api-keys
**Create a new API key for a dataset**
**Create a new API key bound to a single dataset**
#### Parameters
@ -12653,6 +12653,7 @@ Soft lifecycle state for Agent records.
| Name | Type | Description | Required |
| ---- | ---- | ----------- | -------- |
| created_at | integer | | No |
| dataset_id | string | | No |
| id | string | | Yes |
| last_used_at | integer | | No |
| token | string | | Yes |

View File

@ -1148,6 +1148,7 @@ export type ApiKeyList = {
export type ApiKeyItem = {
created_at?: number | null
dataset_id?: string | null
id: string
last_used_at?: number | null
token: string

View File

@ -763,6 +763,7 @@ export const zWorkflowRestoreResponse = z.object({
*/
export const zApiKeyItem = z.object({
created_at: z.int().nullish(),
dataset_id: z.string().nullish(),
id: z.string(),
last_used_at: z.int().nullish(),
token: z.string(),

View File

@ -1712,37 +1712,37 @@ export const byApiKeyId2 = {
}
/**
* Get all API keys for a dataset
* Get all API keys that can access a dataset
*
* Get all API keys for a dataset
* Get all API keys that can access a dataset
*/
export const get35 = oc
.route({
description: 'Get all API keys for a dataset',
description: 'Get all API keys that can access a dataset',
inputStructure: 'detailed',
method: 'GET',
operationId: 'getDatasetsByResourceIdApiKeys',
path: '/datasets/{resource_id}/api-keys',
summary: 'Get all API keys for a dataset',
summary: 'Get all API keys that can access a dataset',
tags: ['console'],
})
.input(z.object({ params: zGetDatasetsByResourceIdApiKeysPath }))
.output(zGetDatasetsByResourceIdApiKeysResponse)
/**
* Create a new API key for a dataset
* Create a new API key bound to a single dataset
*
* Create a new API key for a dataset
* Create a new API key bound to a single dataset
*/
export const post22 = oc
.route({
description: 'Create a new API key for a dataset',
description: 'Create a new API key bound to a single dataset',
inputStructure: 'detailed',
method: 'POST',
operationId: 'postDatasetsByResourceIdApiKeys',
path: '/datasets/{resource_id}/api-keys',
successStatus: 201,
summary: 'Create a new API key for a dataset',
summary: 'Create a new API key bound to a single dataset',
tags: ['console'],
})
.input(z.object({ params: zPostDatasetsByResourceIdApiKeysPath }))

View File

@ -70,6 +70,7 @@ export type ApiKeyList = {
export type ApiKeyItem = {
created_at?: number | null
dataset_id?: string | null
id: string
last_used_at?: number | null
token: string

View File

@ -14,6 +14,7 @@ export const zApiBaseUrlResponse = z.object({
*/
export const zApiKeyItem = z.object({
created_at: z.int().nullish(),
dataset_id: z.string().nullish(),
id: z.string(),
last_used_at: z.int().nullish(),
token: z.string(),