---
title: "Seller opt-in or opt-out"
method: POST
path: "/api/rnb/pvt/calculatorconfiguration/{promotionId}/seller-opt"
tags: ["Promotions and taxes"]
---

# Seller opt-in or opt-out

`POST /api/rnb/pvt/calculatorconfiguration/{promotionId}/seller-opt`

## Request

- Base URL: `https://apiexamples.vtexcommercestable.com.br`
- URL: `https://apiexamples.vtexcommercestable.com.br/api/rnb/pvt/calculatorconfiguration/{promotionId}/seller-opt`
- Auth: one of:
  - API key in header `X-VTEX-API-AppKey` and API key in header `X-VTEX-API-AppToken`
  - API key in header `VtexIdclientAutCookie`

Adds or removes one or more sellers to or from a specified promotion.

>⚠️ When the first seller opts in to an inactive promotion, it's activated, and when the last seller opts out, it's deactivated.


## Permissions

Any user or [application key](https://developers.vtex.com/docs/guides/api-authentication-using-application-keys) must have at least one of the appropriate [License Manager resources](https://help.vtex.com/en/tutorial/license-manager-resources--3q6ztrC8YynQf6rdc6euk3) to be able to successfully run this request. Otherwise they will receive a status code `401` error. These are the applicable resources for this endpoint

| **Product**             | **Category**                  | **Resource**                          |
| ----------------------- | ----------------------------- | ------------------------------------- |
| Rates and Benefits      | Manage external seller promos | **External_Seller_Promotions**        |

## Path parameters

- `promotionId` string, required

## Query parameters

- `an` string, required

## Headers

- `Content-Type` string, required
- `Accept` string, required
- `if-Match` string, required

## Request body

- object
  - `sellerIds` string[], required: List of seller IDs that opted in or out to the promotion.
  - `operation` 'OptIn' | 'OptOut', required: Operation to perform: `OptIn` or `OptOut`.

## Response `200`

Opt-in or opt-out executed successfully.

- object
  - `lastModified` string: Timestamp of the promotion's last modification (UTC).

## Other responses

- `400`: Bad Request
- `401`: Unauthorized
- `404`: Not Found
- `412`: Precondition Failed

## Changes

- **2025-09-22** `014172dcbda7`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/vtex/apis/promotions-taxes-api/changes/api/rnb/pvt/calculatorconfiguration/:promotionId/seller-opt/post.md)

---

[API](https://skmtc.dev/vtex/apis/promotions-taxes-api.md) - [All operations](https://skmtc.dev/vtex/apis/promotions-taxes-api/llms.txt) - [OpenAPI document](https://skmtc.dev/vtex/apis/promotions-taxes-api/revisions/6a0f116108ca?raw)
