inmake DOCS
Docs / SDK / Install

Install

What drop-core-sdk is and how a project depends on it.

Node.js SDK for the Drop Core API (https://core.inmake.dev/api). It wraps the HTTP routes exposed by the api Cloud Function (Express app) into typed modules and re-exports the entity types from drop-core-lib.

The SDK is split into nine facades that mirror the server-side route groups:

Facade Server route prefix Use case
DropCoreAdmin /api/admin/** Generic CRUD against Document Database documents/collections (the store owner).
DropCoreProcess /api/process/** Business-logic endpoints (orders, payments).
DropCorePromo /api/promo/** Promo — credits ledger + coupon minting / redemption.
DropCorePublic /api/public/** Read endpoints intended for storefront / public clients.
DropCoreAuth /api/auth/** Inspect the current token (token.get(), token.check(path)).
DropCoreSecure /api/secure/** Token & secret management — access, secret, expose, revoke, syncStore. Role-gated (owner/master).
DropCoreGen /api/gen/** Generative AI endpoints — translate, nutrients, realty, seo, jsonld, design, log. Metered in credits.
DropCoreMailing /api/mailing/** Send a store's Handlebars e-mail template through its own SMTP setup — send. Free (not metered).
DropCoreModules /api/module/** The control plane of one store's module installs — catalog, list, install, update, configure, verify, enable, reroll, uninstall, call, logs, shipmentEvents. Manager-gated (owner/master) except shipmentEvents (the install token's own leg). No upload — that is /system.

Every request carries the store id and access token in headers; auth is evaluated server-side against a separate admin Document Database (see project AGENTS.md).

Install#

The package is private and consumed via a local file dependency from this monorepo. Add it to a sibling project's package.json:

{
  "dependencies": {
    "drop-core-sdk": "file:../sdk-js"
  }
}

Build the SDK (and its drop-core-lib peer) before importing:

cd functions && npm run build      # builds core-lib first
cd ../sdk-js && npm run build      # tsc -> ./lib

npm run bundle produces a single-file Node bundle at dist/drop_core_admin.js via esbuild — useful when shipping to environments that can't resolve the file: link (e.g. Cloud Functions deploys).