-- Tax Receipts - Automatic Credit
Import Tax Receipts - Credit
The following parameters should be included in a credit
object with maunualcreditflag=0
(see examples 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 |
URL Required | string max(90) | כתובת URL להפניה לאחר התשלום | A URL to redirect to after successful payment | |
istoken | boolean | הפקה ללא חלון תשלום | if true, make a transaction without a payment window
read more about Tokenization | false |
masofid | smallint | מספר מסוף | masof (terminal) id | Manual/default terminal |
suf Required | float number | סכום | sum | |
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 | string max(7) | מספר אישור | confirmation number | |
fshovar | integer number | מספר שובר | shovar number | 0 |
creditfirm | string max(50) | חברת אשראי | credit Company | Default |
last4dig | 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 |
JSON Examples
{
"data": {
"main_info": {
"DocumentID": "2",
"AccountKey": "30001",
"Tftal": "234",
"Osek874": "000000000"
},
"moves": [
{
"ItemKey": "1",
"Price": "100",
"Quantity": "2",
"Tftal": "200"
}
],
"Payment": {
"credit": {
"suF":234,
"url":"https://lb1.wizcloud.co.il/IWIZ/html/kabala_User_temp.html"
}
}
}
}
{
"data": {
"main_info": {
"issueStock": "true",
"deleteTemp": "false",
"flagwarnings": "1",
"StockID": "0",
"DocumentID": "2",
"AccountKey": "30001",
"AccountName": "name acc 111",
"Phone": "",
"Details": "my doc details",
"Osek874": "000000000",
"Tftal":"234"
},
"moves": [
{
"ItemKey": "1",
"ItemName": "name item 11",
"Price": "100",
"Quantity": "2",
"Tftal": "200",
"CurrencyCode": "ש\"ח",
"Details": "my details 11"
}
],
"Payment": {
"cash": {
"suf": "34"
},
"credit": {
"suf": 100,
"masofid": "4",
"URL": "https://lb1.wizcloud.co.il/IWIZ/html/kabala_User_temp.html",
"sufdlr": 30,
"currencydlr": "$",
"fstarstotal": 0,
"payments": 2,
"firstPayment":50,
"paymentssum": "50",
"type": "תשלומים",
"details": " API Example"
},
"cheque": {
"pikadonFlag": "true",
"chequesArr": [
{
"CheqNumber": "125545",
"BankNumber": "12",
"Branch": "5",
"BankAccNum": "999999",
"ValueDate": "2020-01-02",
"Suf": "60",
"SufDlr": "3.56",
"CurrencyDlr": "$",
"Details": ""
},
{
"CheqNumber": "127545",
"BankNumber": "17",
"Branch": "5",
"BankAccNum": "999999",
"ValueDate": "2020-01-02",
"Suf": "40",
"SufDlr": "3.56",
"CurrencyDlr": "$",
"Details": ""
}
]
}
}
}
}
Tax Receipts Credit Responses
Success
If the requests is successful it will return a response with a statusCode
206.
statusCode | 206 - Success |
stockid | The ID that's added to the "stock" table |
CGUrl | A link to a Credit Guard page, where the user needs to fill in their credit card info |
Example
{
"statusCode": 206,
"stockid": 6443,
"CGUrl": "https://cgmpiuat.creditguard.co.il/CGMPI_Server/PerformTransaction?txId=dae90e12-fd1c-4519-b625-f2bc939fceeb"
}
After a successful request the user will be redirected to the address submited in the "URL" parameter.
Error
status | "error" | ||||||
statusCode | between 400-600 | ||||||
message | An array of errors, each error containing:
|
Error - Call Credit Card Comapny
If the error says to "Call the credit card company", you'll need to send a followup request with the confirmation number the credit card company provides.
/docsApi/responseCG_confirmNum
Parameters | Description | Required |
---|---|---|
stockid | from the error response | required |
confirmNum | credit card company's confirmation number | required |
cardToken | from the error response | required |
parmx | from the error response | |
url | response destination url |