import { APIResource } from "../../../resource.js"; import * as Core from "../../../core.js"; import { Page, type PageParams } from "../../../pagination.js"; export declare class Metamessages extends APIResource { /** * Create a new metamessage associated with a user. Optionally link to a session * and message by providing those IDs in the request body. */ create(appId: string, userId: string, body: MetamessageCreateParams, options?: Core.RequestOptions): Core.APIPromise; /** * Update a metamessage's metadata, type, or relationships */ update(appId: string, userId: string, metamessageId: string, body: MetamessageUpdateParams, options?: Core.RequestOptions): Core.APIPromise; /** * Get metamessages with flexible filtering. * * - Filter by user only: No additional parameters needed * - Filter by session: Provide session_id * - Filter by message: Provide message_id (and session_id) * - Filter by type: Provide label * - Filter by metadata: Provide filter object */ list(appId: string, userId: string, params?: MetamessageListParams, options?: Core.RequestOptions): Core.PagePromise; list(appId: string, userId: string, options?: Core.RequestOptions): Core.PagePromise; /** * Get a specific Metamessage by ID */ get(appId: string, userId: string, metamessageId: string, options?: Core.RequestOptions): Core.APIPromise; } export declare class MetamessagesPage extends Page { } export interface Metamessage { id: string; app_id: string; content: string; created_at: string; label: string; message_id: string | null; metamessage_type: string; session_id: string | null; user_id: string; metadata?: Record; } export interface PageMetamessage { items: Array; page: number; size: number; total: number; pages?: number; } export interface MetamessageCreateParams { content: string; metamessage_type: string; message_id?: string | null; metadata?: Record; session_id?: string | null; } export interface MetamessageUpdateParams { message_id?: string | null; metadata?: Record | null; metamessage_type?: string | null; session_id?: string | null; } export interface MetamessageListParams extends PageParams { /** * Query param: Whether to reverse the order of results */ reverse?: boolean | null; /** * Body param: */ filter?: Record | null; /** * Body param: */ message_id?: string | null; /** * Body param: */ metamessage_type?: string | null; /** * Body param: */ session_id?: string | null; } export declare namespace Metamessages { export { type Metamessage as Metamessage, type PageMetamessage as PageMetamessage, MetamessagesPage as MetamessagesPage, type MetamessageCreateParams as MetamessageCreateParams, type MetamessageUpdateParams as MetamessageUpdateParams, type MetamessageListParams as MetamessageListParams, }; } //# sourceMappingURL=metamessages.d.ts.map