v1

latestOpenAPI 3.1.02026-07-241210356.3 KB
Invoice+ - Documents

Create new document

post/books/docs/new/{docType}

Path parameters

docType'inv_tax_receipt' | 'inv_tax' | 'inv_receipt' | 'inv_proforma' | 'inv_refund' | 'crt_delivery' | 'crt_return' | 'order_purchase' | 'purchase' | 'dc_quote' | 'inv_don_receipt' | 'inv_pay_request' required

Type of document to create

Headers

api-keystring required

API Key

secret-keystring required

Secret Key

Request body

doc_datestring

string Document issue date. Format: YYYY-MM-DD. Defaults to current da

brand_uuidstring

If multiple brands exist, specify brand uuid to create document associated with a specific brand. If none provided, the default brand

previewboolean

Get a preview of the document. No document will be generated if set to true

hide_base_currencyboolean

Whether or not to hide the base currency (usually ILS) in a foreign currency document.

draftboolean

Create a draft document. No actual document will be generated if set to true

more_infostring

nullable Optional identifier. Will appear at the bottom of the document

close_docstring

UUID of a previously created document. If supplied, the new document will also close the document indicated by the UUID

cancel_docstring

UUID of a previously created document. If supplied, the new document will also cancel the document indicated by the UUID

transaction_uuidstring

UUID of a PayPlus transaction

send_document_emailboolean

Send email upon document creation. Will override the whatever's defined in your account

send_document_smsboolean

send_document_sms

callback_urlstring

If valid url is specified, payplus will send a notification to the specified URL upon successful document creation

vatType'vat-type-included' | 'vat-type-not-included' | 'vat-type-exempt'

If omitted, configuration values will be used instead

vat_percentageinteger

Vat percentage to use for calculations. If omitted, configuration values will be used instead

language'he' | 'en'
currency_codestring
conversion_ratenumber float

If document currency specified is not ILS, this value will be used as the conversion rate for all the prices into the base currency.

autocalculate_rateboolean

If the conversion rate parameter is omitted, determine conversion rate automatically

prevent_emailboolean

If true, will not send

unique_identifierstring

Arbitrary, unique string. If supplied, the system will refuse further creation attempts if it finds a duplicate, ensuring that this value will always be unique per document.

tagsstring[]

Array of arbitrary strings used to catalogue/ tag documents

totalAmountinteger

Total sum of the document.

Response

200

barcodestring
copyDocAddressstring
currency_codestring
customer_uuidstring
docUIDstring
doc_datestring
doc_typestring
{"stackTrail":"paths:/books/docs/new/{docType}:post:responses:200:content:application/json:schema:properties:more_info","oasType":"schema","type":"unknown"}
numberstring
originalDocAddressstring
total_items_base_currencyinteger
validDocumentGeneratedboolean

Example response

{
  "barcode": "472819632332439",
  "brand": {
    "name": "Company Name",
    "uuid": "67a8cc93-75ac-4832-8386-3eb5b24bf3d0"
  },
  "copyDocAddress": "https://restapi.payplus.co.il/getdoc/s/c/1fa79282-61d1-4898-b7b9-afa67f46d34a.pdf",
  "currency_code": "ILS",
  "customer": {
    "customer_name": "John Doe",
    "email": "johndoe@example.com",
    "phone": "123456789",
    "subject_code": "987654321",
    "uuid": "faa6280f-dba5-4889-9b15-de60e1527bdc",
    "vat_number": "1231231"
  },
  "customer_uuid": "faa6280f-dba5-4889-9b15-de60e1527bdc",
  "docUID": "1fa79282-61d1-4898-b7b9-afa67f46d34a",
  "doc_date": "2022-11-15",
  "doc_type": "inv_tax",
  "number": "SCP/50042",
  "originalDocAddress": "https://restapi.payplus.co.il/getdoc/s/o/1fa79282-61d1-4898-b7b9-afa67f46d34a.pdf",
  "total_items_base_currency": 150,
  "validDocumentGenerated": true
}