Pikbase Docs
Open console (opens the console)
Esc

Type to search.

API reference

addResourcePack() — Application Service

Build an immutable resource pack from an authorized resource-pack template.

Builds a new immutable pack from a GsbResourcePackTmpl. The verified tenant action calls POST /api/app/addResourcePack after explicit confirmation.

Request

{
  "note": "ERP source release",
  "version": "1.0.0",
  "templateId": "resource-pack-template-id",
  "moduleFields": ["entityDefs", "workflows", "functions"]
}
Field Type Description
note string Operator-authored release note stored with the built pack.
version string Version assembled by the action from its major, minor, and build controls.
templateId string Id of the authoritative GsbResourcePackTmpl being built.
moduleFields string[] Optional explicit asset-family allowlist. Omission includes every supported family; an empty array includes none.

Verified action source

The live GsbResourcePackTmpl.actionsStr decodes to Start New Pack, which opens widget 7d32171c-fec4-4f75-8756-98c47c1553a4. Its nested Start Packing action defines apiEndPoint: "/app/addResourcePack" and transposes the current template into the request above. Direct HTTP callers use the platform's /api prefix.

Templates select data through dataDefinitions and saved dataQueries as well as module resources. Use query selection to package only an approved subset of rows; do not also select the whole definition when the filter must limit the release. Template dataQueries is distinct from the userQueries module field, which ships query resources. See CI/CD, deployment, and seeds for selective data promotion and release controls.

This is an operator packaging mutation. The server must authorize the template and tenant; templateId is selection input, not authority. Canonical release builders send an explicit moduleFields allowlist so a backend default change cannot alter the artifact. Supported values are uiResources, permissions, workflows, entityDefs, enums, widgets, propertyDefs, pages, widgetTemplates, roles, positions, groups, departments, codeGenerators, codeLibraries, docTemplates, layouts, importTemplates, plugins, userQueries, actions, themes, functions, mlDictionary, uiServices, and recurringJobs.

When entityDefs is included and widgets is omitted, canonical release validation checks defaultCreateForm_id, defaultViewForm_id, and defaultUpdateForm_id. Mutable references to excluded widgets must be cleared before the build. Immutable system references remain inventoried as deferred evidence while launch editions ship no low-code forms. A reference that resolves to neither an included nor an excluded widget fails the build; it must not emit an unknown reference.

Contract sourcePikbase verified platform contract