import type { User, GeneralUserProfile, NotificationsUserProfile, TimeTrackingUserProfile, SavedQuery, Entity, FieldsParam, ListParams, Schema, Tag, DeepPartial } from "../types"; import { ResourceApi } from "./common"; type UserSchema = Schema; type GeneralUserProfileSchema = Schema; type NotificationsUserProfileSchema = Schema; type TimeTrackingUserProfileSchema = Schema; type SavedQuerySchema = Schema; type TagSchema = Schema; type UserEntity = Entity; type GeneralUserProfileEntity = Entity; type NotificationsUserProfileEntity = Entity; type TimeTrackingUserProfileEntity = Entity; type SavedQueryEntity = Entity; type TagEntity = Entity; /** * This resource lets you work with user settings in YouTrack. * https://www.jetbrains.com/help/youtrack/devportal/resource-api-users.html */ export declare class UsersApi extends ResourceApi { /** * Read the list of users in YouTrack. * @param params - Optional parameters for the request. * @param params.fields - A list of User attributes to include in the response. If not specified, only the entityID is returned. * @param params.$skip - The number of entries to skip in the response. Useful for pagination. * @param params.$top - The maximum number of entries to return. If not specified, the server limits the number of entries returned (42 by default). * @returns A list of users in YouTrack, with optional pagination. */ getUsers(params?: ListParams & FieldsParam): Promise[]>; /** * Read the settings of the YouTrack profile of a specific user. * @param userId - The Id of the user in YouTrack. * @param params - Optional parameters for the request. * @param params.fields - A list of User attributes to include in the response. If not specified, only the entityId is returned. * @returns The settings of the specified user's YouTrack profile. * @requires Read User Basic permission for basic information, or Read User permission for accessing all data. */ getUserProfile(userId: string, params?: FieldsParam): Promise>; /** * Get the general settings of the user's profile. * Requires 'Read Self' permission to read own profile and 'Read User Full' to read another user's profile. * @param userId - The Id of the user in YouTrack. * @param params - Optional parameters for the request. * @param params.fields - A list of GeneralUserProfile attributes to include in the response. If not specified, only the entityId is returned. * @returns The general profile settings of the specified user. */ getUserGeneralProfile(userId: string, params?: FieldsParam): Promise>; /** * Update the general settings of a user's profile. * Requires 'Update Self' permission to update own profile and 'Update User' to update another user's profile. * @param userId - The Id of the user in YouTrack. * @param data - The data to update in the user's general profile. * @param params - Optional parameters for the request. * @param params.fields - A list of GeneralUserProfile attributes to include in the response. If not specified, only the entityId is returned. * @returns The updated general profile settings of the specified user. */ updateUserGeneralProfile(userID: string, data: DeepPartial, params?: FieldsParam): Promise>; /** * Get the notification settings of a user's profile. * Requires 'Read Self' permission to read own profile and 'Read User Full' to read another user's profile. * @param userId - The Id of the user in YouTrack. * @param params - Optional parameters for the request. * @param params.fields - A list of NotificationsUserProfile attributes to include in the response. If not specified, only the entityId is returned. * @returns The notification settings of the specified user's profile. */ getUserNotificationProfile(userId: string, params?: FieldsParam): Promise>; /** * Change the notification settings of a user's profile. * Requires 'Update Self' permission to update own profile and 'Update User' to update another user's profile. * @param userId - The Id of the user in YouTrack. * @param body - The updated notification settings for the user profile. * @param params - Optional parameters for the request. * @param params.fields - A list of NotificationsUserProfile attributes to include in the response. If not specified, only the entityId is returned. * @returns The updated notification settings of the user's profile. */ updateUserNotificationProfile(userId: string, body: DeepPartial, params?: FieldsParam): Promise>; /** * Get the time tracking settings of a user's profile. * Requires 'Read Self' permission to read own profile and 'Read User Full' to read another user's profile. * @param userId - The ID of the user in YouTrack. * @param params - Optional parameters for the request. * @param params.fields - A list of TimeTrackingUserProfile attributes to include in the response. If not specified, only the entityId is returned. * @returns The time tracking settings of the user's profile. */ getUserTimeTrackingProfile(userId: string, params?: FieldsParam): Promise>; /** * Update the time tracking settings of a user's profile. * Requires 'Update Self' permission to update own profile and 'Update User' permission to update another user's profile. * @param userId - The Id of the user in YouTrack. * @param data - The updated time tracking settings. * @param params - Optional parameters for the request. * @param params.fields - A list of TimeTrackingUserProfile attributes to include in the response. If not specified, only the entityId is returned. * @returns The updated time tracking settings of the user's profile. */ updateUserTimeTrackingProfile(userId: string, data: DeepPartial, params?: FieldsParam): Promise>; /** * Get the list of all saved searches (saved queries) that the specified user created. * @param userId - The Id of the user in YouTrack. * @param params - Optional parameters for the request. * @param params.fields - A list of SavedQuery attributes to include in the response. If not specified, only the entityId is returned. * @param params.$skip - The number of entities to skip before returning the first one. * @param params.$top - The maximum number of entries returned in the response. Defaults to 42 if not set. * @returns A list of saved queries created by the user. */ getUserSavedQueries(userId: string, params?: ListParams & FieldsParam): Promise[]>; /** * Get the list of all tags that belong to the specified user. * @param userId - The Id of the user in YouTrack. * @param params - Optional parameters for the request. * @param params.fields - A list of Tag attributes to include in the response. If not specified, only the entityId is returned. * @param params.$skip - The number of entities to skip before returning the first one. * @param params.$top - The maximum number of entries returned in the response. Defaults to 42 if not set. * @returns A list of tags that belong to the user. */ getUserTags(userId: string, params?: ListParams & FieldsParam): Promise[]>; /** * Read the profile settings of the currently logged-in user. * @param params - Optional parameters for the request. * @param params.fields - A list of attributes to include in the response. If not specified, only the entityId is returned. * @returns The profile settings of the currently logged-in user. */ getCurrentUserProfile(params?: FieldsParam): Promise>; } export {};