We are still not clear about the API push from Purchase Orders. In what situation do they go as Purchase Orders and in what situations do they go as sales orders?
purchase order
,api
The API behaviour depends on who the order is being pushed to:
• If the order is pushed to the vendor, it is transmitted as a Purchase Order.
• If the order is pushed to the agent, it is transmitted as a Sales Order. The agent can then raise the corresponding Indent Order to the supplier.
If a company exists in both the Vendor list and the Agent list, the system first evaluates the Agent record and then the Vendor record for the respective Purchase Order.
• If no Agent is specified in the Purchase Order, the system treats the transaction as a Vendor transaction and pushes it as a Purchase Order.
• If an Agent is specified in the Purchase Order, the system treats the transaction as an Agent transaction and pushes it as a Sales Order.
In summary:
Vendor (no Agent specified) → Purchase Order
Agent specified → Sales Order → Indent Order → Supplier
Note 1: The above behaviour is applicable to Tuhund-to-Tuhund integration and is the standard logic used by the system.
Note 2: Any subsequent processing of the order by the receiving party depends on their business workflow and system configuration. For example, in certain OEM procurement scenarios, a Purchase Order received by a vendor may subsequently result in separate Purchase Orders being generated for one or more OEMs. This is a business workflow and not part of the API transmission logic itself.









