API v1 Reference

Create Recurring Donation

This request creates a recurring donation schedule. The payment details will be stored for all future payments. The first instance of the donation schedule will process on the date specified for “Next Date”.

REST

Request

https://api.neoncrm.com/neonws/services/api/donation/createRecurringDonation?userSessionId=T1361502539704&recurringDonation.recurringPeriod=6&recurringDonation.recurringPeriodType=YEAR&recurringDonation.nextDate=2013-02-25&recurringDonation.accountId=123941&recurringDonation.amount=49&recurringDonation.purpose.id=26&recurringDonation.campaign.id=243&recurringDonation.fund.id=11&payment.amount=49&payment.note=for membership term 507&payment.tenderType.id=4&payment.creditCardOnlinePayment.cardNumber=4757077614429236&payment.creditCardOnlinePayment.expirationMonth=9&payment.creditCardOnlinePayment.expirationYear=15&payment.creditCardOnlinePayment.cardType.name=visa&payment.creditCardOnlinePayment.CVV2=201&payment.creditCardOnlinePayment.billingAddressLine1=14/349 Geoge Street&payment.creditCardOnlinePayment.city=Chicago&payment.creditCardOnlinePayment.state.code=IL&payment.creditCardOnlinePayment.country.id=1&payment.creditCardOnlinePayment.zipCode=60009&payment.creditCardOnlinePayment.cardHolder=Dark Smith

Response

{
    "createRecurringDonation": {
        "operationResult": "SUCCESS",
        "responseMessage": "RecurringDonation created.",
        "responseDateTime": "2013-02-21T21:09:04.940-06:00",
        "recurringDonationId": 190
    }
}

SOAP

Request

<soapenv:envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:neon="http://www.z2systems.com/schemas/neonws/">
   <soapenv:header>
       <soapenv:body>
          <neon:createrecurringdonationrequest>
            <usersessionid>T1361757200216</usersessionid>
             <recurringdonation>
               <accountid>123941</accountid>
                <amount>41</amount>
               <purpose>
                   <id>26</id>
                </purpose>
               <campaign>
                   <id>243</id>
               </campaign>
                <fund>
                   <id>11</id>
                 </fund>
               <recurringperiod>12</recurringperiod>
                <recurringperiodtype>MONTH</recurringperiodtype>
                <nextdate>2012-03-21</nextdate>
             </recurringdonation>
                 <payment>
               <amount>41</amount>
               <note>testing payment</note>
                <tendertype>
                   <id>4</id>
                </tendertype>
                <creditcardonlinepayment>
                   <cardnumber>4757077614429236</cardnumber>
                   <expirationmonth>9</expirationmonth>
                   <expirationyear>14</expirationyear>
                   <cardtype>
                       <code>V</code>
                   </cardtype>
                   <cvv2>231</cvv2>
                  <cardholder>William Smith</cardholder>
                   <billingaddressline1>14/349 Geoge Street</billingaddressline1>
                   <billingaddressline2></billingaddressline2>
                   <city>Chicago</city>
                   <state>
                      <code>IL</code>
                   </state>
                   <country>
                      <id>1</id>
                  </country>
                   <zipcode>60000</zipcode>
                   <zipcodesuffix>123</zipcodesuffix>
               </creditcardonlinepayment>
            </payment>
            </neon:createrecurringdonationrequest>
       </soapenv:body>
    </soapenv:header>
</soapenv:envelope>

Response

<soap:envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
   <soap:body>
      <ns2:createrecurringdonationresponse xmlns:ns2="http://www.z2systems.com/schemas/neonws/">
         <operationresult>SUCCESS</operationresult>
         <responsemessage>RecurringDonation created.</responsemessage>
         <responsedatetime>2013-02-24T19:53:26.346-06:00</responsedatetime>
         <recurringdonationid>193</recurringdonationid>
      </ns2:createrecurringdonationresponse>
   </soap:body>
</soap:envelope>

Request Parameters

Name Required Description
recurringDonation.recurringPeriod Yes Number that precedes recurringPeriodType. Example: 1 MONTH means one donation per month.
recurringDonation.recurringPeriodType Yes Possible values: YEAR MONTH DAY LIFE WEEKLY
recurringDonation.nextDate Yes Date the first donation in this series will be processed. Format: 2013-02-25
recurringDonation.endDate Date the recurring donation series ends. Format: 2013-02-25
recurringDonation.accountId Yes Account ID of constituent to whom this donation will be credited
recurringDonation.amount Yes Dollar amount of donation
recurringDonation.campaign.id Possible values can be retrieved from List Campaigns method. Required if campaign.name is not provided.
recurringDonation.campaign.name Possible values can be retrieved from List Campaigns method. Required if campaign.id is not provided.
recurringDonation.purpose.id Possible values can be retrieved from List Purposes method. Required if purpose.name is not provided.
recurringDonation.purpose.name Possible values can be retrieved from List Purposes method. Required if purpose.id is not provided.
recurringDonation.fund.id Possible values can be retrieved from List Funds method. Required if fund.name is not provided.
recurringDonation.fund.name Possible values can be retrieved from List Funds method. Required if fund.id is not provided.
Payments
payment.amount Yes Payment amount
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)
Payment.creditCardOnlinePayment.cardNumber Yes * Required unless using Neon Payment Processing.
Payment.creditCardOnlinePayment.token Yes * Required if using Neon Payment Processing. Use Stripe Elements client library to generate this token. Stripe API Key can be retrieved using the Retrieve Payment Processor Settings method.
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 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
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 Yes
Payment.echeckPayment.CheckNumber
Payment.echeckPayment.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.
111 Billing Address state id or name is invalid.
112 Billing Address country id or name 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.
11003 Amount is required
11004 Donation date is required.
11005 Fund ID or Name is invalid
11006 Campaign ID or Name is invalid
11007 Purpose ID or Name is invalid
11010 Recurring period is required
11011 Recurring period type is required
11012 Recurring next date is required
11013 Recurring donation tender type is not supported