import { HttpClient, HttpHeaders, HttpResponse, HttpEvent, HttpParameterCodec, HttpContext } from '@angular/common/http'; import { Observable } from 'rxjs'; import { CreateUserDtoApi } from '../model/createUserDto'; import { DeleteResponseApi } from '../model/deleteResponse'; import { PatchUserDtoApi } from '../model/patchUserDto'; import { UserDtoCreatedResponseApi } from '../model/userDtoCreatedResponse'; import { UserDtoPaginatedResponseApi } from '../model/userDtoPaginatedResponse'; import { UserDtoResponseApi } from '../model/userDtoResponse'; import { Configuration } from '../configuration'; import * as i0 from "@angular/core"; export interface AttributeLicenseRequestParams { id: string; } export interface CreateUserRequestParams { createUserDtoApi: CreateUserDtoApi; } export interface DeleteUserRequestParams { id: string; } export interface GetUserByIdRequestParams { id: string; } export interface GetUsersRequestParams { createdByUserId?: string; /** The fields to sort by. The Sort by allow to sort the results by specific properties, for example to sort the results by createdAt in scending order you can use the following syntaxt : ?sortBy=createdAt:asc if you want to apply multiple sort you can do it by adding more sortBy options like this : ?sortBy=createdAt:asc,questionId:desc */ sortBy?: string; /** An array of IDs used to filter the results to only include entities with the specified IDs */ ids?: string; /** Filter by email If email is provided, we only want to return users that have the provided email If email is not provided, we return all users */ emails?: string; /** Filter by companyId */ companyId?: string; /** Include soft deleted users If includeDeleted is true and authenticated user is admin, we want to return all users, including soft deleted users */ includeSoftDeleted?: boolean; /** Search by email If search is provided, we want to return all users that match the search criteria If search is not provided, we return all users Search is computed by checking if the user\'s email contains the search string */ search?: string; /** The page of results to retrieve. */ page?: number; /** The number of items per page to retrieve. */ itemsPerPage?: number; /** A date used to filter the results based on the createdAt field of the resources, only including resources created after this date. the operator used for this filter is >= (greater than or equal to) If the createdAfter field is provided with a date without a time, it will include resources created on the same day as the provided date, starting at midnight. The format of the datetime should be ISO 8601 with timezone: YYYY-MM-DDTHH:mm:ss.sssZ. Example: 2023-02-27T21:42:00.000Z. */ createdAfter?: Date; /** A date used to filter the results based on the createdAt field of the resources, only including resources created before this date. the operator used for this filter is <= (less than or equal to) If the createdBefore field is provided with a date without a time, it will include resources created on the same day as the provided date, ending at midnight. The format of the datetime should be ISO 8601 with timezone: YYYY-MM-DDTHH:mm:ss.sssZ. Example: 2023-02-27T21:42:00.000Z. */ createdBefore?: Date; } export interface PatchUserRequestParams { id: string; patchUserDtoApi: PatchUserDtoApi; } export interface RemoveLicenseRequestParams { id: string; } export declare class UsersApiService { protected httpClient: HttpClient; protected basePath: string; defaultHeaders: HttpHeaders; configuration: Configuration; encoder: HttpParameterCodec; constructor(httpClient: HttpClient, basePath: string | string[], configuration: Configuration); private addToHttpParams; private addToHttpParamsRecursive; /** * Attribute a license to a user * This method handles POST requests to the \'/users/{id}/licence\' route with `{id}` the id of the user we want to add a licence for. The licence will be added for the product from which the call is made. For example, if the call is made from RecordX (TheOffice can tell thanks to the API key used for the call), the RecordX licence will be added for this user. * @param requestParameters * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. * @param reportProgress flag to report request and response progress. */ attributeLicense(requestParameters: AttributeLicenseRequestParams, observe?: 'body', reportProgress?: boolean, options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext; }): Observable; attributeLicense(requestParameters: AttributeLicenseRequestParams, observe?: 'response', reportProgress?: boolean, options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext; }): Observable>; attributeLicense(requestParameters: AttributeLicenseRequestParams, observe?: 'events', reportProgress?: boolean, options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext; }): Observable>; /** * Create a new user * This method handles POST requests to the \'/users\' route to create a new user using the data passed in the body. It will respond with the newly created user. * @param requestParameters * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. * @param reportProgress flag to report request and response progress. */ createUser(requestParameters: CreateUserRequestParams, observe?: 'body', reportProgress?: boolean, options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext; }): Observable; createUser(requestParameters: CreateUserRequestParams, observe?: 'response', reportProgress?: boolean, options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext; }): Observable>; createUser(requestParameters: CreateUserRequestParams, observe?: 'events', reportProgress?: boolean, options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext; }): Observable>; /** * Soft delete an existing user by ID * This method handles DELETE requests to the \'/users/{id}\' route with `{id}` the id of the user we want to delete. Access will be removed from the concerned user. * @param requestParameters * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. * @param reportProgress flag to report request and response progress. */ deleteUser(requestParameters: DeleteUserRequestParams, observe?: 'body', reportProgress?: boolean, options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext; }): Observable; deleteUser(requestParameters: DeleteUserRequestParams, observe?: 'response', reportProgress?: boolean, options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext; }): Observable>; deleteUser(requestParameters: DeleteUserRequestParams, observe?: 'events', reportProgress?: boolean, options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext; }): Observable>; /** * Get a single user by ID * This method handles GET requests to the \'/users/me\' route to get the current user. It will respond with the current user. * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. * @param reportProgress flag to report request and response progress. */ getMe(observe?: 'body', reportProgress?: boolean, options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext; }): Observable; getMe(observe?: 'response', reportProgress?: boolean, options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext; }): Observable>; getMe(observe?: 'events', reportProgress?: boolean, options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext; }): Observable>; /** * Get a single user by ID * This method handles GET requests to the \'/users/{id}\' route with `{id}` the id of the user we want to find. If the user exists it will return it, otherwise it will respond with an error. * @param requestParameters * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. * @param reportProgress flag to report request and response progress. */ getUserById(requestParameters: GetUserByIdRequestParams, observe?: 'body', reportProgress?: boolean, options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext; }): Observable; getUserById(requestParameters: GetUserByIdRequestParams, observe?: 'response', reportProgress?: boolean, options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext; }): Observable>; getUserById(requestParameters: GetUserByIdRequestParams, observe?: 'events', reportProgress?: boolean, options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext; }): Observable>; /** * Get Users with filter, sort and pagination options * This method handles GET requests to the \'/users\' route with the filter, sort and pagination options passed in the query parameters. It will respond with the paginated users along with the current state of pagination. * @param requestParameters * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. * @param reportProgress flag to report request and response progress. */ getUsers(requestParameters: GetUsersRequestParams, observe?: 'body', reportProgress?: boolean, options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext; }): Observable; getUsers(requestParameters: GetUsersRequestParams, observe?: 'response', reportProgress?: boolean, options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext; }): Observable>; getUsers(requestParameters: GetUsersRequestParams, observe?: 'events', reportProgress?: boolean, options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext; }): Observable>; /** * Patch an existing user by ID * This method handles PATCH requests to the \'/users/{id}\' route with `{id}` the id of the user we want to update. * @param requestParameters * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. * @param reportProgress flag to report request and response progress. */ patchUser(requestParameters: PatchUserRequestParams, observe?: 'body', reportProgress?: boolean, options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext; }): Observable; patchUser(requestParameters: PatchUserRequestParams, observe?: 'response', reportProgress?: boolean, options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext; }): Observable>; patchUser(requestParameters: PatchUserRequestParams, observe?: 'events', reportProgress?: boolean, options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext; }): Observable>; /** * Remove a license from a user * This method handles DELETE requests to the \'/users/{id}/licence\' route with `{id}` the id of the user we want to remove a licence for. The licence will be removed for the product from which the call is made. For example, if the call is made from RecordX (TheOffice can tell thanks to the API key used for the call), the RecordX licence will be removed for this user. * @param requestParameters * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. * @param reportProgress flag to report request and response progress. */ removeLicense(requestParameters: RemoveLicenseRequestParams, observe?: 'body', reportProgress?: boolean, options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext; }): Observable; removeLicense(requestParameters: RemoveLicenseRequestParams, observe?: 'response', reportProgress?: boolean, options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext; }): Observable>; removeLicense(requestParameters: RemoveLicenseRequestParams, observe?: 'events', reportProgress?: boolean, options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext; }): Observable>; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵprov: i0.ɵɵInjectableDeclaration; }