Action registered_users__set
System ID:
action_registered_users__set
In the scenario also:registered_users__set
Description
Creates or updates a registered user record. Data is collected from constants with the registration: prefix (and standard fields such as reg_phone, reg_first_name). Files with the file: prefix are attached to the user. After execution, the full record is written to the client constant.
Identification: by default — chat_id + channel; with check_by_phone: true — by phone (registration:phone or reg_phone).
Phone
- This action does not normalize numbers to
380XXXXXXXXX(unlikeregistered_users__check_phone). - From
registration:phone/reg_phone, a local copy has+stripped forcheck_by_phonelookup and create defaults; the profilephonecolumn is then set from the raw constant (may still keep+). - Before
__set, when the phone comes from text input or a shared contact — runregistered_users__check_phoneto store normalizedreg_phone.
Events (scenario branches)
| Event | When it occurs |
|---|---|
| success | User created or updated |
There is no separate error branch in the typical scenario (the action returns success after saving).
Parameters
| Parameter | Type | Required | Default | Description |
|---|---|---|---|---|
check_by_phone |
boolean | no | false |
Look up / create by phone instead of chat_id |
active |
number | no | 1 |
Active status (1 / 0) |
anonym |
number | no | 0 |
Anonymous user (1 / 0) |
Before execution, in constants (examples):
| Constant | Description |
|---|---|
registration:first_name |
First name |
registration:last_name |
Last name |
registration:email |
|
registration:phone / reg_phone |
Phone |
file:… |
File URLs to attach |
Configuration example
{
"check_by_phone": true,
"active": 1,
"anonym": 0
}
User constants (example):
{
"reg_phone": "380501234567",
"registration:first_name": "Олена",
"registration:email": "[email protected]"
}