CopyOperationsFromDocInvoice

[POST] .../v1/purchaseoperation/copyoperationsfromdocinvoice

Copies operations from an invoice document to a partner receipt document. Copy item operations from an invoice document into a receipt-from-partner document when purchase lines should be created from invoiced items. The request requires doc_from_id and doc_to_id, leaves the source invoice unchanged and the response returns an empty object result when the copy operation completes successfully. The caller must have purchase-operation add permission for the target receipt; missing body, invalid document ids, denied access, incompatible source or target document state or storage failures are returned as HTTP 200 ErrorResult.

Request Parameters

Name Type Required Description
doc_from_id Int64 Required Source document ID to copy operations from.
doc_to_id Int64 Required Destination document ID to copy operations into.

Request Example

{
  "doc_from_id": 1,
  "doc_to_id": 1
}

Response Parameters

Name Type Description
ok Boolean Indicates whether the request completed successfully.
result Object Result object.

Response Example

{
  "ok": true,
  "result": null
}