mirror of
https://github.com/jdalrymple/gitbeaker.git
synced 2026-01-25 16:04:01 +00:00
Adding extensive typing support Unified browser and Node.JS implementations Adding support of Gitlab API 16.0
36 lines
1.1 KiB
TypeScript
36 lines
1.1 KiB
TypeScript
import { BaseResource } from '@gitbeaker/requester-utils';
|
|
import { RequestHelper, endpoint } from '../infrastructure';
|
|
import type {
|
|
GitlabAPIResponse,
|
|
PaginationRequestOptions,
|
|
PaginationTypes,
|
|
ShowExpanded,
|
|
Sudo,
|
|
} from '../infrastructure';
|
|
import type { IdentitySchema } from './GroupSAMLIdentities';
|
|
|
|
export class GroupSCIMIdentities<C extends boolean = false> extends BaseResource<C> {
|
|
all<E extends boolean = false, P extends PaginationTypes = 'offset'>(
|
|
groupId: string | number,
|
|
options: PaginationRequestOptions<P> & Sudo & ShowExpanded<E>,
|
|
): Promise<GitlabAPIResponse<IdentitySchema[], C, E, P>> {
|
|
return RequestHelper.get<IdentitySchema[]>()(
|
|
this,
|
|
endpoint`groups/${groupId}/scim/identities`,
|
|
options,
|
|
);
|
|
}
|
|
|
|
edit<E extends boolean = false>(
|
|
groupId: string | number,
|
|
identityId: string,
|
|
options: Sudo & ShowExpanded<E>,
|
|
): Promise<GitlabAPIResponse<void, C, E, void>> {
|
|
return RequestHelper.patch<void>()(
|
|
this,
|
|
endpoint`groups/${groupId}/scim/${identityId}`,
|
|
options,
|
|
);
|
|
}
|
|
}
|