The Properties API exported by @forge/api
is deprecated, and will be removed on May 1, 2024.
Instead, you should now interact with properties through the respective APIs of
Confluence and Jira.
To make an authenticated call to either API, use requestConfluence or requestJira. Both will let you use either of the following methods to specify which context to use:
asUser
: sets the user's context (recommended)asApp
: sets the app's contextThis page provides recommendations on how to update apps that use any of the deprecated endpoints of the Properties API.
The Properties API provides methods to store key-value pairs on specific product contexts.
This API uses the properties
package, which is also deprecated:
1 2import { properties } from '@forge/api';
Sets the value of my-key on the Confluence page with page id 123.
The Confluence REST API V2 now uses property-id
for page property keys.
You can retrieve a page's property-id
using
Get content properties for page
with the key=${propertyKey}
query parameter.
Once you have the property-id
, use the following endpoints to query, set, and
delete page property keys:
Sets the value of my-key on the Confluence space with space key SPACEKEY.
The Confluence REST API V2 now uses property-id
for space property keys.
You can retrieve a space's property-id
using
Get space properties in space
with the key=${propertyKey}
query parameter.
Once you have the property-id
, use the following endpoints to query, set, and
delete space property keys:
Sets a key-value pair on a specified Jira issue.
Use the following endpoints to query, set, and delete Jira issue property keys instead:
Sets the value of my-key on the Jira project with project key FORGE.
Use the following endpoints to query, set, and delete Jira project property keys instead:
Rate this page: