Gets Forge app properties. This API can only be accessed using asApp() requests from Forge.
read:app-data:confluenceConnect apps cannot access this REST resource.
string
integer
Forge app properties returned on success.
1
2
3
4
5
6
7
8
9
10
11
12
// This sample uses Atlassian Forge
// https://developer.atlassian.com/platform/forge/
import { requestConfluence } from "@forge/bridge";
const response = await requestConfluence(`/wiki/api/v2/app/properties`, {
headers: {
'Accept': 'application/json'
}
});
console.log(`Response: ${response.status} ${response.statusText}`);
console.log(await response.json());1
2
3
4
5
6
7
8
9
10
11
12
{
"results": [
{
"key": "<string>",
"value": {}
}
],
"_links": {
"next": "<string>",
"base": "<string>"
}
}Gets a Forge app property by property key. This API can only be accessed using asApp() requests from Forge.
read:app-data:confluenceConnect apps cannot access this REST resource.
string
RequiredApp property returned on success.
1
2
3
4
5
6
7
8
9
10
11
12
// This sample uses Atlassian Forge
// https://developer.atlassian.com/platform/forge/
import { requestConfluence } from "@forge/bridge";
const response = await requestConfluence(`/wiki/api/v2/app/properties/{propertyKey}`, {
headers: {
'Accept': 'application/json'
}
});
console.log(`Response: ${response.status} ${response.statusText}`);
console.log(await response.json());1
2
3
4
5
6
7
{
"key": "user-preferences",
"value": {
"theme": "dark",
"language": "en"
}
}Creates or updates a Forge app property. This API can only be accessed using asApp() requests from Forge.
write:app-data:confluenceConnect apps cannot access this REST resource.
string
Requiredobject
Property updated.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
// This sample uses Atlassian Forge
// https://developer.atlassian.com/platform/forge/
import { requestConfluence } from "@forge/bridge";
var bodyData = `{
"name": "Forge app",
"darkMode": true,
"version": "1.0.0",
"buildNumber": 7
}`;
const response = await requestConfluence(`/wiki/api/v2/app/properties/{propertyKey}`, {
method: 'PUT',
headers: {
'Content-Type': 'application/json'
},
body: bodyData
});
console.log(`Response: ${response.status} ${response.statusText}`);
console.log(await response.text());Deletes a Forge app property. This API can only be accessed using asApp() requests from Forge.
write:app-data:confluenceConnect apps cannot access this REST resource.
string
RequiredProperty deleted.
1
2
3
4
5
6
7
8
9
10
// This sample uses Atlassian Forge
// https://developer.atlassian.com/platform/forge/
import { requestConfluence } from "@forge/bridge";
const response = await requestConfluence(`/wiki/api/v2/app/properties/{propertyKey}`, {
method: 'DELETE'
});
console.log(`Response: ${response.status} ${response.statusText}`);
console.log(await response.text());Rate this page: