{
  "info": {
    "name": "Takeat V1 — Contagens de estoque",
    "schema": "https://schema.getpostman.com/json/collection/v2.1.0/collection.json"
  },
  "item": [
    {
      "name": "registerInputCount",
      "request": {
        "method": "POST",
        "header": [
          {
            "key": "Content-Type",
            "value": "application/json"
          },
          {
            "key": "Idempotency-Key",
            "value": "{{idempotencyKey}}"
          }
        ],
        "auth": {
          "type": "bearer",
          "bearer": [
            {
              "key": "token",
              "value": "{{accessToken}}",
              "type": "string"
            }
          ]
        },
        "url": "{{baseUrl}}/v1/inventory/inputs/{{stockId}}/counts?restaurant_id={{restaurantId}}",
        "body": {
          "mode": "raw",
          "raw": "{\n  \"quantidade\": \"{{countedQuantity}}\",\n  \"expected_stock_version\": \"{{stockVersion}}\",\n  \"counted_at\": \"{{countedAt}}\",\n  \"reason\": \"{{countReason}}\"\n}",
          "options": {
            "raw": {
              "language": "json"
            }
          }
        },
        "description": "OpenAPI operationId: registerInputCount\nAltera saldo real. Exige inputs:stock:write. Leia a versão antes de contar. Reenvio idêntico usa a mesma chave; 409 exige revisão."
      }
    },
    {
      "name": "registerInputCounts",
      "request": {
        "method": "POST",
        "header": [
          {
            "key": "Content-Type",
            "value": "application/json"
          },
          {
            "key": "Idempotency-Key",
            "value": "{{idempotencyKey}}"
          }
        ],
        "auth": {
          "type": "bearer",
          "bearer": [
            {
              "key": "token",
              "value": "{{accessToken}}",
              "type": "string"
            }
          ]
        },
        "url": "{{baseUrl}}/v1/inventory/inputs/counts/bulk?restaurant_id={{restaurantId}}",
        "body": {
          "mode": "raw",
          "raw": "{\n  \"items\": [\n    {\n      \"id\": 1,\n      \"quantidade\": \"{{countedQuantity}}\",\n      \"expected_stock_version\": \"{{stockVersion}}\",\n      \"counted_at\": \"{{countedAt}}\",\n      \"reason\": \"{{countReason}}\"\n    }\n  ]\n}",
          "options": {
            "raw": {
              "language": "json"
            }
          }
        },
        "description": "OpenAPI operationId: registerInputCounts\nAltera saldo real. Exige inputs:stock:write. Leia a versão antes de contar. Reenvio idêntico usa a mesma chave; 409 exige revisão."
      }
    },
    {
      "name": "registerIntermediaryCount",
      "request": {
        "method": "POST",
        "header": [
          {
            "key": "Content-Type",
            "value": "application/json"
          },
          {
            "key": "Idempotency-Key",
            "value": "{{idempotencyKey}}"
          }
        ],
        "auth": {
          "type": "bearer",
          "bearer": [
            {
              "key": "token",
              "value": "{{accessToken}}",
              "type": "string"
            }
          ]
        },
        "url": "{{baseUrl}}/v1/inventory/intermediaries/{{stockId}}/counts?restaurant_id={{restaurantId}}",
        "body": {
          "mode": "raw",
          "raw": "{\n  \"quantidade\": \"{{countedQuantity}}\",\n  \"expected_stock_version\": \"{{stockVersion}}\",\n  \"counted_at\": \"{{countedAt}}\",\n  \"reason\": \"{{countReason}}\"\n}",
          "options": {
            "raw": {
              "language": "json"
            }
          }
        },
        "description": "OpenAPI operationId: registerIntermediaryCount\nAltera saldo real. Exige intermediaries:stock:write. Leia a versão antes de contar. Reenvio idêntico usa a mesma chave; 409 exige revisão."
      }
    },
    {
      "name": "registerIntermediaryCounts",
      "request": {
        "method": "POST",
        "header": [
          {
            "key": "Content-Type",
            "value": "application/json"
          },
          {
            "key": "Idempotency-Key",
            "value": "{{idempotencyKey}}"
          }
        ],
        "auth": {
          "type": "bearer",
          "bearer": [
            {
              "key": "token",
              "value": "{{accessToken}}",
              "type": "string"
            }
          ]
        },
        "url": "{{baseUrl}}/v1/inventory/intermediaries/counts/bulk?restaurant_id={{restaurantId}}",
        "body": {
          "mode": "raw",
          "raw": "{\n  \"items\": [\n    {\n      \"id\": 1,\n      \"quantidade\": \"{{countedQuantity}}\",\n      \"expected_stock_version\": \"{{stockVersion}}\",\n      \"counted_at\": \"{{countedAt}}\",\n      \"reason\": \"{{countReason}}\"\n    }\n  ]\n}",
          "options": {
            "raw": {
              "language": "json"
            }
          }
        },
        "description": "OpenAPI operationId: registerIntermediaryCounts\nAltera saldo real. Exige intermediaries:stock:write. Leia a versão antes de contar. Reenvio idêntico usa a mesma chave; 409 exige revisão."
      }
    }
  ],
  "variable": [
    {
      "key": "baseUrl",
      "value": "http://localhost:3100"
    },
    {
      "key": "restaurantId",
      "value": ""
    },
    {
      "key": "stockId",
      "value": ""
    },
    {
      "key": "stockVersion",
      "value": ""
    },
    {
      "key": "countedQuantity",
      "value": ""
    },
    {
      "key": "countedAt",
      "value": ""
    },
    {
      "key": "countReason",
      "value": "Contagem física"
    },
    {
      "key": "idempotencyKey",
      "value": ""
    },
    {
      "key": "accessToken",
      "value": ""
    }
  ]
}
