> For the complete documentation index, see [llms.txt](https://docs.flowretail.com/docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.flowretail.com/docs/developers/api-documentation/soa/batch-create-soa-amounts.md).

# BATCH Create SOA amounts

Creates amounts on a SOA.

Items in:

* create : will be created.
* update : will be updated.
* delete: will be deleted.
* upsert: will create or update if needed.

The response http status is either:

* 200: all items in request was processed successfully,
* 207: one or more item was processed with an error.

Required permissions: SOA

```json
{"openapi":"3.0.2","info":{"title":"Flow Retail API version 2","version":"2.0.0"},"tags":[{"name":"SOA","description":"SOA"}],"servers":[{"description":"Flow Retail Production","url":"https://api.flowretail.com/v2"},{"description":"Flow Retail Stage","url":"https://api.stage.flowretail.com/v2"}],"security":[{"accessToken":[]},{"authToken":[]},{"integrationToken":[]}],"components":{"securitySchemes":{"accessToken":{"description":"Access token recevied after user login with a deviceToken","scheme":"bearer","type":"http"},"authToken":{"description":"Token received from the auth service","scheme":"bearer","type":"http"},"integrationToken":{"scheme":"bearer","type":"http"}},"requestBodies":{"SOAAmountBatchRequest":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SOAAmountBatchRequestSchema"}}}}},"schemas":{"SOAAmountBatchRequestSchema":{"title":"SOAAmountBatchRequestSchema","type":"object","required":["upsert"],"properties":{"upsert":{"type":"array","items":{"$ref":"#/components/schemas/SOAAmountBatchCreateRequestSchema"}}}},"SOAAmountBatchCreateRequestSchema":{"allOf":[{"$ref":"#/components/schemas/SOAAmountCreateRequestSchema"},{"properties":{"soaUid":{"$ref":"#/components/schemas/UID"}},"required":["soaUid"]}],"title":"SOAAmountBatchCreateRequestSchema","type":"object"},"SOAAmountCreateRequestSchema":{"title":"SOAAmountCreateRequestSchema","type":"object","required":["storeUid","productUid","amount","fromDateTime","toDateTime"],"properties":{"storeUid":{"$ref":"#/components/schemas/UID"},"productUid":{"$ref":"#/components/schemas/UID"},"amount":{"type":"integer"},"fromDateTime":{"type":"string","format":"date-time"},"toDateTime":{"type":"string","format":"date-time"},"soaAmountUid":{"$ref":"#/components/schemas/UID"}}},"UID":{"title":"UID","type":"string","pattern":"^[A-Za-z0-9-_]+"},"SOAAmountBatchResponseSchema":{"title":"SOAAmountBatchResponseSchema","type":"object","required":["upsert"],"properties":{"upsert":{"$ref":"#/components/schemas/BatchResponseItemSOAAmountSchema"}}},"BatchResponseItemSOAAmountSchema":{"title":"BatchResponseItemSOAAmountSchema","type":"object","required":["errors","success"],"properties":{"errors":{"type":"array","items":{"$ref":"#/components/schemas/BatchErrorSOAAmountSchema"}},"success":{"type":"integer"}}},"BatchErrorSOAAmountSchema":{"title":"BatchErrorSOAAmountSchema","type":"object","required":["errorCode","message","productUid","storeUid","soaUid"],"properties":{"errorCode":{"type":"string"},"message":{"type":"string"},"productUid":{"$ref":"#/components/schemas/OptionalUID"},"storeUid":{"$ref":"#/components/schemas/OptionalUID"},"soaUid":{"$ref":"#/components/schemas/OptionalUID"},"soaAmountUid":{"$ref":"#/components/schemas/OptionalUID"}}},"OptionalUID":{"title":"OptionalUID","type":"string","pattern":"^[A-Za-z0-9-_]*"}},"responses":{"SOAAmountBatchResponse":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SOAAmountBatchResponseSchema"}}},"description":"Response for SOAAmountBatchRequest.\n200: All items in request was processed with no errors\n207: One or more items in request returned an error"}}},"paths":{"/tenants/{tenantUid}/soas/batch":{"post":{"description":"Creates amounts on a SOA.\n\nItems in:\n  - create :  will be created.\n  - update :  will be updated.\n  - delete:   will be deleted.\n  - upsert:   will create or update if needed.\n\nThe response http status is either:\n - 200: all items in request was processed successfully, \n - 207: one or more item was processed with an error.\n\nRequired permissions: SOA\n","operationId":"post-tenant-soa-amounts-batch","requestBody":{"$ref":"#/components/requestBodies/SOAAmountBatchRequest"},"responses":{"200":{"$ref":"#/components/responses/SOAAmountBatchResponse"},"207":{"$ref":"#/components/responses/SOAAmountBatchResponse"}},"summary":"BATCH Create SOA amounts","tags":["SOA"]}}}}
```


---

# 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 by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.flowretail.com/docs/developers/api-documentation/soa/batch-create-soa-amounts.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

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.
