Skip to main content

Core Types

BrowserTestConfig

Configuration options for the BrowserTest client.

QuotaInfo

Usage and quota information.

Screenshot Types

ScreenshotOptions

Configuration options for screenshot capture.

ScreenshotResult

Result of a screenshot operation.

BatchScreenshotOptions

Options for batch screenshot operations.

BatchScreenshotResult

Result of a batch screenshot operation.

Testing Types

TestOptions

Configuration options for test execution.

TestConfig

Browser and test configuration.

TestResult

Result of a test execution.

TestJob

Information about an async test job.

TestJobStatus

Detailed status of a test job.

ListTestsOptions

Options for listing test jobs.

TestJobsList

List of test jobs.

Template Types

TemplateOptions

Options for creating a test template.

TemplateResponse

Response from template creation/update.

TemplateInvocationOptions

Options for invoking a template.

TemplateJobResponse

Response from template invocation.

TemplateListOptions

Options for listing templates.

TemplateListResponse

List of templates.

Batch Types

ScreenshotRequest

Request configuration for a single screenshot in a batch.

TestRequest

Request configuration for a single test in a batch.

BatchOptions

Options for batch processing.

BatchScreenshotResults

Results from batch screenshot processing.

BatchTestResults

Results from batch test processing.

BatchJobResults

Results from batch job creation.

Error Types

BrowserTestError

Base error class for SDK errors.

BrowserTestAuthError

Authentication-related errors.

BrowserTestQuotaError

Quota and billing-related errors.

BrowserTestAPIError

API-related errors.

BrowserTestTimeoutError

Timeout-related errors.

Utility Types

ApiResponse

Generic API response wrapper.

Successful Results

Type helpers for extracting successful results.

Batch Result Types

Type helpers for batch operations.

Configuration Types

Environment-based configuration types.

Advanced Types

Generic Test Types

Template Types

Batch Processing Types

Event Types

Type Guards

Runtime type checking functions.

Type Utilities

Extract and Transform

Conditional Types

Migration Types

Types for handling API changes and versioning.

Best Practices

Type Safety

  1. Always use strict TypeScript settings
  2. Define interfaces for structured output
  3. Use discriminated unions for results
  4. Create type guards for runtime checks
  5. Leverage generic types for reusable code

Development Experience

IntelliSense Optimization

Error Type Narrowing