sdk package

The Core3D SDK

Remarks

The SDK is a TypeScript library that enables developers to integrate Core3D directly into their platforms. You can use the SDK to programmatically create and edit designs in real-time, build custom 3D (and 2D) editing experiences, capture screenshots, and more.

The goal of the SDK is to be higher-level than Three.js, A-Frame, or Babylon.js, but lower-level than a typical <iframe /> or React component-type editor implementation to allow developers to focus on the design and UI rather than 3D interaction.

Please refer to our [versioning notes](/docs) for info on how SDK versions work.

Classes

Class

Description

API

Core3D API client

APIError

An error that includes error and response objects.

Cache

Provides a local, in-memory cache.

Context

Establishes how the SDK should behave via configuration.

Core3D

The Core3D facade is the easiest way to get started with the SDK.

Design

The Design class handles Design Document manipulation.

EventEmitter

A typed event emitter.

GraphicAssignment

Graphic assignments are returned when applying graphic resources to a Design.

GraphicResource

Graphic resources are non-repeating images.

MaterialAssignment

Material assignments are returned when applying material resources to a Design.

MaterialResource

Material resources are base texture e.g. cotton, plastic.

PatternAssignment

Pattern assignments are returned when applying pattern resources to a Design.

PatternResource

Pattern resources are used for repeating graphics.

Polygon

A polygon utility class.

Position

A utility for altering positions using mixed units.

Tool

Implementation of basic editing tools.

ZoneAttachment

Zone attachments are returned when applying zone resources to a Design.

ZoneResource

A zone resource is a utility for displaying the defined zones on the model.

Enumerations

Enumeration

Description

Material

A reference to public material identities.

Model

A reference to public model identities.

ModelVariant

A reference to standard model variants.

Quality

Defines render qualities of textures and resources.

Functions

Function

Description

convert({ from, extra, ratio, to, value, })

Provides conversion functionality between units.

createApi(ctx, data)

Create an instance of the API client.

createCache(options)

Create a cache.

createContext(args)

Helper to create a Context object.

createDesign(args)

Helper for creating a design.

createScene(ctx, options)

Helper to create a SceneInterface object.

getQualityValue(quality)

Given a quality, get the target texture width (in pixels).

isAssignable(resource)

Type guard for AssignableInterface.

isAssignment(modifier)

Type guard for AssignmentInterface.

isAttachable(resource)

Type guard for AttachableInterface.

isAttachment(modifier)

Type guard for AttachmentInterface.

isGraphicAssignment(modifier)

Type guard for GraphicAssignment.

isGraphicResource(resource)

Type guard for GraphicResource.

isMaterialAssignment(modifier)

Type guard for MaterialAssignment.

isMaterialResource(resource)

Type guard for MaterialResource.

isMesh(node)

Type guard for MeshInterface.

isModifier(modifier)

Type guard for ModifierInterface.

isPatternAssignment(modifier)

Type guard for PatternAssignment.

isPatternResource(resource)

Type guard for PatternResource.

isQuality(quality)

Type guard for Quality.

isResource(obj)

Type guard for ResourceInterface.

isSerializedGraphicResource(data)

Type guard for a serialized GraphicResource.

isSerializedMaterialResource(data)

Type guard for a serialized MaterialResource.

isSerializedPatternResource(data)

Type guard for a serialized PatternResource.

isTextured(resource)

Type guard for TexturedResourceInterface.

isZone(node)

A type guard for ZoneInterface.

isZoneAttachment(modifier)

Type guard for ZoneAttachment.

isZoneResource(resource)

Type guard for ZoneResource.

loadDesign(ctx, optionsOrUri)

Helper to load a Design object by identity or data.

loadGraphic(ctx, identity)

Helper to load a GraphicResource object by Upload identity.

loadMaterial(ctx, identity)

Helper to load a MaterialResource object by Material identity.

loadModel(ctx, identity, modelData)

Helper to load a ModelInterface object by Model identity.

loadPattern(ctx, identity)

Helper to load a PatternResource object by Upload identity.

loadScene(ctx, options)

Helper to load a SceneInterface.

migrate(data)

Migrate an unknown version of a design document to the latest schema.

rotatePoint(point, angle, origin)

Rotate a point around some origin.

Interfaces

Interface

Description

AdapterConstructorInterface

An AdapterInterface constructor contract.

AdapterInterface

The interface for implementing an adapter.

AssignableInterface

Assignable resources target specific nodes within a Design.

AssignmentInterface

Contract for Assignments.

AttachableInterface

Attachable resources apply to the model within a Design, rather than a specific node.

AttachmentInterface

Contract for Attachments.

CacheOptions

Options for Cache.

CacheSetOptions

Options for .

EntityInterface

Contract describing an entity.

Latest

Design Document (latest)

MaterialInterface

The interface for implementing an adapter material.

MeshInterface

Contract for meshes.

ModelDataInterface

Data for model instantiation.

ModelInterface

Contract for models.

ModifierInterface

Contract for Modifiers.

ModifierInterfaceRenderOptions

Options for ModifierInterface.render().

NodeInterface

Contract describing Nodes.

NodeInterfaceComputePolygonsOptions

Options for NodeInterface.computePolygons().

ResourceInterface

Contract for a resource.

ResourceInterfaceRenderOptions

Options for ResourceInterface.render().

SceneInterface

Contract for scenes.

TexturedResourceInterface

Contract for a textured resource.

ToolOptions

Options for the Tool constructor.

V0

Design Document (v0)

V1

Design Document (v1)

V10

Design Document (v10)

V11

Design Document (v11)

V12

Design Document (v12)

V2

Design Document (v2)

V3

Design Document (v3)

V4

Design Document (v4)

V5

Design Document (v5)

V6

Design Document (v6)

V7

Design Document (v7)

V8

Design Document (v8)

V9

Design Document (v9)

ZoneInterface

Contract for zones.

Variables

Variable

Description

validateLatest

Validator for Latest.

validateV0

Validator for V0.

validateV1

Validator for V1.

validateV10

Validator for V10.

validateV11

Validator for V11.

validateV12

Validator for V12.

validateV2

Validator for V2.

validateV3

Validator for V3.

validateV4

Validator for V4.

validateV5

Validator for V5.

validateV6

Validator for V6.

validateV7

Validator for V7.

validateV8

Validator for V8.

validateV9

Validator for V9.

Type Aliases

Type Alias

Description

AdapterInterfaceCreateMaterialOptions

Options for AdapterInterface.createMaterial().

APIResolverFn

Function that resolves a URI to its API resource.

BoundingBox

Describes a bounding box.

ConvertParameters

Parameters for a conversion function given from/to.

ConvertUnit

Units supported by the conversion utility.

DesignEvents

Events emitted by Design.

GraphicAssignmentOptions

Options for graphic assignments.

GraphicResourceOptions

Options for graphic resources.

GraphicResourceSources

Sources for graphic resources.

MaterialAssignmentOptions

Options for material assignments.

MaterialInterfaceSetTextureSourcesOptions

Options for MaterialInterface.setTextureSources().

MaterialInterfaceTextureKeys

Valid keys for MaterialInterface textures.

MaterialInterfaceTextureSources

A key/value object containing texture sources.

MaterialResourceOptions

Options for material resources.

MaterialResourceSources

Sources for material resources.

MeshRankResolver

Function that determines a mesh "rank".

ModelZoneRecipientFilter

Function to check whether a mesh is a zone recipient.

ModifierEvents

Events emitted by ModifierInterface.

PatternAssignmentOptions

Options for pattern assignments.

PatternResourceOptions

Options for pattern resources.

PatternResourceSources

Sources for pattern resources.

Point

A point.

PositionDirection

The position direction indicator.

PositionUnit

The position unit indicator.

PositionValue

The position indicator value.

ResourceEvents

Events emitted by ResourceInterface.

SceneCamera

Scene camera options.

SceneEvents

Event types emitted by SceneInterface.

SceneLayout

Scene layout options.

SceneNodeIntersection

Describes a raycast hit during pointer interactions with SceneInterface.

SceneOptions

Options for SceneInterface.

ScenePointerEvent

Event emitted for pointer events on SceneInterface.

SerializedModifier

The JSON-serialized representation of a modifier as stored in the Design Document.

SerializedResource

The JSON-serialized representation of a resource as stored in the Design Document.

TexturedResourceInterfaceTOptions

A utility type to extend provided options with TexturedResourceInterface options.

TexturedResourceInterfaceTSources

A utility type to extend provided sources with TexturedResourceInterface sources.

ToolMode

Modes that the tool supports.

ZoneAttachmentOptions

Options for zone attachments.

ZoneDataInterface

Data for Zones.

ZoneResourceOptions

Options for zone resources.

ZoneResourceSources

Sources for zone resources.

Get in touch

We'd love to learn more about your vision and how we can help.

PressPrivacyTermsSupportCopyright © 2025 Core3D, Inc. All Rights Reserved.