import { APIResource } from "../../core/resource.mjs"; import { APIPromise } from "../../core/api-promise.mjs"; import { RequestOptions } from "../../internal/request-options.mjs"; export declare class Items extends APIResource { /** * Get paginated list of items in a moderation queue with filtering options */ list(id: string, query?: ItemListParams | null | undefined, options?: RequestOptions): APIPromise; /** * Mark a queue item as resolved with a specific moderation action */ resolve(itemID: string, params: ItemResolveParams, options?: RequestOptions): APIPromise; /** * Mark a previously resolved queue item as unresolved/pending */ unresolve(itemID: string, params: ItemUnresolveParams, options?: RequestOptions): APIPromise; } export interface ItemListResponse { items: Array; pagination: ItemListResponse.Pagination; } export declare namespace ItemListResponse { interface Item { /** * Content ID */ id: string; /** * The content to be moderated */ content: string; /** * Whether the item is flagged by any label */ flagged: boolean; labels: Array; /** * Status of the item */ status: 'pending' | 'resolved'; /** * Unix timestamp of when the item was created */ timestamp: number; /** * Action IDs taken on this item */ actions?: Array; /** * Author ID */ authorId?: string; /** * Type of the content object */ contentType?: string; /** * Conversation ID */ conversationId?: string; /** * Content language */ language?: string; } namespace Item { interface Label { /** * Whether this label caused a flag */ flagged: boolean; /** * Label name */ label: string; /** * Confidence score of the label */ score: number; } interface Action { /** * Action ID */ id: string; /** * Action name */ name: string; /** * Unix timestamp of when the action was taken */ timestamp: number; /** * Action comment */ comment?: string; /** * Moderator userID */ reviewer?: string; } } interface Pagination { currentPage: number; hasNextPage: boolean; hasPreviousPage: boolean; totalItems: number; totalPages: number; } } export interface ItemResolveResponse { /** * Timestamp when the item was resolved */ resolvedAt: string; success: boolean; /** * Optional comment */ comment?: string; } export interface ItemUnresolveResponse { /** * New status of the item */ status: string; success: boolean; /** * Timestamp when the item was unresolved */ unresolvedAt: string; } export interface ItemListParams { afterDate?: string; authorId?: string; beforeDate?: string; conversationIds?: string; filteredActionIds?: string; includeResolved?: string; labels?: string; /** * Page number to fetch */ pageNumber?: number; /** * Number of items per page */ pageSize?: number; /** * Sort direction */ sortDirection?: 'asc' | 'desc'; sortField?: 'createdAt' | 'severity' | 'reviewedAt'; } export interface ItemResolveParams { /** * Path param: The queue ID */ id: string; /** * Body param: Optional comment */ comment?: string; } export interface ItemUnresolveParams { /** * Path param: The queue ID */ id: string; /** * Body param: Optional reason for unresolving the item */ comment?: string; } export declare namespace Items { export { type ItemListResponse as ItemListResponse, type ItemResolveResponse as ItemResolveResponse, type ItemUnresolveResponse as ItemUnresolveResponse, type ItemListParams as ItemListParams, type ItemResolveParams as ItemResolveParams, type ItemUnresolveParams as ItemUnresolveParams, }; } //# sourceMappingURL=items.d.mts.map