Install
From npm
sh
bun add reearth-cms-integration-api-helpersh
yarn add reearth-cms-integration-api-helpersh
npm install reearth-cms-integration-api-helperRequirements: Node 20.11+, Bun, Deno, or any modern browser / edge runtime that supports fetch and URLSearchParams. The package is ESM-only ("type": "module").
From a CDN
For browser / prototype use, import straight from esm.sh:
html
<script type="module">
import { createClient } from "https://esm.sh/reearth-cms-integration-api-helper";
const cms = createClient({
baseUrl: "https://cms.example.com/api",
token: "your-integration-token",
});
const { projects } = await cms.ProjectFilter({
path: { workspaceIdOrAlias: "ws-1" },
});
console.log(projects);
</script>To pin to a specific version:
js
import { createClient } from "https://esm.sh/reearth-cms-integration-api-helper@0.1.0";