Ditextil Inventory

Operaciones completas para la API de inventario Ditextil

📝 Borrador (texto) → Crear Borrador desde Texto

AI-generated

Summary

Creates a draft sales order or reception from free-form text by POSTing it to the Ditextil API's text-drafts endpoint (/api/orders/text-drafts). The draft is created for later review and confirmation.

Inputs

  • Tipo (orderType) — Whether the draft is a sale ("sales", default) or a reception ("reception"). Sent as order_type.
  • Texto del Pedido / Recepción (rawText) (required) — The raw order or reception text to turn into a draft. Sent as raw_text. The API does the parsing.
  • ID Bodega (draftWarehouseId) — Warehouse to associate with the draft, chosen from a list loaded from the API. Sent as warehouse_id only if set.

Output shape

The JSON response from the Ditextil API for the created draft, returned as one or more n8n items per input item. The exact fields come from the API and are not defined in the node.

The request also sends source 'n8n-community-node' and created_by 'n8n', and these are fixed. It runs once per input item. With Continue On Fail enabled, a failed item returns an item with an 'error' message. The node requires the ditextilApi credential.

Examples

Example 1: Turn a WhatsApp sales message into a pending draft for review.

Tipo=Venta, Texto del Pedido = {{$json.message}}, ID Bodega = main warehouse.

Example 2: Draft a supplier delivery from pasted text.

Tipo=Recepción, Texto = delivery note text, ID Bodega left empty.

Links

Discussion