Skip to content

Custom fields

Many /api/v1 resources accept a custom_fields object (key and value). The definitions (type, label, required) are created in the ERP; nobody invents database columns.

A made-up example on a client:

{
"display_name": "Ana Pop",
"custom_fields": {
"allergies": "penicillin",
"referral_source": "instagram"
}
}
  1. In the ERP, open the fields settings of the entity (for example Clients).
  2. Add the key, type and label.
  3. The frontend and the API now see it in custom_fields.

Alternatively the AI proposes the key and type, and you approve it in the ERP.

“You need an allergies field (text) on clients. Add it in the ERP under the client fields. After that I send it in custom_fields.allergies.”

  • It does not create tables in the Rivil database.
  • It does not send made-up fields without a definition, or without asking you to create it.
For AI assistants

The public docs describe the capability, not the fields of any company. The per-company OpenAPI file, with its fields, is in the ERP.