Cargo Types
Shared TypeScript types and domain models for Cargo.
This package provides the canonical type definitions and domain structures used across Cargo products (e.g. @cargo-ai/api). It includes Zod schemas and domain-specific utilities where applicable.
Documentation: docs.getcargo.ai
Installation
npm install @cargo-ai/types
Dependency
@cargo-ai/types depends on @cargo-ai/utils. Install it if your environment does not already provide it:
npm install @cargo-ai/utils
Contents
Domain-oriented types and helpers for:
- Ai – AI resources, agents, MCP servers, files, templates
- Billing – billing and subscription types
- Connection – connectors, integrations, filters, extractors
- Content – knowledge files and libraries
- Context – context repository, runtime sandbox, knowledge graph
- Expression – expression types and
ExpressionUtils - Hosting – Cargo Hosting apps, workers, deployments, env vars, custom domains
- Orchestration – workflows, plays, tools, templates,
OrchestrationUtils - RevenueOrganization – members, capacities, territories
- Segmentation – segment types
- Storage – datasets, models, relationships, columns
- SystemOfRecordIntegration – systems of record, clients
- UserManagement – user and permission types
- WorkspaceManagement – workspaces, folders, roles, tokens
- Global – shared utilities used across domains
Use these types when you need to type payloads, validate data, or share structures with the Cargo API and backend without depending on the full @cargo-ai/api client.
Requirements
- Node.js 22.x
- TypeScript (for types)
License
See the root of the repository for license information.