New:Introducing Socket Scanning for VS Code Marketplace Extensions.Learn more →
Get Started

@llml-browser/types

Package Overview
Dependencies
Maintainers
1
Versions
33
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@llml-browser/types

TypeScript types and schemas for the @llml-browser API

npmnpm
Version
0.1.0
Version published
Weekly downloads
1
-50%
Maintainers
1
Weekly downloads
 
Created
Source

@llml/api-types

TypeScript types and schemas for the LLML API.

Installation

npm install @llml/api-types
# or
yarn add @llml/api-types
# or
pnpm add @llml/api-types
# or
bun add @llml/api-types

Usage

Type-Only Imports (No Runtime Code)

import type { CrawlResult, CrawlOptions } from '@llml/api-types';

// Use types in your code
const result: CrawlResult = {
  url: 'https://example.com',
  status: 200,
  browserSessionId: 'session-123',
  completedTimestamp: new Date().toISOString(),
};

Runtime Validation with Zod Schemas

import { schemas } from '@llml/api-types';

// Validate data at runtime
const options = {
  format: ['markdown'],
  includeTimings: true,
};

const validated = schemas.ContentProcessingOptionsSchema.parse(options);

Available Types

  • CrawlResult - Result of a URL crawl
  • CrawlOptions - Configuration options for the crawler
  • ContentFormat - Supported content formats ('raw', 'cleanedHTML', 'markdown')
  • ContentProcessingOptions - Content processing configuration
  • HTMLCleaningMetrics - Metrics for HTML cleaning process
  • PageMetrics - Page performance metrics
  • CrawlMetrics - Overall crawl metrics
  • LimitsResponse - Browser service limits
  • BrowserStatus - Browser service status

Available Schemas

All types have corresponding Zod schemas for runtime validation:

import { schemas } from '@llml/api-types';

const {
  ContentFormatSchema,
  ContentProcessingOptionsSchema,
  CrawlOptionsSchema,
  PuppeteerOptionsSchema,
  HTMLCleaningOptionsSchema,
  TurndownOptionsSchema,
  LinkExtractionOptionsSchema,
  MetadataOptionsSchema,
} = schemas;

Package Structure

src/
  ├── types/        # Type definitions (no runtime code)
  │   ├── core.ts   # Core types
  │   └── index.ts  # Type exports
  ├── schemas/      # Zod schemas (runtime code)
  │   ├── core.ts   # Core schemas
  │   └── index.ts  # Schema exports
  └── index.ts      # Main entry point

Development

# Install dependencies
bun install

# Build package
bun run build

## License

MIT

Keywords

llml

FAQs

Package last updated on 29 Mar 2025

Related posts