Import Receipts
Create Receipt
REST API | docsApi/createRecipt |
The following parameters should be included in a rows
object (see example below)
Parameters | Description | Parameter Options/value | Default |
---|---|---|---|
flagwarnings | A flag indicating whether to display warnings | true / false | true |
main_info Required | stock- (object name contains data) | See table below | |
pay_types Required | Payment methods - 'cheque', 'cash', 'backDeposit', 'credit' | See tables below |
JSON Body Example
{
"rows": {
"flagwarnings": true,
"main_info": {
...
},
"pay_types": {
"cheque": {
"chequesArr": [
{
...
}
]
},
"cash": {
...
},
"bankDeposit": {
...
},
"credit": {
...
}
}
}
}
Receipts Data
The following parameters should be included in a main-info
object (see example below)
Name-trans | Type | Description | תיאור | Default |
---|---|---|---|---|
stockid | Integer number | מזהה טבלת stock. כאשר מעדכנים מסמך, חייבים להעביר מזהה | ID in the stock table. Required when updating an existing document. | 0 |
doccurr Required | string max (5) values | מטבע | Currency | From company definition |
accountkey Required | string max(15) | מפתח חשבון | Account key | |
fullname | string max(50) | שם חשבון | Account fullname | From account definition |
address | string max(50) | כתובת | Address | From account definition |
city | string max(50) | עיר | City | From account definition |
phone | string max(30) | טלפון | Phone | From account definition |
remark | string max(250) | הערות | Remarks | "" |
DocNumber | Integer number | מספר המסמך. הספרור של מסמכים בעלי ספרור קשיח נקבע בעת ההפקה | Document number. When the document numeration isunchangeable, the number is determined when the document is issued. | From company definition |
documentid Required | Integer number | סוג מסמך (לפי הגדרות בטבלת DocumentsDef) | Document type (according to the DocumentDef table) | |
contact | string max(30) | איש קשר | contact | "" |
string max(200) | כתובת דוא"ל שידור כתובת מייל אומר שליחת מקור למייל לא משנה מה מוגדר בחשבון (הפקה לא דיגיטלית או שליחה במייל לאחר תצוגה) | E-Mail address Sending an email address means the source will be sent to it regardless of what is defined the account (non-digital production or sending by email after display) | "" | |
costcode | string max(8) | קוד תמחיר קיים | Existing cost center code | "" |
issueStock | boolean | הפקת המסמך | Issue the document | TRUE |
Copies | Integer number | מספר עותקים להדפסה | Number of print copies | From company definition |
PrintStyle | Integer number | מזהה פורמט הדפסה | Print format ID | From company definition |
Payment Methods
The following parameters should be included in a pay_types
object (see example below)
Cash
The following parameters should be included in a cash
object (see example below)
Name-trans | Type | Description | תיאור | Default |
---|---|---|---|---|
suf Required | Float number | הסכום שהתקבל | The amount received | |
sufDlr | Float number | סכום משוערך | Reevaluated amount | 0 |
currencyDlr Required for foreign currency documents | string max(5) values | מטבע השיערוך | The revaluation currency | From company definition |
details | string max(20) | פרטים | details | "" |
customerId Required | string max(20) | ת.ז לקוח | customer Id |
JSON Example for a cash payment
{
"rows": {
"flagwarnings": true,
"main_info": {
"accountKey": "30002",
"documentid": "31",
"issueStock": true
},
"pay_types": {
"cash": {
"suf": "10"
}
}
}
}
Credit
tip
Automatic (instant) Credit Payment
Manual Credit Payment
The following parameters should be included in a credit
object (see example below)
Name-trans | Type | Description | תיאור | Default |
---|---|---|---|---|
maunualcreditflag | boolean | דגל המציין האם אשראי ידני / רגיל: 1= ידני 0= רגיל | A flag indicating whether the credit is manual or regular: 1= manual 0=regular | 0 |
masofid | smallint | מספר מסוף | masof (terminal) id | Manual/default terminal |
suf Required | float number | סכום | sum | 0 |
fstarstotal | float number | סכום כוכבים /מיילים /נקודות | 0 | |
type | string max(50) | סוג תשלום | Type of payment | Default |
payments | smallint | מספר תשלומים | Number of payments | Defined by card type |
firstpayment | float number | תשלום ראשון | First Payment | Calculated based on number of payments |
paymentssum | float number | תשלום קבוע | Fixed payment | Calculated based on number of payments |
fvoucher Required | string max(7) | מספר אישור | confirmation number | |
fshovar | integer number | מספר שובר | shovar number | 0 |
creditfirm | string max(50) | חברת אשראי | credit Company | Default |
last4dig Required | string max(4) | 4 ספרות אחרונות | Last 4 digits | |
fvalidmonth | string max(2) | תוקף חודש | valid month | Current month |
fvalidyear | string max(2) | תוקף שנה | valid year | Current year |
fid | string max(60) | ת.ז (באשראי ידני) | "" | |
details | string max(250) | פרטים | details | "" |
sufdlr | float number | סכום משוערך | Reevaluated amount | 0 |
currencydlr Required for foreign currency documents | string max(5) values | מטבע השערוך | The revaluation currency | From company definition |
istoken | boolean | הפקה ללא חלון תשלום | if true, make a transaction without a payment window
read more about Tokenization | false |
JSON Example for a credit payment
{
"rows": {
"flagwarnings": true,
"main_info": {
"accountKey": "30002",
"documentid": "31",
"issueStock": true
},
"pay_types": {
"credit": {
"maunualcreditflag": 1,
"suF": 100,
"fvoucher": 3659,
"last4dig": "6598",
"payments": "3",
"type": "תשלומים",
"firstpayment": 30,
"paymentssum": 35,
"istoken": true
}
}
}
}
Cheque
The following parameters should be included in a cheque
object (see example below)
Name-trans | Type | Description | תיאור | Default |
---|---|---|---|---|
pikadonFlag | bool | זיכוי קופת שיקים לפיקדון במקום קופת שיקים ברירת מחדל | Use deposit instead of regular registry | false |
chequesArr Required | See table below | מערך של שיקים | Array of cheques |
The following parameters should be included in a chequesArr
array (see example below)
Name-trans | Type | Description | תיאור | Default |
---|---|---|---|---|
cheqnumber Required | integer number | מספר שק | cheque number | |
banknumber Required | string max(2) | מספר בנק | bank number | |
branch Required | string max(3) | סניף | branch | |
bankaccnum Required | string max(20) | מספר חשבון בנק | Bank account number | |
valuedate | datetime | תאריך | date | תאריך נוכחי |
suf Required | float number | סכום | sum | |
sufdlr | float number | סכום משוערך | Reevaluated amount | 0 |
CurrencyDlr | string max(5) values | מטבע | currency | From account definition |
details | string max(20) | פרטים | sdetails | "" |
customerid | string max(11) | ת.ז. לקוח | customer id | From account definition |
JSON Example for a cheque payment
{
"rows": {
"flagwarnings": true,
"main_info": {
"accountKey": "30002",
"documentid": "31",
"issueStock": true
},
"pay_types": {
"cheque": {
"chequesArr": [
{
"CheqNumber": "125545",
"BankNumber": "12",
"Branch": "5",
"BankAccNum": "785",
"ValueDate": "2020-01-02",
"Suf": "60",
"SufDlr": "3.56",
"CurrencyDlr": "$",
"Details": ""
},
{
"CheqNumber": "125547",
"BankNumber": "12",
"Branch": "5",
"BankAccNum": "785",
"ValueDate": "2020-01-02",
"Suf": "100",
"SufDlr": "3.56",
"CurrencyDlr": "$",
"Details": ""
}
]
}
}
}
}
Bank Deposit
The following parameters should be included in a bankDeposit
object (see example below)
Name-trans | Type | Description | תיאור | Default |
---|---|---|---|---|
suf Required | float number | סכום | sum | 0 |
sufdlr | float number | סכום משוערך | Reevaluated amount | 0 |
currencydlr Required for foreign currency documents | string max(5) values | מטבע השערוך | The revaluation currency | From account definition |
bankacc Required | string max(15) | מספר חשבון בנק | Bank accoun | |
duedate | datetime | תאריך ערך | due date | Current date |
details | string max(40) | פרטים | details | "" |
JSON Example for a bank deposit payment
{
"rows": {
"flagwarnings": true,
"main_info": {
"accountKey": "30002",
"documentid": "31",
"issueStock": true
},
"pay_types": {
"bankDeposit": {
"suf": "14",
"bankAcc": "10002"
}
}
}
}
JSON Example
{
"rows": {
"flagwarnings": true,
"main_info": {
"accountKey": "30002",
"documentid": "31",
"issueStock": true
},
"pay_types": {
"cheque": {
"chequesArr": [
{
"CheqNumber": "125545",
"BankNumber": "12",
"Branch": "5",
"BankAccNum": "785",
"ValueDate": "2020-01-02",
"Suf": "60",
"SufDlr": "3.56",
"CurrencyDlr": "$",
"Details": ""
},
{
"CheqNumber": "125547",
"BankNumber": "12",
"Branch": "5",
"BankAccNum": "785",
"ValueDate": "2020-01-02",
"Suf": "100",
"SufDlr": "3.56",
"CurrencyDlr": "$",
"Details": ""
},
{
"CheqNumber": "127545",
"BankNumber": "17",
"Branch": "5",
"BankAccNum": "785",
"ValueDate": "2020-01-02",
"Suf": "40",
"SufDlr": "3.56",
"CurrencyDlr": "$",
"Details": ""
}
]
},
"cash": {
"suf": "10"
},
"bankDeposit": {
"suf": "14",
"bankAcc": "10002"
},
"credit": {
"maunualcreditflag": 1,
"suF": 100,
"fvoucher": 3659,
"last4dig": "6598",
"payments": "3",
"type": "תשלומים",
"firstpayment": 30,
"paymentssum": 35
}
}
}
}
Receipts OutputData
Name | Options |
---|---|
stockid | New stockid |
statusCode | 200 (OK) / 500 (error) |
status | For errors only: “error” |
message | Error Message / "הקבלה עודכנה למאגר זמני" |
docUrl | document url |