feat(gateway-clients): add policy-based gateway client tokens and gateway client route and DNS management endpoints

This commit is contained in:
2026-05-09 11:53:45 +00:00
parent 7e3b89d9b4
commit 97505935bb
15 changed files with 604 additions and 92 deletions
+7 -1
View File
@@ -2506,7 +2506,12 @@ export const fetchUsersAction = usersStatePart.createAction(async (statePartArg)
}
});
export async function createApiToken(name: string, scopes: interfaces.data.TApiTokenScope[], expiresInDays?: number | null) {
export async function createApiToken(
name: string,
scopes: interfaces.data.TApiTokenScope[],
expiresInDays?: number | null,
policy?: any,
) {
const context = getActionContext();
const request = new plugins.domtools.plugins.typedrequest.TypedRequest<
interfaces.requests.IReq_CreateApiToken
@@ -2516,6 +2521,7 @@ export async function createApiToken(name: string, scopes: interfaces.data.TApiT
identity: context.identity!,
name,
scopes,
policy,
expiresInDays,
});
}