import type { ThreadChannelStructure } from '../../client/transformers'; import { type APIThreadMember, type RESTGetAPIChannelThreadMembersQuery, type RESTGetAPIChannelThreadsArchivedQuery, type RESTPatchAPIChannelJSONBody, type RESTPostAPIChannelMessagesThreadsJSONBody } from '../../types'; import type { MakeRequired, When } from '../types/util'; import type { ThreadCreateBodyRequest } from '../types/write'; import { BaseShorter } from './base'; export declare class ThreadShorter extends BaseShorter { /** * Creates a new thread in the channel (only guild based channels). * @param channelId The ID of the parent channel. * @param reason The reason for unpinning the message. * @returns A promise that resolves when the thread is succesfully created. */ create(channelId: string, body: ThreadCreateBodyRequest, reason?: string): Promise; fromMessage(channelId: string, messageId: string, options: RESTPostAPIChannelMessagesThreadsJSONBody & { reason?: string; }): Promise; join(threadId: string): Promise; leave(threadId: string): Promise; lock(threadId: string, locked?: boolean, reason?: string): Promise; edit(threadId: string, body: RESTPatchAPIChannelJSONBody, reason?: string): Promise; removeMember(threadId: string, memberId: string): Promise; fetchMember(threadId: string, memberId: string, with_member: WithMember): Promise, GetAPIChannelThreadMemberResult>>; addMember(threadId: string, memberId: string): Promise; listMembers(threadId: string, query?: T): Promise>; listArchived(channelId: string, type: 'public' | 'private', query?: RESTGetAPIChannelThreadsArchivedQuery): Promise<{ threads: ThreadChannelStructure[]; members: GetAPIChannelThreadMemberResult[]; hasMore: boolean; }>; listGuildActive(guildId: string, force?: boolean): Promise; listJoinedArchivedPrivate(channelId: string, query?: RESTGetAPIChannelThreadsArchivedQuery): Promise<{ threads: ThreadChannelStructure[]; members: GetAPIChannelThreadMemberResult[]; hasMore: boolean; }>; } export type GetAPIChannelThreadMemberResult = MakeRequired; type InferWithMemberOnList = T extends { with_member: infer B; } ? B extends true ? Required[] : GetAPIChannelThreadMemberResult[] : GetAPIChannelThreadMemberResult[]; export {};