adobe / adobe/reactor-developer-docs

Some endpoints for action doesn't provide a relevant example

Open
#129 1 comment 0 reactions 0 assignees View on GitHub
Dominant language
CSS
Stars
11
Forks
20
PR merge metrics
No merged PRs in 30d

Description

## Topic Link

- [Discontinue an ExtensionPackage](https://developer.adobelaunch.com/api/reference/1.0/extension_packages/discontinue/#discontinue-an-extensionpackage)
- [Private Release an ExtensionPackage](https://developer.adobelaunch.com/api/reference/1.0/extension_packages/release_private/#private-release-an-extensionpackage)
- [Revise a DataElement](https://developer.adobelaunch.com/api/reference/1.0/data_elements/revise/#revise-a-dataelement)
- [Revise a Rule](https://developer.adobelaunch.com/api/reference/1.0/rules/revise/#revise-a-rule)
- [Transition a Library](https://developer.adobelaunch.com/api/reference/1.0/libraries/transition/#transition-a-library)
- [Revise an Extension](https://developer.adobelaunch.com/api/reference/1.0/extensions/revise/#revise-an-extension)
- [Test a Secret](https://developer.adobelaunch.com/api/reference/1.0/secrets/test/#test-a-secret)

## Description

Some endpoints where `data.meta.action` is required, their examples omit it.
Some examples are wrong, look likes a copy of the "create" example.

Examples should be relevant like the following ones.

Discontinue an ExtensionPackage:

```shell
curl https://reactor.adobe.io/extension_packages/:id \
-H "Accept: application/vnd.api+json;revision=1" \
-H "Content-Type: application/vnd.api+json" \
-H "Authorization: Bearer [TOKEN]" \
-H "X-Api-Key: [KEY]" \
-H "X-Gw-Ims-Org-Id: [ORG_ID]" \
-X PATCH \
-d \
'
{
"data": {
"attributes": {
"discontinued": true
},
"type": "extension_packages",
"id": "EP5eb32f57d71e436cac2b8e0e72ad08d2"
}
}'
```

Private Release an ExtensionPackage:

```shell
curl https://reactor.adobe.io/extension_packages/:id \
-H "Accept: application/vnd.api+json;revision=1" \
-H "Content-Type: application/vnd.api+json" \
-H "Authorization: Bearer [TOKEN]" \
-H "X-Api-Key: [KEY]" \
-H "X-Gw-Ims-Org-Id: [ORG_ID]" \
-X PATCH \
-d \
'
{
"data": {
"meta": {
"action": "release_private"
},
"type": "extension_packages",
"id": "EP5eb32f57d71e436cac2b8e0e72ad08d2"
}
}'
```

Revise a DataElement:

```shell
curl https://reactor.adobe.io/data_elements/:id \
-H "Accept: application/vnd.api+json;revision=1" \
-H "Content-Type: application/vnd.api+json" \
-H "Authorization: Bearer [TOKEN]" \
-H "X-Api-Key: [KEY]" \
-H "X-Gw-Ims-Org-Id: [ORG_ID]" \
-X PATCH \
-d \
'
{
"data": {
"attributes": {
"name": "My New Name",
"settings": "{\"elementSelector\":\".target-element-b\",\"elementProperty\":\"html\"}"
},
"meta": {
"action": "revise"
},
"type": "data_elements",
"id": "DE1246eb06e8884ef4b34a8e87dd9673a7"
}
}'
```

## Additional information

That not the case for [Republish a build from a published Library](https://developer.adobelaunch.com/api/reference/1.0/builds/republish/#republish-a-build-from-a-published-library).

Also, maybe it's not a documentation issue, but the `id` supplied by the `data` is required but useless. The value is ignored, never checked with the one provided in that path.

```shell
curl https://reactor.adobe.io/extension_packages/:id \
-H "Accept: application/vnd.api+json;revision=1" \
-H "Content-Type: application/vnd.api+json" \
-H "Authorization: Bearer [TOKEN]" \
-H "X-Api-Key: [KEY]" \
-H "X-Gw-Ims-Org-Id: [ORG_ID]" \
-X PATCH \
-d \
'
{
"data": {
"attributes": {
"discontinued": true
},
"type": "extension_packages",
"id": "EP5eb32f57d71e436cac2b8e0e72ad08d2"<--- the value here
}
}'
```

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.