Package Manifest

Every Power Platform ToolBox tool requires a package.json file at the root of the distribution. This file describes your tool to the ToolBox host and the npm registry.

Overview

The package.json follows the standard npm package format with additional PPTB-specific fields. Required fields must be present for your tool to load correctly.

Required Fields

FieldTypeDescriptionSample
namestringScoped npm package name — lowercase, no spaces"@myorg/my-tool"
versionstringSemVer-compatible version"1.0.0"
displayNamestringHuman-readable name shown in the ToolBox UI"My Awesome Tool"
descriptionstringShort description of what the tool does"Manage Dataverse solutions"
mainstringEntry-point file relative to the dist root"index.html"
iconstringPath to SVG icon relative to the dist root. Use fill="currentColor" to support light/dark themes"icons/tool.svg"
licensestringAn approved open-source license identifier"MIT"
contributorsarrayOne or more objects with a name and optional urlSee below
configurationsobjectPPTB-specific links and metadataSee Configurations Object

contributors array

Each entry must have at minimum a name.

"contributors": [
  { "name": "Jane Dev", "url": "https://janedev.com" },
  { "name": "John Doe" }
]

Allowed licenses: MIT, Apache-2.0, BSD-2-Clause, BSD-3-Clause, GPL-2.0, GPL-3.0, LGPL-3.0, ISC, AGPL-3.0-only.

Configurations Object

Nested inside the top-level configurations key.

FieldRequiredTypeDescriptionSample
repositoryYesstringURL of the tool's source repository — shown in the ToolBox help menu"https://github.com/myorg/my-tool"
websiteNostringTool website or documentation URL"https://docs.myorg.com/my-tool"
readmeUrlNostringRaw githubusercontent.com URL for the README — used to display docs inside ToolBox"https://raw.githubusercontent.com/myorg/my-tool/main/README.md"

Optional Fields

FieldTypeDescriptionSample
homepagestringPublic homepage URL"https://myorg.com"
repositoryobjectStandard npm repository object{ "type": "git", "url": "https://github.com/…" }
cspExceptionsobjectAdditional Content Security Policy origins your tool connects toSee CSP Exceptions Object
featuresobjectDeclare special ToolBox capabilities required by your toolSee Features Object

Features Object

Declare ToolBox-specific capabilities your tool needs. Omit this section entirely if neither field applies.

FieldTypeValuesDescriptionSample
multiConnectionstring"optional" | "required"Whether the tool supports or requires a second Dataverse connection"optional"
minAPIstringSemVerMinimum ToolBox API version the tool requires"1.2.0"
"features": {
  "multiConnection": "optional",
  "minAPI": "1.2.0"
}

CSP Exceptions Object

Declare additional external origins that your tool's iframe is permitted to connect to. Omit this section entirely if your tool only communicates with Dataverse endpoints. All fields are optional.

FieldTypeDescriptionSample
connect-srcstring[]Fetch, XHR, WebSocket, and EventSource origins["api.example.com"]
script-srcstring[]Additional origins allowed to serve scripts["cdn.example.com"]
style-srcstring[]Additional origins allowed to serve stylesheets["fonts.googleapis.com"]
img-srcstring[]Additional origins allowed to serve images["img.example.com"]
font-srcstring[]Additional origins allowed to serve fonts["fonts.gstatic.com"]
frame-srcstring[]Origins allowed to be embedded in iframes["embed.example.com"]
media-srcstring[]Origins allowed to serve audio/video media["media.example.com"]
"cspExceptions": {
  "connect-src": ["api.example.com"],
  "script-src": ["cdn.example.com"],
  "style-src": ["fonts.googleapis.com"],
  "img-src": ["img.example.com"],
  "font-src": ["fonts.gstatic.com"],
  "frame-src": ["embed.example.com"],
  "media-src": ["media.example.com"]
}

Full Example

{
  "name": "@myorg/my-awesome-tool",
  "version": "1.0.0",
  "displayName": "My Awesome Tool",
  "description": "Manage Dataverse solutions across environments with ease.",
  "main": "index.html",
  "icon": "icons/tool.svg",
  "license": "MIT",
  "contributors": [
    { "name": "Jane Dev", "url": "https://janedev.com" },
    { "name": "John Doe" }
  ],
  "configurations": {
    "repository": "https://github.com/myorg/my-awesome-tool",
    "website": "https://docs.myorg.com/my-awesome-tool",
    "readmeUrl": "https://raw.githubusercontent.com/myorg/my-awesome-tool/main/README.md"
  },
  "features": {
    "multiConnection": "optional",
    "minAPI": "1.2.0"
  },
  "cspExceptions": {
    "connect-src": ["api.example.com"],
    "img-src": ["img.example.com"]
  },
  "keywords": ["dataverse", "power-platform", "solutions"],
  "homepage": "https://docs.myorg.com/my-awesome-tool",
  "repository": {
    "type": "git",
    "url": "https://github.com/myorg/my-awesome-tool.git"
  },
  "bugs": {
    "url": "https://github.com/myorg/my-awesome-tool/issues"
  },
  "dependencies": {},
  "devDependencies": {
    "@pptb/types": "^1.0.0",
    "typescript": "^5.0.0",
    "vite": "^5.0.0"
  },
  "scripts": {
    "build": "vite build",
    "dev": "vite"
  }
}

Was this page helpful?