Function: createServiceAccount()
createServiceAccount(
client,props):Promise<{id:number;name:string;createdAt:string;updatedAt:string;apiTokenCount:number;role:"ADMIN"|"MEMBER"|"VIEWER"; }>
Creates a new service account in an organization or project.
Parameters
client
The API client instance
props
The request properties
query
{ orgName: string; projectName: string; } | { orgName: string; } = createServiceAccountQuerySchema
Query parameters (orgName, optional projectName)
body
{ name: string; role: "ADMIN" | "MEMBER" | "VIEWER"; } = createServiceAccountBodySchema
Request body with service account name
body.name
string = ...
body.role
"ADMIN" | "MEMBER" | "VIEWER" = ...
Returns
Promise<{ id: number; name: string; createdAt: string; updatedAt: string; apiTokenCount: number; role: "ADMIN" | "MEMBER" | "VIEWER"; }>
Promise resolving to the created service account
Operation Id
create-service-account