Request

Removes any applied personalization or A/B/n test variant set up, such as copy, hide, or swap, from a component and restores it to its original state.

Security
HTTPBearer
Path
flowIdstring(Flowid)required

The unique identifier of the A/B/n test or personalization that contains the variant to reset. To get this ID, you can use the List flow definitions endpoint for the page and use the flow ref value.

Headers
x-sc-job-idany(X-Sc-Job-Id)

A unique identifier for the job, used to trace, audit, and revert actions performed by an AI agent through the Agent API.

Bodyapplication/jsonrequired
page_idstring, (uuid)(Page Id)required

The unique identifier of the page containing the variant. To get this ID, use List pages of a site.

Example:"3f2504e0-4f89-11d3-9a0c-0305e82c3301"
component_idstring, (uuid)(Component Id)required

The unique identifier of the component with personalization or A/B test variant to reset. To get this ID, use List components of a page.

Example:"429e3b45-277a-4c7f-adeb-4eb8b295d9ab"
languagestring or null(Language)
Example:"en"
Any of:

The language code for the page.

string
page_versioninteger or null(Page Version)
Example:1
Any of:

The version of the page to use, or null for the latest version.

integer
variant_idstring or null(Variant Id)
Example:"429e3b45277a4c7fadeb4eb8b295d9ab_9d6f8492a3234b96b4c89878a8a1a7ab"
Any of:

The unique identifier of the personalization or A/B testing variant to reset. To get this ID, you can use the List flow definitions endpoint. Use the transpiledVariants[].ref, or variants[].ref when available.

If you provide this value, the specified personalization or A/B test variant is reset. For personalization only, if you omit this value, the component on the default page variant is reset.

string
curl -i -X POST \
  'https://edge-platform.sitecorecloud.io/stream/ai-agent-api/api/v1/flows/{flowId}/variants/reset' \
  -H 'Authorization: Bearer <YOUR_JWT_HERE>' \
  -H 'Content-Type: application/json' \
  -H 'x-sc-job-id: {x-sc-job-id}' \
  -d '{
    "language": "en",
    "page_version": 1,
    "page_id": "3f2504e0-4f89-11d3-9a0c-0305e82c3301",
    "component_id": "429e3b45-277a-4c7f-adeb-4eb8b295d9ab",
    "variant_id": "429e3b45277a4c7fadeb4eb8b295d9ab_9d6f8492a3234b96b4c89878a8a1a7ab"
  }'

Responses

Successful response

Bodyapplication/json
pageIdstring, (uuid)(Pageid)

The unique identifier of the page where the component was reset

Example:"3f2504e0-4f89-11d3-9a0c-0305e82c3301"
componentIdstring, (uuid)(Componentid)

The unique identifier of the component that was reset

Example:"86a03271-dff4-470a-92bd-b68c67de2e25"
languagestring(Language)

The language of the page.

Example:"en"
Response
{ "pageId": "3f2504e0-4f89-11d3-9a0c-0305e82c3301", "componentId": "86a03271-dff4-470a-92bd-b68c67de2e25", "language": "en" }