Retrieve the data for an existing Rule, based on its ID.
When Rules
are deleted, they are marked as deleted but are not actually removed from system.
Therefore, it is possible to retrieve a deleted Rule
.
Deleted Rules
can be identified by the presence of data.meta.deleted_at
.
A Rule’s updated_at
timestamp will also reflect changes to it’s child RuleComponents
.
GET /rules/:id
curl https://reactor.adobe.io/rules/: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 GET
{
"data": {
"id": "RL20d5849b1bb546d88ccb09e525593a17",
"type": "rules",
"attributes": {
"created_at": "2023-04-21T23:06:24.660Z",
"deleted_at": null,
"dirty": true,
"enabled": true,
"name": "Example Rule",
"published": false,
"published_at": null,
"revision_number": 0,
"updated_at": "2023-04-21T23:06:24.660Z",
"created_by_email": "ciltaru@adobe.com",
"created_by_display_name": "George Ciltaru",
"updated_by_email": "ciltaru@adobe.com",
"updated_by_display_name": "George Ciltaru",
"review_status": "unsubmitted"
},
"relationships": {
"libraries": {
"links": {
"related": "https://reactor.adobe.io/rules/RL20d5849b1bb546d88ccb09e525593a17/libraries"
}
},
"revisions": {
"links": {
"related": "https://reactor.adobe.io/rules/RL20d5849b1bb546d88ccb09e525593a17/revisions"
}
},
"notes": {
"links": {
"related": "https://reactor.adobe.io/rules/RL20d5849b1bb546d88ccb09e525593a17/notes"
}
},
"property": {
"links": {
"related": "https://reactor.adobe.io/rules/RL20d5849b1bb546d88ccb09e525593a17/property"
},
"data": {
"id": "PR4b2cbbdaf096469bb85f362e0700e144",
"type": "properties"
}
},
"origin": {
"links": {
"related": "https://reactor.adobe.io/rules/RL20d5849b1bb546d88ccb09e525593a17/origin"
},
"data": {
"id": "RL20d5849b1bb546d88ccb09e525593a17",
"type": "rules"
}
},
"rule_components": {
"links": {
"related": "https://reactor.adobe.io/rules/RL20d5849b1bb546d88ccb09e525593a17/rule_components"
}
}
},
"links": {
"property": "https://reactor.adobe.io/properties/PR4b2cbbdaf096469bb85f362e0700e144",
"origin": "https://reactor.adobe.io/rules/RL20d5849b1bb546d88ccb09e525593a17",
"self": "https://reactor.adobe.io/rules/RL20d5849b1bb546d88ccb09e525593a17",
"rule_components": "https://reactor.adobe.io/rules/RL20d5849b1bb546d88ccb09e525593a17/rule_components"
},
"meta": {
"latest_revision_number": 0
}
}
}