---
title: SDKs
summary: The two families of BIM.works SDKs — the OpenAPI SDKs for Java, .NET, TypeScript, PHP and Python, generated from the OpenAPI document, and the classic hand-written SDKs for JavaScript, Java and .NET — what each covers and which one to use.
order: 35
terms: [sdk, openapi, api-token, auth-token]
see-also: [api, how-to/install, reference/sdk/java, reference/javascript]
---

# SDKs

BIM.works has two families of [[term:sdk|SDKs]]. Both are released with every server version and carry its version number.

| | OpenAPI SDKs | Classic SDKs |
|---|---|---|
| Languages | [[page:reference/sdk/java|Java]], [[page:reference/sdk/dotnet|.NET]], [[page:reference/sdk/typescript|TypeScript]], [[page:reference/sdk/php|PHP]], [[page:reference/sdk/python|Python]] | [[page:reference/javascript|JavaScript]], [[page:reference/java|Java]], [[page:reference/dotnet|.NET]] |
| Made by | Generated from the [[term:openapi|OpenAPI]] document on every build | Written by hand |
| Calls | Exactly the operations of the [[page:api|API part]], over HTTPS, one method per operation | The task API, the one the BIM.works web application uses, over HTTP and WebSocket |
| Classes | One API class per group of operations, one model class per request and response | One client with sub-APIs (`client.bim`, `client.fs`, …) |
| Packages | Maven `nl.bimbase.bimworks:sdk`, NuGet `BIMworks.Sdk`, npm `@bimworks/sdk`, Composer `bimbase/bimworks`, Python `bimworks` | npm `@bimworks/jssdk` (and the viewers), Maven `nl.bimbase.bimworks:client`, NuGet `BIM.works_SDK` |
| Use for | New integrations, servers and scripts, any language | The 3D and 2D viewers, which build on the JavaScript one, and existing integrations |

## Which one to use {#choose}

- **A new integration in Java, .NET, TypeScript, PHP or Python**: the OpenAPI SDK of that language. What it can do is listed per operation in the [[page:api|API part]], where every operation runs on its page.
- **A web page with the 3D or 2D viewer**: the classic JavaScript SDK, `@bimworks/jssdk`. The viewers take its client, and the viewer packages are installed with it ([[page:how-to/install/javascript]]).
- **An existing integration on a classic SDK**: it keeps working; the classic SDKs are still built, published and documented. Move to the OpenAPI SDK when you touch the code anyway; nothing has to move at once.
- **A language without an SDK**: call the API over HTTPS. Each operation page shows the request with curl.

The two families share no package name, namespace or class, so an application can use both side by side while it moves.

## The OpenAPI SDKs {#openapi}

Each OpenAPI SDK is generated by openapi-generator from the same document the [[page:api|API part]] shows, so its classes and methods follow the operations one to one: the group (tag) of an operation is the API class, the operation id is the method, and the request and response objects are model classes. Its reference — every class, method and model with an example — is generated from what the generator actually wrote, so a name on these pages is the name in the package of the same version.

| SDK | Package | Reference |
|---|---|---|
| Java 17+ | `nl.bimbase.bimworks:sdk` on `https://maven.bim.works` | [[page:reference/sdk/java]] |
| .NET 8+ (the library also targets .NET Standard 2.0) | `BIMworks.Sdk` on nuget.org | [[page:reference/sdk/dotnet]] |
| TypeScript and JavaScript, Node.js 18+ and browsers | `@bimworks/sdk` on `https://npm.bim.works` | [[page:reference/sdk/typescript]] |
| PHP 8.1+ | `bimbase/bimworks` from the BIM.works Composer registry | [[page:reference/sdk/php]] |
| Python 3.9+ | `bimworks` on `https://pypi.bim.works/simple/` | [[page:reference/sdk/python]] |

### One example shape {#example-shape}

Every example of an OpenAPI SDK, on these reference pages and on the operation pages of the API part, is a complete program with the same four steps, in every language:

1. **Connect** — a client for your instance (`BIM_WORKS_ADDRESS/openapi`), logged in with your [[term:api-token|API token]]: the login returns an [[term:auth-token|auth token]], which every later call sends as its bearer token.
2. **The request** — the request object, built from the same JSON the API part shows, so the body of a request reads the same in every language and on the operation's page.
3. **The call** — the operation's method on its API class.
4. **The result** — printed, or for a file written to disk.

So an example runs as it is once the package is installed: copy it, put in your address, your API token and the UUIDs it names, and run it. On the operation pages of the API part the address and the demo models of your instance are filled in for you; the API token never is. The connect step is the same in every example of a language; a program that makes several calls keeps one client and repeats steps 2 to 4.

## The classic SDKs {#classic}

The classic SDKs are hand-written clients of the task API: a client factory logs in, and the client's sub-APIs call the server's tasks. They offer some things the OpenAPI does not have yet, and the JavaScript SDK is what the viewers are built on.

| SDK | Package | Reference |
|---|---|---|
| JavaScript | `@bimworks/jssdk` on `https://npm.bim.works` | [[page:reference/javascript]] |
| Java 17+ | `nl.bimbase.bimworks:client` on `https://maven.bim.works` | [[page:reference/java]] |
| .NET Standard 2.0 | `BIM.works_SDK` on nuget.org | [[page:reference/dotnet]] |

How-to pages that show classic SDK code label it **Classic SDK**; code labelled **OpenAPI SDK** uses the generated SDKs.
