Quicklinks

Entity Record Operations

Entity records are instances of custom objects, and support standard CRUD operations via the API. These can be an instance of a contact object, or a custom object (with workflow data or without).

It's a good idea to be familiar with these concepts before diving in to entity record operations:

Objects

Custom Objects are how data is modeled in Kizen. Learn more about interacting with them using the API.

Object Best Practices

Tips for working with custom object and field metadata.

Get Entity Record

When getting an entity record, it can be retrieved either by using the entity ID, or identifying the record by name or email.

 

Get by ID

Using the endpoint /records/{object_identifier}/{entity_id}, a single entity can be fetched by its ID:

curl -X GET "https://app.go.kizen.com/api/records/{object_identifier}/{entity_id}" \
 -H 'accept: application/json' 

Read more details and try it yourself in the developer documentation

 

Get by Entity Name or Email

Using the endpoint /api/records/{object_identifier}/lookup, a single entity can be fetched using the entity name, or the email address for contacts:

curl -X GET "https://app.go.kizen.com/api/records/object_identifier/lookup?identifier=entity_identifier" \
 -H 'accept: application/json' 

Required query parameters:

Parameter NameTypeDescription
identifierStringThe url-encoded entity name, or email address

Optional query parameters:

Parameter NameTypeDescription
all_fieldsBooleanReturns all fields
field_idsStringComma-separated list of field ids to include in the response. If this parameter is present but empty, only default fields will be returned
field_namesStringComma-separated list of field names to include in the response. If this parameter is present but empty, only default fields will be returned

Read more details and try it yourself in the developer documentation

 

 

Update Entity Record

An entity record can be updated by object identifier and entity ID.

 

Partial Update

To partially update an entity record, make a PATCH to /records/{object_identifier}/{entity_id}:

curl -X PATCH "https://app.go.kizen.com/api/records/{object_identifier}/{entity_id}" \
 -H 'accept: application/json'\
 -H 'content-type: application/json' \
 -d '{"fields":[{"id":"{field_id}","value":100}]}' 

By default, only the updated fields will be returned in the response. In order to return all fields in the response to the PATCH, include the query parameter return_all_fields=true":

Parameter NameTypeDescription
return_all_fieldsBooleanIf true, returns all fields even if they were not updated.

Read more details and try it yourself in the developer documentation

 

 

Archive Entity Record

Entity records are archived rather than deleted. This soft delete behavior allows for entity records to be restored at a later time. When an archived record is restored, its history is preserved.

When a record is archived, if it is related to other records, in the inverse relationship field will be cleared on any related records.

To archive a record, make a DELETE to /records/{object_identifier}/{entity_id}:

curl -X DELETE "https://app.go.kizen.com/api/records/{object_identifier}/{entity_id}"

Read more details and try it yourself in the developer documentation