Objects
SetScxChannelCustomAttributeValuesCommandResponse
Replaces the custom fields that an SCX seller stored on channel level. The list describes the custom field entries the seller has on channel level afterwards: an entry with an "Id" updates that entry (a property that is not sent keeps its stored value), an entry without an "Id" creates a new entry and needs a "ClientId", and a stored custom field entry that no list entry names is deleted, so an empty list deletes all of them. A new entry with the name of an existing field adds a value to that field; a changed name on an existing entry renames the field. Stored entries without a name are deleted as well, although the read operation never returns them; the call does not report them. Values with an attribute code are not touched. A custom field cannot hold a file, so the input has no file property. The whole call is one unit: if any rule is violated nothing is written. The result lists all custom field entries that the seller has on channel level after the call, ordered like "QueryScxChannelCustomAttributeValues" without a requested sort order, read after the change was saved; an entry whose list entry sent a "ClientId" carries it, a created entry together with its new "Id". The call has no concurrency protection: it writes the list as given, so an entry that another client created in the meantime is deleted as well. A repeated call is not idempotent for created entries: a retry sends no "Id" for an entry that the lost first call created, so it deletes that entry and creates a new one with a new "Id". A client that did not receive the result therefore reads the stored custom fields ("QueryScxChannelCustomAttributeValues") before it repeats the call. The parameter "cascadeRename" (default false) only has an effect when the call renames a custom field: if it is true, the custom fields with the old name of all channel categories and all items of the seller are renamed as well; they are never merged into another field. Without it, the categories and items keep their custom fields and only the entries on channel level change. With "cascadeRename" the call is a heavy operation: it changes one custom field entry for each affected category and item, all in one transaction that holds locks on these rows until it ends, so it should run outside peak hours. The call takes no lock on the seller's custom fields: a cascading rename looks for clashes before it renames, so a write of a category or item custom field that adds the new name in between can leave two custom fields of that name; rename with "cascadeRename" set to true while no other client writes the custom fields of the seller. A change that reaches the offers marks the offers of all items of the seller's shop for upload. An invalid sales channel id is rejected as invalid (error code SALES_CHANNEL_ID_INVALID). A sales channel that does not exist, is deleted, is deactivated or is not an SCX seller, or an id whose channel part does not match the seller, is rejected as not found (error code SCX_SALES_CHANNEL_NOT_FOUND). Violated rules of the entries are all reported at once. The error carries the error code that all violations share, or SCX_VALIDATION_FAILED if they differ, and the violations grouped by field: the key is "entries[<index>].<field>" with the zero-based position of the entry in the list and the field in camelCase (for example "entries[2].name"), the value is a list of texts of the form "[id: <id>, clientId: <clientId>] <error code>: <message>", where the bracket part appears only if the entry carries an id or a client id and is not a machine-readable contract. If a rename with "cascadeRename" would give a channel category or an item two custom fields of the same name, or the stored categories and items cannot tell the old names of renames apart or would rename a field that the call does not mean, the call is rejected as a conflict (error code SCX_CUSTOM_FIELD_CASCADE_CONFLICT) and nothing is written, not even the rename on channel level; the violations of the entries take precedence over a conflict. The conflict lists at most 100 objects, first the channel categories ordered by id, then the items ordered by id, under "entries[<index>].name" with the index of the renamed entry; each text names the conflicting category by its public id as "[…, channelCategory: <channelCategoryId>]" or the conflicting item as "[…, item: <itemId>]", and the message names the total number of conflicting categories and of conflicting items. If the old names of two renames are equal for the database, the entries of both renames are listed without a category or item. The grouping is delivered in the same form on every API surface. - Response
object
SetScxChannelCustomAttributeValuesCommandResponseFields
customAttributeValues
The custom field entries that the seller has on channel level after the call, read after the change was saved.
Was this page helpful?