Bulk: Generate CSV Template
bulk_generate_templateGenerate a ready-to-fill CSV template for bulk CRM operations, plus a per-field report explaining how each column behaves when populated, blank, or omitted.
Instructions
Generate a ready-to-fill CSV template for a bulk operation, plus a per-field report describing exactly what happens when each column is populated, left blank, or omitted.
The template is generated from the SAME field configuration the validate/execute tools use, so it always reflects the rules that will actually be applied. Supply the field configuration as arguments; nothing about any specific CRM is built in.
Returns: { csv, columns, report } where report[].behavior explains each field's merge strategy. Columns are ordered LACRM built-in fields first (key, owner name, address block, then other standard fields), then custom fields.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| fields | Yes | Field configuration (the columns "on the menu"). | |
| operation | Yes | Which operation the template is for. | |
| key_column | No | Identity column for update mode (placed first, required). | |
| address_config | No | Update-mode address mapping: an uploaded address is appended to the contact only if it is not already present (CRM copy wins on a duplicate; existing addresses untouched). | |
| key_description | No | Optional description for the key column. | |
| include_example_row | No | Append one example row built from field examples. |