-- Receipts - Automatic Credit
Import 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
{
"rows": {
"main_info": {
"accountKey":"30001",
"documentid":"31"
},
"pay_types": {
"credit": {
"suF":50,
"url":"https://lb1.wizcloud.co.il/IWIZ/html/kabala_User_temp.html"
}
}
}
}
{
"rows": {
"flagwarnings": true,
"main_info": {
"accountKey": "30002",
"documentid": "31",
},
"pay_types": {
"credit": {
"URL": "https://lb1.wizcloud.co.il/IWIZ/html/kabala_User_temp.html",
"suF": 100.00,
"sufdlr": 30,
"currencydlr": "$",
"fstarstotal": 0,
"masofid":5,
"payments": 3,
"firstPayment": "34",
"paymentsSum": "33",
"type": "תשלומים",
"details": " API Example"
}
}
}
}
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 |