API v1 Reference

Update Payment

The Update Payment method allows you to update a payment for an existing transaction.

REST

Request

https://api.neoncrm.com/neonws/services/api/common/updatePayment?responseType=json&userSessionId=[sessionId]&payment.paymentId=58415&payment.amount=50&payment.tenderType.id=4&payment.creditCardOnlinepayment.cardNumber=4444111111111111&payment.creditCardOnlinepayment.expirationMonth=01&payment.creditCardOnlinepayment.expirationYear=2020&payment.creditCardOnlinepayment.cardType.name=Visa&payment.creditCardOnlinepayment.CVV2=999&payment.creditCardOnlinepayment.cardHolder=Example%20Person

Response


   {
    "updatePaymentResponse": {
        "operationResult": "SUCCESS",
        "responseDateTime": "2018-01-19T16:32:00.926+0000",
        "paymentId": 58416,
        "transaction": {
            "transactionId": 38422,
            "transactionStatus": "SUCCEED",
            "payments": {
                "payment": [
                    {
                        "paymentId": 58416,
                        "amount": 50,
                        "tenderType": {
                            "id": "4",
                            "name": "credit card (online)"
                        },
                        "creditCardOnlinePayment": {
                            "cardNumber": "4111111111111111",
                            "expirationMonth": 1,
                            "expirationYear": 2020,
                            "cardType": {
                                "code": "v",
                                "name": "Visa"
                            },
                            "cardHolder": "Example Person"
                        }
                    }
                ]
            }
        }
    }
}

Request Parameters

Name Required Description
Payments
payment.paymentId Yes The unique ID of the payment record. Note that this is not the same as a transaction ID. A transaction may have multiple payments associated with it.
payment.amount Yes Payment amount
payment.fairMarketValue When using the “In-Kind” tender type (ID #5), you may supply the fair market value amount for the donation.
payment.tenderType.id Yes * Possible values can be retrieved from List Tenders method. Required if tenderType.name is not provided.
payment.tenderType.name Yes * Possible values can be retrieved from List Tenders method. Required if tenderType.id is not provided.
payment.note
Credit Card Online Payment
The following fields are applicable if tenderType = 4 (credit card online). NeonPay is currently not supported for credit card online payments.
payment.creditCardOnlinepayment.cardNumber Yes * Required for third-party gateways. See Payments for further documentation.
payment.creditCardOnlinepayment.token Yes * Required if using NeonPay or Neon Payment Processing. See Payments for further documentation.
payment.creditCardOnlinepayment.expirationMonth Yes
payment.creditCardOnlinepayment.expirationYear Yes
payment.creditCardOnlinepayment.cardType.id Yes * Possible values can be retrieved from List Credit Card Types method. Required when cardType.name is not provided.
payment.creditCardOnlinepayment.cardType.name Yes * Possible values: American Express, Discover, MasterCard, Visa. Can be retrieved from List Credit Card Types method. Required when cardType.id is not provided.
payment.creditCardOnlinepayment.CVV2 Yes
payment.creditCardOnlinepayment.cardHolder Yes Name of credit card holder, as shown on the card.
payment.creditCardOnlinepayment.cardHolderEmail Yes * Required if using Neon Payment Processing.
payment.creditCardOnlinepayment.billingAddressLine1
payment.creditCardOnlinepayment.billingAddressLine2
payment.creditCardOnlinepayment.city
payment.creditCardOnlinepayment.state.code Possible values can be retrieved from the List States method. Required when state.name is not provided.
payment.creditCardOnlinepayment.state.name Possible values can be retrieved from the List States method. Required when state.code is not provided.
payment.creditCardOnlinepayment.province
payment.creditCardOnlinepayment.country.id Possible values can be retrieved from the List Countries method. Required when country.name is not provided.
payment.creditCardOnlinepayment.country.name Possible values can be retrieved from the List Countries method. Required when country.id is not provided.
payment.creditCardOnlinepayment.zipCode
payment.creditCardOnlinepayment.zipCodeSuffix
Credit Card Offline Payment
The following fields are applicable if tenderType = 2 (credit card offline, on-site credit card machine)
payment.creditCardOfflinepayment.cardNumber
payment.creditCardOfflinepayment.expirationMonth
payment.creditCardOfflinepayment.expirationYear
payment.creditCardOfflinepayment.cardType.id Possible values can be retrieved from List Credit Card Types method. Required when cardType.name is not provided.
payment.creditCardOfflinepayment.cardType.name Possible values can be retrieved from List Credit Card Types method. Required when cardType.id is not provided.
payment.creditCardOfflinepayment.CVV2
payment.creditCardOfflinepayment.cardHolder
payment.creditCardOfflinepayment.billingAddressLine1
payment.creditCardOfflinepayment.billingAddressLine2
payment.creditCardOfflinepayment.city
payment.creditCardOfflinepayment.state.code Possible values can be retrieved from the List States method. Required when state.name is not provided.
payment.creditCardOfflinepayment.state.name Possible values can be retrieved from the List States method. Required when state.code is not provided.
payment.creditCardOfflinepayment.province
payment.creditCardOfflinepayment.country.id Possible values can be retrieved from the List Countries method. Required when country.name is not provided.
payment.creditCardOfflinepayment.country.name Possible values can be retrieved from the List Countries method. Required when country.id is not provided.
payment.creditCardOfflinepayment.zipCode
payment.creditCardOfflinepayment.zipCodeSuffix
eCheck / ACH Payment
The following fields are applicable if tenderType = 12 (E-Check/ACH)
payment.echeckPayment.institution
payment.echeckPayment.routingNumber Yes
payment.echeckPayment.accountNumber Yes
payment.echeckPayment.accountOwner
payment.echeckPayment.CheckNumber
payment.echeckPayment.accountType Possible values: Checking, Saving
Check Payment
The following fields are applicable if tenderType = 3 (Check)
payment.checkPayment.institution
payment.checkPayment.routingNumber
payment.checkPayment.accountNumber
payment.checkPayment.accountOwner
payment.checkPayment.CheckNumber
payment.checkPayment.accountType Possible values: Checking, Saving

Response Parameters

Name Required Description
donationId Yes The ID of the donation transaction (not the account).
transaction.transactionId Yes Transaction ID
transaction.transactionStatus Yes Possible values: Pending, Processing, Succeed, Declined, Error, Scheduled, Cancelled, Deferred
transaction.payments.payment Yes Transaction details of the payment

Error Codes

Code Text Description
101 Payment amount is required.
102 Tender type id or name is required.
103 Tender type id or name is invalid.
104 Echeck routing number is required.
105 Echeck account number is required.
106 Echeck account owner is required.
107 Credit card number is required.
108 Credit card expiration date is required.
109 Credit card CVV2 is required.
110 Credit card type is invalid.
150 Unable to process payment.
151 Payment id is invalid.
152 Payment id is required.
153 Succeed credit card online or e-check payment cannot be reprocessed.