//#region src/qase/types.d.ts /** * Qase API type definitions. Pure request/response shapes — UI command * options (e.g. `--json` / `--plain` flags) belong in the consumer. */ interface ApiError { message: string; code?: number; } interface ApiResponseSuccess { status: true; result: T; } interface ApiResponseError { status: false; error: ApiError; result?: never; } type ApiResponse = ApiResponseSuccess | ApiResponseError; interface PaginatedResponse { total: number; filtered: number; count: number; entities: T[]; } interface SearchParams { query: string; limit?: number; page?: number; } interface SearchEntity { id: number; title: string; [key: string]: unknown; } interface TestCase { id: number; title: string; steps: string[] | TestStep[]; expected_result?: string; suite_id: number; section_id?: number; severity?: number; priority?: number; type?: number; behavior?: number; automation?: number; preconditions?: string | null; postconditions?: string | null; description?: string | null; tags?: Array; } interface TestStep { action: string; expected_result?: string; hash?: string; shared_step_hash?: string; shared_step_nested_hash?: string; } interface TestCaseCreateRequest { title: string; suite_id: number; steps: string[] | TestStep[]; expected_result: string; section_id?: number; severity?: number; priority?: number; type?: number; behavior?: number; automation?: number; preconditions?: string; postconditions?: string; description?: string; tags?: string[]; } interface TestCaseUpdateRequest { title?: string; suite_id?: number; section_id?: number; severity?: number; priority?: number; type?: number; behavior?: number; automation?: number; preconditions?: string; postconditions?: string; description?: string; steps?: TestStep[]; expected_result?: string; tags?: string[]; } interface SharedStep { hash: string; title: string; steps: TestStep[]; } interface SharedStepCreateRequest { title: string; steps: TestStep[]; } interface SharedStepUpdateRequest { title?: string; steps?: TestStep[]; } interface TestPlan { id: number; title: string; description?: string | null; cases?: number[]; } interface TestPlanCreateRequest { title: string; cases: number[]; description?: string | null; } interface TestPlanUpdateRequest { title?: string; description?: string | null; cases?: number[]; } interface TestPlanListParams { limit?: number; offset?: number; } interface TestRun { id: number; title: string; description?: string; status?: string; created?: string; cases?: number[]; } interface TestRunCreateRequest { title: string; description?: string; include_all_cases?: boolean; cases?: number[]; is_autotest?: boolean; environment_id?: number; environment_slug?: string; milestone_id?: number; plan_id?: number; author_id?: number; tags?: string[]; configurations?: number[]; custom_field?: Record; start_time?: string; end_time?: string; } interface TestRunListParams { search?: string; status?: string; milestone?: number; environment?: number; from_start_time?: number; to_start_time?: number; limit?: number; offset?: number; include?: string; } interface QaseError { status: false; error?: string; message?: string; code?: number; } interface TestCaseCreateResponse { id: number; } interface SharedStepCreateResponse { hash: string; } interface TestPlanCreateResponse { id: number; } interface TestRunCreateResponse { id: number; } interface QaseApiConfig { token: string; baseUrl?: string; defaultProject?: string; } declare enum TestCaseSeverity { Blocker = 1, Critical = 2, Major = 3, Normal = 4, Minor = 5, Trivial = 6 } declare enum TestCasePriority { High = 1, Medium = 2, Low = 3 } declare enum TestCaseType { Other = 1, Functional = 2, Smoke = 3, Regression = 4, Security = 5, Usability = 6, Performance = 7, Acceptance = 8 } declare enum TestCaseBehavior { Undefined = 1, Positive = 2, Negative = 3, Destructive = 4 } declare enum TestCaseAutomation { NotAutomated = 0, ToBeAutomated = 1, Automated = 2 } declare enum TestRunStatus { Active = "active", Complete = "complete", Abort = "abort" } //#endregion export { TestRunCreateResponse as A, TestPlan as C, TestPlanUpdateRequest as D, TestPlanListParams as E, TestRunStatus as M, TestStep as N, TestRun as O, TestCaseUpdateRequest as S, TestPlanCreateResponse as T, TestCaseCreateRequest as _, PaginatedResponse as a, TestCaseSeverity as b, SearchEntity as c, SharedStepCreateRequest as d, SharedStepCreateResponse as f, TestCaseBehavior as g, TestCaseAutomation as h, ApiResponseSuccess as i, TestRunListParams as j, TestRunCreateRequest as k, SearchParams as l, TestCase as m, ApiResponse as n, QaseApiConfig as o, SharedStepUpdateRequest as p, ApiResponseError as r, QaseError as s, ApiError as t, SharedStep as u, TestCaseCreateResponse as v, TestPlanCreateRequest as w, TestCaseType as x, TestCasePriority as y };