younifyd
Menu

Update Segment Values

Set product data that differs per segment, like delivery time, stock or an exclusive flag. Applied separately from product content, so updating it never reprocesses the products.

Use it in a workflow

  1. Add a step and choose the Search connector.
  2. Pick the Update Segment Values action (under database).
  3. Fill in the fields below, then reference the result from later steps as {{updateSegmentValues.response.data}}.

Fields

indexSlugstringrequired

The search index whose values to update, by slug. Can also be a variable, e.g. {{variables.indexSlug}}.

rowsstringrequired

A JSON array, up to 1,000 per step, like [{"key":"p1","unitKey":"p1-a","segment":"uk","values":{"deliveryDays":2,"exclusive":true}}]

Examples

Set delivery time per segment

The same variant ships in 2 days in the UK and 5 in the EU

json
{
  "indexSlug": "products",
  "rows": "[{\"key\":\"p1\",\"unitKey\":\"p1-a\",\"segment\":\"uk\",\"values\":{\"deliveryDays\":2}},{\"key\":\"p1\",\"unitKey\":\"p1-a\",\"segment\":\"eu\",\"values\":{\"deliveryDays\":5}}]"
}

Need more? See the Search guide for connection setup and behaviour shared by every action.

Was this page helpful?