Map Price Book Attribute
map_price_book_attributeBind one price-book attribute to a canonical ITEM custom field by stable GUID during import, or atomically replace its confirmed mapping on an active book. For a closed enum, provide every exact vendor bookValue and the stable canonicalOptionId it represents. Vendor keys, labels, values, and grid rows stay unchanged; the saved adapter translates an item's option id into this book's value at pricing time. Numeric and numeric-band attributes bind to a decimal field and use an empty optionMappings list. Similar names from evaluate_price_book are suggestions only. Set confirmed true only after reviewing the complete mapping; the server validates it and activation refuses anything unconfirmed.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"bookId": "<bookId>",
"attributeKey": "<attributeKey>",
"canonicalFieldId": "<canonicalFieldId>",
"optionMappings": "<optionMappings>"
},
"name": "map_price_book_attribute"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| bookId | Yes | The price book id (GUID). | |
| confirmed | No | Whether an operator has reviewed this complete mapping. | |
| attributeKey | Yes | The vendor attribute key exactly as this book stores it. | |
| optionMappings | Yes | Closed enums only: every vendor bookValue paired with its canonical custom-field option id. Use [] for numeric, numeric-band, and open-enum attributes. | |
| canonicalFieldId | Yes | The canonical ITEM custom-field id (GUID). |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| ok | No | ||
| bookId | No | ||
| attributeKey | No | ||
| optionMappings | No | ||
| canonicalFieldId | No | ||
| mappingConfirmed | No |