← Back to schema index

UpdateBeneficiaryRequest

Body for `PUT /v1/beneficiaries/{id}`. Accepts JSON:API envelope `{ data: { attributes: {...} } }` or a flat object. All fields are optional — only those present are updated. If the body contains no editable field the server returns `422 no_valid_fields`. There are three update paths. With `label` alone, it is sanitized and stored. With a new `account_number`, `account_type`, `bank_code`, and `bank_name` are re-derived using the same rules as `POST /v1/beneficiaries`. With `bank_code` alone, the change only counts when the beneficiary is of type `phone` — on CLABE and card it is ignored silently — and it leaves the `beneficiary.phone_bank_updated` audit event when the code changes.

Properties

FieldTypeDescription
labelstringOptional free-form label. Sanitized with `strip_tags` + `trim`.
account_numberstringNew account number. Replaces the existing one and triggers the re-derivation of `account_type`, `bank_code` and `bank_name`. For type `phone`, `bank_code` must accompany the request.
bank_codestring5-digit Banxico SPEI code. For `phone` beneficiaries, may be sent alone to reassign the DiMo receiving bank. For CLABE/card the field is ignored.

Used in operations

  • PUT /v1/beneficiaries/{id}