import type { DateTime } from 'luxon'; import { int, datetime, ObjectSpec, double } from './validators.js'; type int = number; type double = number; type datetime = DateTime; export interface LoginResponse { id: int; token: string; } export declare const LoginResponseSpec: ObjectSpec; export interface Version { version: string; } export declare const VersionSpec: ObjectSpec; export interface User { id: int; name: string; real_name: string; } export declare const UserSpec: ObjectSpec; export interface SetFlag { status: string; name?: string; type_id?: int; requestee?: string; } export declare const SetFlagSpec: ObjectSpec; export interface UpdateFlag extends SetFlag { id?: int; new?: boolean; } export declare const UpdateFlagSpec: ObjectSpec; export interface Flag extends SetFlag { id: int; creation_date: datetime; modification_date: datetime; setter: string; } export declare const FlagSpec: ObjectSpec; export interface Bug { alias: string | string[]; assigned_to: string; assigned_to_detail: User; blocks: number[]; cc: string[]; cc_detail: User[]; classification: string; component: string | string[]; creation_time: datetime; creator: string; creator_detail: User; depends_on: number[]; dupe_of: int | null; flags: Flag[] | undefined; groups: string[]; id: int; is_cc_accessible: boolean; is_confirmed: boolean; is_open: boolean; is_creator_accessible: boolean; keywords: string[]; last_change_time: datetime; op_sys: string; platform: string; priority: string; product: string; qa_contact: string; qa_contact_detail?: User; resolution: string; see_also: string[] | undefined; severity: string; status: string; summary: string; target_milestone: string; update_token?: string; url: string; version: string | string[]; whiteboard: string; } export declare const BugSpec: ObjectSpec; export interface Change { field_name: string; removed: string; added: string; attachment_id?: int; } export declare const ChangeSpec: ObjectSpec; export interface History { when: datetime; who: string; changes: Change[]; } export declare const HistorySpec: ObjectSpec; export interface BugHistory { id: int; alias: string[]; history: History[]; } export declare const BugHistorySpec: ObjectSpec; export interface HistoryLookup { bugs: BugHistory[]; } export declare const HistoryLookupSpec: ObjectSpec; export interface Comment { attachment_id?: int | null; bug_id: int; count: int; creation_time: datetime; creator: string; id: int; is_private: boolean; tags: string[]; time: datetime; text: string; } export declare const CommentSpec: ObjectSpec; export interface CommentsTemplate { comments: Comment[]; } export declare const CommentsTemplateSpec: ObjectSpec; export interface Comments { bugs: Map; comments: Map; } export declare const CommentsSpec: ObjectSpec; export interface CreateCommentContent { comment: string; is_private: boolean; } export interface CreatedComment { id: int; } export declare const CreatedCommentSpec: ObjectSpec; export interface CreateBugContent { product: string; component: string; summary: string; version: string; description: string; op_sys: string; platform: string; priority: string; severity: string; alias?: string[]; assigned_to?: string; cc?: string[]; comment_is_private?: boolean; comment_tags?: string[]; groups?: string[]; keywords?: string[]; qa_contact?: string; status?: string; resolution?: string; target_milestone?: string; flags?: SetFlag[]; } export interface CreatedBug { id: int; } export declare const CreatedBugSpec: ObjectSpec; export interface UpdateList { add?: T[]; remove?: T[]; } export type UpdateOrReplaceList = UpdateList | { set?: T[]; }; export interface UpdateBugContent { id_or_alias: int | string | string[]; ids: (int | string)[]; alias?: UpdateOrReplaceList; assigned_to?: string; blocks?: UpdateOrReplaceList; depends_on?: UpdateOrReplaceList; cc?: UpdateList; is_cc_accessible?: boolean; comment?: CreateCommentContent; comment_is_private?: Map; comment_tags?: string[]; component?: string; deadline?: datetime; dupe_of?: int; estimated_time?: double; flags?: UpdateFlag[]; groups?: UpdateList; keywords?: UpdateOrReplaceList; op_sys?: string; platform?: string; priority?: string; product?: string; qa_contact?: string; is_creator_accessible?: boolean; remaining_time?: double; reset_assigned_to?: boolean; reset_qa_contact?: boolean; resolution?: string; see_also?: UpdateList; severity?: string; status?: string; summary?: string; target_milestone?: string; url?: string; version?: string; whiteboard?: string; work_time?: double; } export interface Changes { added: string; removed: string; } export interface UpdatedBug { id: int; alias: string[]; last_change_time: datetime; changes: Map, Changes>; } export declare const UpdatedBugSpec: ObjectSpec; export interface UpdatedBugTemplate { bugs: UpdatedBug[]; } export declare const UpdatedBugTemplateSpec: ObjectSpec; export interface Attachment { data: Buffer; size: int; creation_time: datetime; last_change_time: datetime; id: int; bug_id: int; file_name: string; summary: string; content_type: string; is_private: boolean | int; is_obsolete: boolean | int; is_patch: boolean | int; creator: string; flags: Flag[]; } export declare const AttachmentSpec: ObjectSpec; export interface Attachments { bugs: Map; attachments: Map; } export declare const AttachmentsSpec: ObjectSpec; export interface CreateAttachmentContent { ids: int[]; data: Buffer | ArrayBuffer; file_name: string; summary: string; content_type: string; comment?: string; is_patch?: boolean; is_private?: boolean; flags?: SetFlag[]; } export interface CreatedAttachment { ids: int[]; } export declare const CreatedAttachmentSpec: ObjectSpec; export interface UpdateAttachmentContent { attachment_id?: int; ids?: int[]; file_name?: string; summary?: string; comment?: string; content_type?: string; is_patch?: boolean; is_private?: boolean; is_obsolete?: boolean | int; flags?: UpdateFlag[]; } export interface UpdatedAttachment { id: int; last_change_time: datetime; changes: Map, Changes>; } export declare const UpdatedAttachmentSpec: ObjectSpec; export interface UpdatedAttachmentTemplate { attachments: UpdatedAttachment[]; } export declare const UpdatedAttachmentTemplateSpec: ObjectSpec; export {};