Error Conditions

List of errors

Common Error Handling

accountType is case sensitive and only accepts checking or savings.

Payload:

"bankName":"@@TESTBANKNAME@@",
	"accountType":"Checking",
	"routingNumber":"061009052",
	"accountNumber":"100090009",
	"checkStartNumber":1,
	"address":
	{
    "street1":"2334 Pencil Avenue",
		"city":"Seattle",
		"state":"WA",
		"postalCode":"30004"
  }
}

Response:

{
    "message": "Validation errors",
    "errors": [
        {
            "code": "INVALID_REQUEST_PARAMETER",
            "errors": [
                {
                    "code": "ENUM_MISMATCH",
                    "params": [
                        ""
                    ],
                    "message": "No enum match for: Checking",
                    "path": [
                        "accountType"
                    ]
                }
            ],
            "in": "body",
            "message": "Invalid parameter (checkAccount): Value failed Schema validation",
            "name": "checkAccount",
            "path": [
                "paths",
                "/buyer/{buyerId}/checkAccount/add",
                "post",
                "parameters",
                "1"
            ]
        }
    ]
}

Duplicate checking account being added.

Response:

{
    "message": "pages.buyer.errors.validation.checkAccounts.duplicate"
}

Routing number format error.

Payload:

{
	"bankName":"@@TESTBANKNAME@@",
	"accountType":"checking",
	"routingNumber":"06100906652",
	"accountNumber":"100090044409",
	"checkStartNumber":1,
	"address":
	{
    "street1":"2334 Pencil Avenue",
		"city":"Seattle",
		"state":"WA",
		"postalCode":"30004"
  }
}

Response:

{
    "message": "Validation errors",
    "errors": [
        {
            "code": "INVALID_REQUEST_PARAMETER",
            "errors": [
                {
                    "code": "PATTERN",
                    "params": [
                        "((^$)|^([0-9]){9}$)",
                        "06100906652"
                    ],
                    "message": "String does not match pattern ((^$)|^([0-9]){9}$): 06100906652",
                    "path": [
                        "routingNumber"
                    ],
                    "description": "A valid bank routing number"
                }
            ],
            "in": "body",
            "message": "Invalid parameter (checkAccount): Value failed Schema validation",
            "name": "checkAccount",
            "path": [
                "paths",
                "/buyer/{buyerId}/checkAccount/add",
                "post",
                "parameters",
                "1"
            ]
        }
    ]
}

No Payment Specified Error

When sending a pif transaction. If no payment is set, the system will set the the payment type as "Check" by default. Then the payment status will be set to "Pending". Our system will then check if the buyer has a checking account.

Payload Example:

[
    {
        "nid": "KPSANDBOX",
        "fid": "KPSANDBOX",
        "buyerId": "JTester2",
        "fileDate": "2019-11-11",
        "transactionId": "232448e-2df5g-e93-2d443e2-es",
        "accountType": "{No payment set}",
        "bankAccountId": "",
        "amount": 27.20,
        "invoiceNumbers": [
            "0024"
        ],
        "invoiceDates": [
            "2019-11-21"
        ],
        "invoiceAmounts": [
            11.11
        ],
        "invoiceTotals": [
            11.11
        ],
        "invoiceDescriptions": [
            "inv desc03"
        ],
        "poNumber": "0024",
        "poDate": "2019-11-11",
        "supplierId": "JN_supplier",
        "supplierName": "JN_supplier",
        "supplierAddressLine1": "1112 Main Street",
        "supplierAddressLine2": "Unit Z",
        "supplierCity": "Alpharetta",
        "supplierState": "GA",
        "supplierZip": "30004",
        "supplierEmail": "[email protected]",
        "reference1": "reference 1",
        "reference2": "reference 2",
        "reference3": "reference 3",
        "reference4": "reference 4",
        "reference5": "reference 5",
        "emailnotes": "email [email protected]"
    }
]

Response:

{
    "fileInfo": {
        "fileId": "38eb7845-9616-567f-83e2-7e06c3a0e78f",
        "fileName": "KPSANDBOX.KPSANDBOX.pif.WEB_20191204104630.csv"
    },
    "rec": [
        {
            "id": "33077940-aa20-5530-a76f-f0f459220374",
            "originalAmount": 27.2,
            "paymentAuthMessage": null,
            "paymentMethod": "Check",
            "paymentStatus": "Pending",
            "transactionId": "233348e-2df5g-e93-2d443e2-es",
            "paymentType": "Check",
            "accountType": "CHK",
            "achTransactionType": null,
            "isProxyPay": false,
            "institution": {
                "id": "60ea3ec4-35b3-5358-9f0e-6b8e812fe2df",
                "fid": "KPSANDBOX"
            },
            "network": {
                "id": "22859b04-d3f6-5eae-bbbd-435ea27c28d6",
                "nid": "KPSANDBOX"
            },
            "buyer": {
                "id": "848f937a-b565-5108-837c-594e31774ab5",
                "bid": "JTester2"
            },
            "supplier": {
                "sid": "JN_supplier2"
            }
        }
    ]
}

If the buyer doesn't have a checking account setup. The transaction will fail. To see why move the cursor over the failed status. A pop up will say "Unable to locate Valid Check account for Buyer".

2738

Sending checking payments with the invalid amount and type.

{
    "statusCode": 400,
    "message": "Invalid Amount - 200.9809",
    "info": {
        "index": 0,
        "record": {
            "buyerId": "JNTester",
            "fileDate": "2019-11-27T00:00:00.000Z",
            "transactionId": "22244e-2g-e93-2d43e2-es",
            "accountType": "CHK",
            "amount": 200.9809,
            "poNumber": "0024",
            "poDate": "2019-11-21",
        					}
        } 
}
{
    "message": "Validation errors",
    "errors": [
        {
            "code": "INVALID_REQUEST_PARAMETER",
            "errors": [
                {
                    "code": "INVALID_TYPE",
                    "params": [
                        "number",
                        "string"
                    ],
                    "message": "Expected type number but found type string",
                    "path": [
                        "0",
                        "amount"
                    ]
                }
            ],
            "in": "body",
            "message": "Invalid parameter (pifTransactions): Value failed Schema validation",
            "name": "pifTransactions",
            "path": [
                "paths",
                "/pifTransactions/json",
                "post",
                "parameters",
                "0"
            ]
        }
    ]
}