Skip to main content
POST
/
api
/
v1
/
stock-movements
Crear movimiento de stock
curl --request POST \
  --url https://api.lapyme.com.ar/api/v1/stock-movements \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --header 'Idempotency-Key: <idempotency-key>' \
  --data '
{
  "warehouse_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "mode": "delta",
  "operation_date": "2023-11-07T05:31:56Z",
  "reason": "<string>",
  "items": [
    {
      "product_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
      "quantity": 1
    }
  ],
  "direction": "inbound",
  "notes": "<string>"
}
'
{
  "request_id": "<string>",
  "data": {
    "stock_movement_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
    "transaction_group_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
    "affected_product_ids": [
      "3c90c3cc-0d44-4b50-8888-8dd25736052a"
    ],
    "idempotent_replay": true
  },
  "warnings": [
    "<unknown>"
  ]
}

Documentation Index

Fetch the complete documentation index at: https://docs.lapyme.com.ar/llms.txt

Use this file to discover all available pages before exploring further.

Authorizations

Authorization
string
header
required

Incluí tu API key en el header Authorization con el prefijo Bearer.

Headers

Idempotency-Key
string
required

Clave única para evitar duplicados al reintentar el mismo movimiento de stock.

Required string length: 1 - 255
X-Request-Id
string

ID opcional de la solicitud para trazabilidad. Si se omite, el servidor genera uno.

Required string length: 1 - 255

Body

application/json
warehouse_id
string<uuid>
required
Pattern: ^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$
mode
enum<string>
required
Available options:
delta,
replace
operation_date
string<date-time>
required
Pattern: ^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))T(?:(?:[01]\d|2[0-3]):[0-5]\d(?::[0-5]\d(?:\.\d+)?)?(?:Z))$
reason
string
required
Required string length: 1 - 200
items
object[]
required
Required array length: 1 - 500 elements
direction
enum<string>
Available options:
inbound,
outbound
notes
string
Maximum string length: 2000

Response

Movimiento de stock creado exitosamente

request_id
string
required
data
object
required
warnings
any[]
required