PATCH

Update Attribute Definition


Developer Preview

This API is subject to change. Bug fixes and new features will be released based on developer feedback throughout the preview period.

Updates an attribute definition.

Each time the attribute definition is updated, revision increments by 1. The current revision must be passed when updating the attribute definition. This ensures you're working with the latest attribute definition and prevents unintended overwrites.

valueType is immutable. The request is rejected if a different valueType is passed.

Changing the attribute's config (a string attribute's allowedValues, or a number attribute's min/max) re-validates every stored attribute value for this definition across all entities: any value that no longer conforms to the new configuration is reset to the attribute's defaultValue.

Endpoint
PATCH
https://www.wixapis.com/_api/attributes/v1/attribute-definitions/{attributeDefinition.id}

Errors
400Invalid Argument

There are 3 errors with this status code.

409Already Exists

There is 1 error with this status code.

This method may also return standard errors. Learn more about standard Wix errors.

Did this help?