Zalo — Follower fields
List user fields — zalo.list_user_fields
List the OA's custom user fields.
| Side effect | Risk | Needs approval | Idempotent | Scopes |
|---|---|---|---|---|
| NONE | low | no | yes | — |
Input
No input.
Extra fields: ignored.
Output
| Field | Type | Description |
|---|---|---|
data | object | The OA's user fields. |
data.fields | array of object | User fields, system and custom. |
data.fields[].key | string | Key of the field. |
data.fields[].name | string | Name of the field. |
data.fields[].description | string | What the field is for. |
data.fields[].status | string | active or inactive. |
data.fields[].data_type | string | Data type: boolean, number, text, datetime, table, email, phone or url; system fields can also be id, tag, gender or location. |
data.fields[].value_unique | boolean | True when values must be unique. Only user_external_id and user_id today. |
data.fields[].field_type | string | system or oa_custom. |
data.fields[].additional_format | string | Date format, e.g. dd/MM/yyyy. Only for datetime fields. |
data.fields[].additional_fields | array of object | Columns of the table. Only for table fields. |
data.fields[].additional_fields[].key | string | Key of the column. |
data.fields[].additional_fields[].data_type | string | Data type of the column. |
data.fields[].additional_fields[].additional_format | string | Date format of the column. Only for datetime columns. |
Create user field — zalo.create_user_field
Create a custom user field.
| Side effect | Risk | Needs approval | Idempotent | Scopes |
|---|---|---|---|---|
| WRITE | medium | yes | no | — |
Input
| Field | Type | Required | Description |
|---|---|---|---|
name | string | yes | Custom field name. |
display_name | string | yes | Name shown in OA Manager. |
type | string | yes | Field type, e.g. text, number, date or choice. |
choices | array of string | no | Options for choice fields. |
Extra fields: ignored.
Output
| Field | Type | Description |
|---|---|---|
data | object | The field that was created. |
data.key | string | Key of the field. |
data.name | string | Name of the field. |
data.description | string | What the field is for. |
data.status | string | active or inactive. |
data.data_type | string | Data type: boolean, number, text, datetime, table, email, phone or url; system fields can also be id, tag, gender or location. |
data.value_unique | boolean | True when values must be unique. Only user_external_id and user_id today. |
data.field_type | string | system or oa_custom. |
data.additional_format | string | Date format, e.g. dd/MM/yyyy. Only for datetime fields. |
data.additional_fields | array of object | Columns of the table. Only for table fields. |
data.additional_fields[].key | string | Key of the column. |
data.additional_fields[].data_type | string | Data type of the column. |
data.additional_fields[].additional_format | string | Date format of the column. Only for datetime columns. |
Update user field — zalo.update_user_field
Change a custom user field's display name or choices.
| Side effect | Risk | Needs approval | Idempotent | Scopes |
|---|---|---|---|---|
| WRITE | medium | yes | no | — |
Input
| Field | Type | Required | Description |
|---|---|---|---|
name | string | yes | Custom field name. |
display_name | string | no | Name shown in OA Manager. |
choices | array of string | no | Options for choice fields. |
Extra fields: ignored.
Output
| Field | Type | Description |
|---|---|---|
data | object | The field after the update, with its full current settings. |
data.key | string | Key of the field. |
data.name | string | Name of the field. |
data.description | string | What the field is for. |
data.status | string | active or inactive. |
data.data_type | string | Data type: boolean, number, text, datetime, table, email, phone or url; system fields can also be id, tag, gender or location. |
data.value_unique | boolean | True when values must be unique. Only user_external_id and user_id today. |
data.field_type | string | system or oa_custom. |
data.additional_format | string | Date format, e.g. dd/MM/yyyy. Only for datetime fields. |
data.additional_fields | array of object | Columns of the table. Only for table fields. |
data.additional_fields[].key | string | Key of the column. |
data.additional_fields[].data_type | string | Data type of the column. |
data.additional_fields[].additional_format | string | Date format of the column. Only for datetime columns. |
Delete user field — zalo.delete_user_field
Delete a custom user field and the values users stored in it.
| Side effect | Risk | Needs approval | Idempotent | Scopes |
|---|---|---|---|---|
| WRITE | high | yes | no | — |
Input
| Field | Type | Required | Description |
|---|---|---|---|
name | string | yes | Custom field name. |
Extra fields: ignored.
Output
| Field | Type | Description |
|---|---|---|
data | object | Not returned: Zalo replies only error and message. |