Skip to main content
PATCH
/
v1
/
entity
/
{entityId}
Update Entity
curl --request PATCH \
  --url https://api.app.reva.ai/v1/entity/{entityId} \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '{
  "entityId": "entity-12345",
  "op": "REPLACE",
  "path": "ATTRIBUTE",
  "relationValue": {
    "id": "parent-entity-6789",
    "typeId": "type-4567"
  },
  "attributeValue": {
    "name": "Salary",
    "value": "100000"
  }
}'
{
  "entityId": "12345",
  "entityTypeId": "abcde-1234"
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Path Parameters

entityId
string
required

Unique identifier of the entity

Query Parameters

entityTypeId
string
required

Unique identifier for the entity type.

To find the entityTypeId, follow these steps:

  • From the left menu, navigate to an Application -> Environment -> Policy Store
  • Click on the "Data" tab.
  • Here you will see a list of all Entity Types along with their IDs. Copy the ID of the entity type you want to use.

Body

application/json

Request object to update an entities' attributes or relationships

entityId
string
required

Unique identifier of the entity to be updated

Example:

"entity-12345"

op
enum<string>
required

Supported update operations

Available options:
ADD,
REMOVE,
REPLACE
Example:

"REPLACE"

path
enum<string>
required

Entity path to be updated

Available options:
ATTRIBUTE,
PARENT,
CHILD
Example:

"ATTRIBUTE"

relationValue
object

Details about a relation update, used when path is PARENT or CHILD

attributeValue
object

Details about an attribute update, used when path is ATTRIBUTE

Response

Ok

entityId
string

Unique identifier of the entity

Example:

"12345"

entityTypeId
string

Unique type identifier of the entity

Example:

"abcde-1234"

I