UXP Manifest
The manifest is a JSON file that is located at the root of the plugin bundle. It is named manifest.json and is required for all plugins.
Overview
Each UXP plugin has one manifest.json file that describes the plugin. It contains metadata such as the plugin's name, version, icons, and entry points.
The manifest file also contains the permissions that the plugin requires. Most importantly, it contains your plugin ID which is used to identify your plugin. (Valid plugin IDs are required for distributing in Adobe's Marketplace, read more in the docmentation.)
Since UXP plugins can be run in a number of different hosts, the manifest also contains a host field that specifies which host the plugin is for. This is used to identify the plugin in the manifest and in the plugin bundle.
Reference
Manifest
The object at the root of the manifest file.
data-slots=text
Example
{
"manifestVersion": 5,
"id": "YOUR_ID_HERE",
"name": "Name of your plugin",
"version": "1.0.0",
"main": "index.html",
"host": {
"app": "HOST_APPLICATION",
"minVersion": "HOST_VERSION"
},
"entrypoints": [
{
"type": "command",
"id": "commandFn",
"label": {
"default": "Show A Dialog"
}
},
{
"type": "panel",
"id": "panelName",
"label": {
"default": "Panel Name"
}
}
],
"icons": [
{
"width": 24,
"height": 24,
"path": "icons/icon.png",
"scale": [
1,
2
]
}
],
"requiredPermissions": {
"network": {
"domains": "all"
}
}
}
data-slots=text
Properties
manifestVersion *"5"id *stringname *string | LocalizedStringstringsStringsDefinition{} (no strings)version *stringmainstringindex.html and index.js. If not specified (for deprecations), main.js is used. Default value "main.js"iconsIconDefinition[][] (no icons)host *HostDefinitionentrypoints *EntrypointDefinition[]requiredPermissionsPermissionsDefinition{} (no permissions)addonobject{} (no addons)featureFlagsFeatureFlags{} (no additional feature flags)StringsDefinition
Represents a set of strings used to localize the plugin name and other user-facing strings.
StringsDefinition keys can be used anywhere where LocalizedString is supported.
Example
Your manifest.json file might look like this:
{
"name": "my-plugin",
"strings": {
"my-plugin": {
"default": "My Plugin",
"de": "Mein Plugin"
}
}
}
LocalizedString
Represents a localized string. The key is the locale, and the value is the translated string.
Example
{
"default": "Hello",
"en": "Hello",
"de": "Hallo"
}
Properties
default *stringIconDefinition
Represents an icon used by the plugin or specific entry point. The icon may be used in the plugin list, toolbar, or other places.
Properties
width *numberheight *numberpath *string.png), JPG (.jpg or .jpeg), and SVG (.svg) files.scalenumber[]{ "path": "icon.png", "width": 24, "height": 24, "scale": [1, 2, 2.5] } Results in the following icon files being used: • icon.png or icon@1x.png (24x24px) for 100% scaling\• icon@2x.png (48x48px) for 200% scaling\• icon@2.5x.png (60x60px) for 250% scaling Default value [1] (only supports 100% scaling)theme("all" | "lightest" | "light" | "medium" | "dark" | "darkest")[]{ "path": "icon.png", "width": 24, "height": 24, "theme": ["lightest", "light"] } Default value ["all"] (supports all themes)species("generic" | "toolbar" | "pluginList")[]["generic"] (suitable for display anywhere)EntrypointDefinition
Represents an entrypoint provided by the plugin, which can be invoked by the user.
An entrypoint consists of an ID and a label at minimum.
Example
{
"id": "myPlugin.myEntrypoint",
"label": "My Entrypoint"
}
Properties
type *"command" | "panel"command and panel are supported.id *stringlabel *string | LocalizedStringdescriptionstring | LocalizedStringundefined (uses the plugin's name)shortcut{ mac: string, win: string }"shortcut": { "mac": "Cmd+Shift+P", "win": "Ctrl+Shift+P" } Keyboard shortcuts are defined separately for each platform. Each definition is a string that follows this syntax: • One or more modifier keys, in any order, each one followed by "+"\• Mac: modifiers may be Cmd, Ctrl, Opt/Alt, or Shift. The shortcut must contain at least one of Cmd or Ctrl.\• Win: modifiers may be Ctrl, Alt, or Shift. The shortcut must contain Ctrl.\• A letter or number key. Letters are case-insensitive (e.g., "Cmd+P" and "Cmd+p" mean the same thing and neither requires pressing Shift). Other keys (including punctuation, arrow keys, or F1-F12) are currently not supported. **Please note:**If your shortcut collides with a built-in command in the host app, or another plugin's shortcut, your shortcut will be ignored, and you"ll see a warning printed to the developer console. Default value undefined (no shortcut)iconIconDefinition[][] (plugin icon)minimumSize{ width: number, height: number }maximumSize{ width: number, height: number }preferredDockedSize{ width: number, height: number }preferredFloatingSize{ width: number, height: number }HostDefinition
UXP supports a number of different host applications. The host definition specifies which host app the plugin supports.
Properties
app *"PS" | "ID" | "XD"PS: Adobe Photoshop\• ID: Adobe InDesign\• XD: Adobe XDminVersion *stringx.y.z.maxVersionstringundefined (the latest version of the host app)PermissionsDefinition
To ensure that plugins are secure, UXP requires that plugins declare the permissions they need to function.
data-variant=info
data-slots=heading, text
Properties
clipboard"read" | "readAndWrite"read: enables the plugin to read from the clipboard.\• readAndWrite: enables the plugin to read from and write to the clipboard. Default value undefined (no clipboard access)localFileSystem"plugin" | "request" | "fullAccess"plugin: enables the plugin to access the file system in the plugin folder.\• request: enables the plugin to request access to the file system (user consent).\• fullAccess: enables the plugin to access the file system without requesting access. Default value "plugin"networkNetworkPermission<img src="" />), etc. Default value undefined (no network access)webviewWebviewPermissionundefined (no webview usage)launchProcessLaunchProcessPermissionrequire("uxp").shell.openPath() or shell.openExternal(). Default value undefined (no process launching)allowCodeGenerationFromStringsbooleaneval(), and new Function() syntax. Default value falseipcIpcPermissionundefinedNetworkPermission
Specifies the domains that the plugin can access in network requests.
Example
{
"domains": [
"https://example.com",
"https://*.adobe.com/",
"wss://*.myplugin.com"
]
}
Then, in your plugin code, you can make network requests like this:
const response = await fetch("https://example.com");
Or load images like this:
<img src="https://example.com/image.png" />
You can also allow access to all domains by setting domains to "all".
{
"domains": "all"
}
Properties
domains *string[] | "all"The network recipe has more details.
WebViewPermission
Enables the plugin to use webviews in its UI to display web content or complex UI.
Example
{
"allow": "yes",
"domains": ["https://example.com"],
"enableMessageBridge": "localAndRemote"
}
Then, in your plugin code, you can use a webview like this:
<webview src="https://example.com" />
To communicate between the webview and the plugin, you can use the message API:
// In the plugin:
const webview = document.querySelector("webview");
webview.addEventListener("message", (event) => \{
console.log("Received message from webview:", event.data);
webview.postMessage("Hello from the plugin!");
\});\n
// In the webview:
window.addEventListener("message", (event) => \{
console.log("Received message from plugin:", event.data);
window.uxpHost.postMessage("Hello from the webview!");
\});
Properties
allow *"yes"domains *string[] | "all"enableMessageBridge"no" | "localAndRemote""no"Find the detailed WebView API reference or use the webview-starter template plugin in UDT.
LaunchProcessPermission
Specifies the schemes and extensions that the plugin can launch.
For example, if the plugin can launch a web browser, it should specify the http and https schemes.
Example
{
"schemes": ["http", "https"],
"extensions": []
}
Properties
schemes *string[]["http", "https", "mailto"]extensions *string[]file:// schema) Example ["pdf", "png", "jpg"]The launch process recipe has more details.
IpcPermission
Allows communication with other plugins.
Example
{
"enablePluginCommunication": true
}
Properties
enablePluginCommunication *booleanThe inter-plugin communication example has more details.
FeatureFlags
Specifies which experimental features the plugin uses.
Example
{
"enableFillAsCustomAttribute": true,
"enableSWCSupport": true
}
Properties
enableFillAsCustomAttributebooleanfill attribute on SVG elements. Example ``With the following CSS: :root { --iconColor: blue; } Default value falseenableSWCSupportbooleanClick me Note that you will need to manually install the library, import it (for example import '@spectrum-web-components/button/sp-button.js'), and bundle the code with a tool like webpack or esbuild so that it's included in your plugin. Default value false