SimplyFill.

Update mapping

Update a mapping's name, description, field_mappings, or transformations.

Update mapping

Updates one or more fields of an existing mapping. Unset fields in the request body are left unchanged.

Signature

PUT /api/v1/mappings/{mapping_id}

Content-Type: application/json

Permissions

API key scope: write or higher. Caller must own the mapping.

Path parameters

NameTypeDescription
mapping_idintegerMapping ID.

Request body

All fields are optional. Send only what you want to change.

FieldTypeDescription
namestringNew display name.
descriptionstringNew description.
field_mappingsobjectReplaces the entire field_mappings dictionary.
transformationsobjectReplaces the entire transformations dictionary.
is_templatebooleanPublish or unpublish as a reusable mapping template.
template_categorystringNew category (only meaningful when is_template is true).
template_descriptionstringNew short description for the template library.

Example

curl -X PUT https://api.simplyfill.app/v1/mappings/456 \
  -H "Authorization: Bearer $SIMPLYFILL_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "name": "Invoice — billing system (v2)",
    "field_mappings": {
      "invoice_number": "invoiceId",
      "customer_name": "clientName",
      "total_amount": "amount",
      "due_date": "dueDate"
    }
  }'
await client.mappings.update(456, {
  name: 'Invoicebilling system (v2)',
  fieldMappings: {
    invoice_number: 'invoiceId',
    customer_name: 'clientName',
    total_amount: 'amount',
    due_date: 'dueDate'
  }
})
client.mappings.update(
    456,
    name="Invoice — billing system (v2)",
    field_mappings={
        "invoice_number": "invoiceId",
        "customer_name": "clientName",
        "total_amount": "amount",
        "due_date": "dueDate",
    },
)

Response

200 OK with the updated mapping (same shape as Get mapping).

Errors

Statuserror codeCause
400validation_errorBody failed validation (unknown field, type mismatch).
403not_mapping_ownerCaller is not the mapping owner.
404mapping_not_foundNo mapping with the given ID.

`field_mappings` replaces, it does not merge

Sending a partial field_mappings object overwrites the entire stored dictionary. To add a single field, GET the mapping, merge client-side, and PUT the full result.

On this page