1 | import type { CollectionProp, GetSpaceParams, QueryParams } from '../../common-types';
|
2 | import type { SpaceMemberProps } from '../../entities/space-member';
|
3 | import type { OptionalDefaults } from '../wrappers/wrap';
|
4 | export type SpaceMemberPlainClientAPI = {
|
5 | /**
|
6 | * Fetch the space member
|
7 | * @param params the space and member IDs
|
8 | * @returns the space member
|
9 | * @throws if the request fails, or the space member is not found
|
10 | * @example ```javascript
|
11 | * const spaceMember = await client.spaceMember.get({
|
12 | * spaceId: '<space_id>',
|
13 | * spaceMemberId: '<member_id>',
|
14 | * });
|
15 | * ```
|
16 | */
|
17 | get(params: OptionalDefaults<GetSpaceParams & {
|
18 | spaceMemberId: string;
|
19 | }>): Promise<SpaceMemberProps>;
|
20 | /**
|
21 | * Fetches all the space members for a given space
|
22 | * @param params a space ID and query parameters
|
23 | * @returns a collection of space members
|
24 | * @throws if the request fails, the space is not found, or the query parameters are malformed
|
25 | * @example ```javascript
|
26 | * const spaceMember = await client.spaceMember.getMany({
|
27 | * spaceId: '<space_id>',
|
28 | * });
|
29 | * ```
|
30 | */
|
31 | getMany(params: OptionalDefaults<GetSpaceParams & QueryParams>): Promise<CollectionProp<SpaceMemberProps>>;
|
32 | };
|