UNPKG

guilded.ts

Version:

A powerful NPM module that allows you to easily interact with the Guilded API.

40 lines 1.76 kB
import { BaseManager, FetchManyOptions } from '../BaseManager'; import { ServerMember } from '../../structures/server/ServerMember'; import { ServerMemberRole } from '../../structures/server/ServerMemberRole'; import { ServerRole } from '../../structures/server/ServerRole'; /** * The manager of roles that belong to a server member. * @example new ServerMemberRoleManager(member); */ export declare class ServerMemberRoleManager extends BaseManager<number, ServerMemberRole> { readonly member: ServerMember; /** @param member The server member the roles belong to. */ constructor(member: ServerMember); /** * Fetch roles that belong to the member. * @param options The options to fetch the roles with. * @returns The fetched roles that belong to the member. * @example roles.fetch(); */ fetch(options?: ServerMemberRoleFetchManyOptions): Promise<import("@discordjs/collection").Collection<number, ServerRole>>; /** * Assign a role to the member. * @param role The role to add to the member. * @returns The role that was added to the member. * @example roles.assign(role); */ assign(role: number | ServerRole): Promise<ServerRole>; /** * Unassign a role from the member. * @param role The role to remove from the member. * @returns The role that was removed from the member. * @example roles.unassign(role); */ unassign(role: number | ServerRole): Promise<ServerRole>; } /** The options for fetching server member roles. */ export interface ServerMemberRoleFetchManyOptions extends FetchManyOptions { /** Whether to cache the fetched server roles. */ cacheServerRoles?: boolean; } //# sourceMappingURL=ServerMemberRoleManager.d.ts.map