> For the complete documentation index, see [llms.txt](https://docs.barte.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.barte.com/api-reference/split-de-transacoes/split-pos-transacao/estornar-split.md).

# Estornar Split

## Estorno de Split POS

> Reverte o split de uma charge, estornando os valores divididos

```json
{"openapi":"3.0.0","info":{"title":"Barte Payment Service API - Split de Pagamento","version":"2.0.0"},"servers":[{"url":"https://api.barte.com","description":"Servidor de Produção"},{"url":"https://sandbox-api.barte.com","description":"Servidor de Sandbox"}],"security":[{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"x-token-api","description":"Token de autenticação para acesso à API"}},"schemas":{"SplitRevertResponse":{"type":"object","properties":{"uuidCharge":{"type":"string","format":"uuid","description":"UUID da charge original"},"valueSplitTotal":{"type":"integer","description":"Valor total do split (em centavos)"},"valueSplitActual":{"type":"integer","description":"Valor atual do split após o estorno (em centavos)"}}},"Error":{"type":"object","properties":{"errors":{"type":"array","items":{"$ref":"#/components/schemas/ErrorDetail"}},"metadata":{"$ref":"#/components/schemas/Metadata"}}},"ErrorDetail":{"type":"object","properties":{"status":{"type":"string"},"code":{"type":"string","enum":["BAR-3011","BAR-3004","BAR-3014","BAR-3013","BAR-3016","BAR-3017","BAR-3005","BAR-3015","BAR-5001","BAD_REQUEST","FORBIDDEN","METHOD_NOT_ALLOWED","NOT_ACCEPTABLE","UNSUPPORTED_MEDIA_TYPE"]},"title":{"type":"string","enum":["BUSINESS_SPLIT","BUSINESS_CHARGE","BUSINESS_VALIDATION","INVALID_REQUEST_PARAM","Corpo da requisição inválido","Erro ao processar estorno","Token inativo ou inexistente","Acesso negado","Falha temporária ao processar estorno"]},"description":{"type":"string"},"action":{"type":"string"},"additionalInfo":{"type":"object","additionalProperties":{"type":"object"}}}},"Metadata":{"type":"object","properties":{"totalRecords":{"type":"integer"},"totalPages":{"type":"integer"},"requestDatetime":{"type":"string","format":"date-time"}}}}},"paths":{"/v2/seller/orders/charges/{charge_uuid}/splits/revert":{"put":{"summary":"Estorno de Split POS","description":"Reverte o split de uma charge, estornando os valores divididos","tags":["Split de Pagamento"],"parameters":[{"name":"charge_uuid","in":"path","required":true,"schema":{"type":"string","format":"uuid"},"description":"UUID da charge splitada"},{"name":"x-token-api","in":"header","required":true,"schema":{"type":"string"},"description":"Token de autenticação da API"}],"responses":{"200":{"description":"Split estornado com sucesso","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SplitRevertResponse"}}}},"400":{"description":"Payload Inválido - O UUID no path não foi informado ou está em formato inválido","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Token Inválido ou Inativo - O token informado no header não existe, está inativo ou expirado","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Acesso Negado - O token é válido, mas pertence a um seller que não é a conta principal (matriz) da company","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Split Não Encontrado - O UUID informado não existe, não pertence ao seller autenticado, ou o split não está com status PROCESSED","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Split Já em Processamento - Outra requisição já está processando o estorno deste split (race condition detectada)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Valor Insuficiente - O valor disponível no split é menor que o valor a ser estornado","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Falha Temporária no Scheduler - Os jobs de scheduler foram criados mas falharam ao executar. O sistema fez rollback automático","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}}}}
```


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.barte.com/api-reference/split-de-transacoes/split-pos-transacao/estornar-split.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
