import type { PublishedPost, PublishPostInput, SocialIdentityCredentials, SocialPublishingDriver, TimelineQuery, TimelineResult } from '../types'; export declare interface ThreadsDriverOptions { graphVersion?: string authBase?: string graphBase?: string } export declare interface ThreadsAuthUrlInput { clientId: string redirectUrl: string scopes: string[] state: string } export declare interface ThreadsTokenExchangeInput { clientId: string clientSecret: string redirectUrl: string code: string } export declare interface ThreadsAccount { threadsUserId: string username?: string accessToken: string } export declare class ThreadsApiError extends Error { public status: number; public body: string; constructor(message: string, status: number, body: string); get isAuthError(): boolean; } /** * Publishing driver for Threads (Meta) via the Threads Graph API. Auth is the * Threads OAuth flow (`threads.net/oauth/authorize`, scopes `threads_basic` + * `threads_content_publish`). Publishing is the documented two-step flow: * create a media container, then publish it. * * Unlike Instagram, Threads allows text-only posts — `post.media` is optional * and, when present, the container is created as an `IMAGE` instead of `TEXT`. */ export declare class ThreadsPublishingDriver implements SocialPublishingDriver { readonly provider: 'threads'; characterLimit: number; protected graphVersion: string; protected authBase: string; protected graphBase: string; constructor(options?: ThreadsDriverOptions); getAuthUrl(input: ThreadsAuthUrlInput): string; exchangeCode(input: ThreadsTokenExchangeInput): Promise<{ accessToken: string, userId?: string, expiresIn?: number }>; resolveAccount(accessToken: string): Promise; publish(identity: SocialIdentityCredentials, post: PublishPostInput): Promise; timeline(_identity: SocialIdentityCredentials, _query?: TimelineQuery): Promise; protected graph(path: string, init: RequestInit): Promise; }