Cross-Reference One Document with Another (Cross Document)
When should this function be used?
When a tax invoice is issued only for the amount the customer is expected to pay in the future, and the corresponding document is issued only afterward, this function can be used to cross-reference the documents.
Note: Cross-referencing documents is neither essential nor mandatory. If it is possible to associate all documents with the same customer card, this is the preferred option. Keeping all documents under the customer's card will help prevent future issues, such as confusion or errors in customer-card balances.
When cross-referencing documents, keep in mind that an incorrect cross-reference may cause problems with data accuracy, particularly regarding card balances. Therefore, cross-referencing should be performed only with the correct documents.
The JSON function is available at the following link:
Request method: POST.
Cross document
https://secure.cardcom.solutions/api/v11/Documents/CrossDocument
The following parameters must be passed to the Cross Document function.
Legend:
Red parameter – required
Bold parameter – recommended
Parameter that is neither red nor bold – optional
| No. | Parameter | Possible example values | Description |
| 1 | ApiName | "test2025" | Interface username. This parameter must be obtained from the business. |
| 2 | ApiPassword | "kzFKfohEvL6AOF8aMEJz" | API password, intended for refunds and transaction cancellations. |
| 3 | FromDocNumber | 500 | The receipt or tax invoice to which the document will be cross-referenced. |
| 4 | FromDocType |
1 – Tax invoice-receipt 2 – Credit invoice and refund 3 – Nonprofit receipt / VAT-exempt receipt 4 – Nonprofit credit receipt (refund) 50 – Price quote 100 – Order (unpaid) 101 – Order confirmation – website (internal document; not for bookkeeping) – paid order 102 – Order credit – website (internal document; not for bookkeeping) – credited order 200 – Delivery note 210 – Return note 300 – Transaction account 301 – Payment request 302 – Payment request cancellation 303 – Pro forma receipt account 305 – Tax invoice 330 – Credit invoice 400 – Receipt (for an invoice) 410 – Customer refund (credit receipt) 405 – Donation receipt 406 – Donation receipt credit (refund) 303 – Receipt account (similar to an invoice for an עוסק פטור; rarely used) 304 – Credit receipt account |
The document type to which the document will be cross-referenced. |
| 5 |
ToDocumentsList Array of objects. |
DocNumber – INT -------------------------------------------------------- DocType – INT -------------------------------------------------------- PartialSumToCorss – INT |
ToDocumentsList The second document for cross-referencing. --- DocNumber – Document number to cross-reference. --- DocType – Type of the document to cross-reference. This is the same value as FromDocType. --- PartialSumToCorss – The partial amount to cross-reference with the document. This function can be performed multiple times for the same documents. |
Cross Document response
| No. | Parameter | Possible example values | Description |
| 1 | ResponseCode | 0 | Response code. If it equals zero, the function was executed successfully. Any other response indicates that the operation was unsuccessful. |
| 2 | Description | "OK" | Response description. “OK” indicates success. |
Below is an example of the function together with its response.
Example request for cross-referencing documents:
Response received: