/*! * Copyright Adaptavist 2022 (c) All rights reserved */ import { UsersResponseAsResponse } from "../definitions/UsersResponseAsResponse"; import { ErrorStrategyOption } from "../errorStrategy"; import { HeadersOption } from "@managed-api/commons-core"; import { CurrentUserResponseAsResponse } from "../definitions/CurrentUserResponseAsResponse"; import { UserResponseAsResponse } from "../definitions/UserResponseAsResponse"; import { GroupMembershipsResponseAsResponse } from "../definitions/GroupMembershipsResponseAsResponse"; import { OrganizationMembershipsResponseAsResponse } from "../definitions/OrganizationMembershipsResponseAsResponse"; export interface GetAllUsersRequest extends HeadersOption, ErrorStrategyOption { /** * Filters the results by role. Possible values are "end-user", "agent", or "admin" */ role?: "end-user" | "agent" | "admin"; /** * Filters the results by more than one role using the format `role[]={role}&role[]={role}` */ "role[]"?: string; /** * For custom roles which is available on the Enterprise plan and above. You can only filter by one role ID per request */ permission_set?: number; /** * List users by external id. External id has to be unique for each user under the same account. */ external_id?: string; /** * One of `id`, `updated_at`, `-id`, or `-updated_at`. The `-` denotes the sort will be descending. */ sort?: string; /** * A [pagination cursor](/documentation/api-basics/pagination/paginating-through-lists-using-cursor-pagination) that tells the endpoint which page to start on. It should be a `meta.before_cursor` value from a previous request. Note: `page[before]` and `page[after]` can't be used together in the same request. */ "page[before]"?: string; /** * A [pagination cursor](/documentation/api-basics/pagination/paginating-through-lists-using-cursor-pagination) that tells the endpoint which page to start on. It should be a `meta.after_cursor` value from a previous request. Note: `page[before]` and `page[after]` can't be used together in the same request. */ "page[after]"?: string; /** * Specifies how many records should be returned in the response. You can specify up to 100 records per page. */ "page[size]"?: number; } type GetAllUsersResponseOKType = UsersResponseAsResponse; export interface GetAllUsersResponseOK extends GetAllUsersResponseOKType { } export type GetAllUsersResponseError = undefined; export interface GetMyUserRequest extends HeadersOption, ErrorStrategyOption { } type GetMyUserResponseOKType = CurrentUserResponseAsResponse; export interface GetMyUserResponseOK extends GetMyUserResponseOKType { } export type GetMyUserResponseError = undefined; export interface GetUsersRequest extends HeadersOption, ErrorStrategyOption { /** * Accepts a comma-separated list of up to 100 user ids. */ ids?: string; /** * Accepts a comma-separated list of up to 100 external ids. */ external_ids?: string; /** * the URL of the next page */ next_page?: string; /** * the URL of the previous page */ previous_page?: string; } type GetUsersResponseOKType = UsersResponseAsResponse; export interface GetUsersResponseOK extends GetUsersResponseOKType { } export type GetUsersResponseError = undefined; export interface GetUserRequest extends HeadersOption, ErrorStrategyOption { /** * The id of the user */ user_id: number; } type GetUserResponseOKType = UserResponseAsResponse; export interface GetUserResponseOK extends GetUserResponseOKType { } export type GetUserResponseError = undefined; export interface GetUsersByGroupRequest extends HeadersOption, ErrorStrategyOption { /** * The ID of the group */ group_id: number; /** * One of `id`, `updated_at`, `-id`, or `-updated_at`. The `-` denotes the sort will be descending. */ sort?: string; /** * A [pagination cursor](/documentation/api-basics/pagination/paginating-through-lists-using-cursor-pagination) that tells the endpoint which page to start on. It should be a `meta.before_cursor` value from a previous request. Note: `page[before]` and `page[after]` can't be used together in the same request. */ "page[before]"?: string; /** * A [pagination cursor](/documentation/api-basics/pagination/paginating-through-lists-using-cursor-pagination) that tells the endpoint which page to start on. It should be a `meta.after_cursor` value from a previous request. Note: `page[before]` and `page[after]` can't be used together in the same request. */ "page[after]"?: string; /** * Specifies how many records should be returned in the response. You can specify up to 100 records per page. */ "page[size]"?: number; } type GetUsersByGroupResponseOKType = GroupMembershipsResponseAsResponse; export interface GetUsersByGroupResponseOK extends GetUsersByGroupResponseOKType { } export type GetUsersByGroupResponseError = undefined; export interface GetUsersByOrganizationRequest extends HeadersOption, ErrorStrategyOption { /** * The ID of an organization */ organization_id: number; /** * One of `id`, `updated_at`, `-id`, or `-updated_at`. The `-` denotes the sort will be descending. */ sort?: string; /** * A [pagination cursor](/documentation/api-basics/pagination/paginating-through-lists-using-cursor-pagination) that tells the endpoint which page to start on. It should be a `meta.before_cursor` value from a previous request. Note: `page[before]` and `page[after]` can't be used together in the same request. */ "page[before]"?: string; /** * A [pagination cursor](/documentation/api-basics/pagination/paginating-through-lists-using-cursor-pagination) that tells the endpoint which page to start on. It should be a `meta.after_cursor` value from a previous request. Note: `page[before]` and `page[after]` can't be used together in the same request. */ "page[after]"?: string; /** * Specifies how many records should be returned in the response. You can specify up to 100 records per page. */ "page[size]"?: number; } type GetUsersByOrganizationResponseOKType = OrganizationMembershipsResponseAsResponse; export interface GetUsersByOrganizationResponseOK extends GetUsersByOrganizationResponseOKType { } export type GetUsersByOrganizationResponseError = undefined; export {}; //# sourceMappingURL=user.d.ts.map