Node.js Library
The official TypeScript/Node.js package,@ollang-dev/sdk, doubles as a plain API client for the whole Ollang integration API — projects, uploads, orders, folders, revisions, translation memories, custom instructions, content, billing, locales and Figma — with full TypeScript types. This page covers that programmatic use; the Quick Start and Features pages cover the Asset Management UI and Browser SDK that ship in the same package.
Source code lives in the SDK repository. Node.js 18+ is recommended.
Installation
Authentication
- Sign up or log in at Olabs
- Create or select a project
- Generate an API key from project settings
Quick Start
Ollang is a named export. It is also the default export, so import Ollang from "@ollang-dev/sdk" works too — but versions up to 0.4.0 only exported it
by name, and the default import threw Ollang is not a constructor there.
import { Ollang } works on every version.Naming the uploaded file
The platform takes the stored file’s extension from the name the file is sent under, and rejects an upload it cannot get one from. AFile carries its own
name; a bare Blob does not, so pass filename alongside it:
Blob with filename is the portable form. File is only a global from
Node 20 onwards — on Node 18 new File(...) throws ReferenceError: File is not defined, and importing File from node:buffer is not a substitute
here, as it does not satisfy the parameter’s TypeScript type. A global File
works fine where it exists, and its own name is used when filename is
omitted.name is the display name for the created project. The extension is appended
to it if it does not already end in one, so name: "App strings" above is
stored as App strings.json.
Uploading VTT subtitles
Pass the sourceprojectId returned by the upload and a name, rather than an
order ID. The response contains projectId. Source language defaults to the
project’s language; Node and Python also accept an explicit override.
Resources
All methods return typed, parsed JSON responses. Non-2xx responses reject with the underlying HTTP error, which carries the response status and body.
More Examples
Resolve a language code
Order and project creation match language codes exactly, so resolve anything uncertain instead of guessing at a region subtag.Translation memories
Folders
Billing
Large remote files
createByUrl hands the platform a URL to fetch server-side, so the bytes never
pass through your process and there is no practical size ceiling.
XLSX exports
The export endpoints resolve to aBuffer rather than JSON. Each has a
...ToFile companion that writes the workbook to a path, creating parent
directories as needed.
The underlying HTTP client stays available for anything not wrapped yet:
ollang.getClient().get("/integration/orders"). See the full API
reference for every endpoint.