35
Web Active Corporation Direct Debit Web Service Data type and field specifications Michael Nordling 2008-03-31 Version 1.0

Direct debit web services - eWAY AustraliaCustomerID Direct debit customer id long 12 InvoiceReference A reference to your own invoice system for the purchase. string 50 InvoiceDescription

  • Upload
    others

  • View
    2

  • Download
    0

Embed Size (px)

Citation preview

Page 1: Direct debit web services - eWAY AustraliaCustomerID Direct debit customer id long 12 InvoiceReference A reference to your own invoice system for the purchase. string 50 InvoiceDescription

Web Active Corporation

Direct Debit Web

Service Data type and field specifications

Michael Nordling

2008-03-31

Version 1.0

Page 2: Direct debit web services - eWAY AustraliaCustomerID Direct debit customer id long 12 InvoiceReference A reference to your own invoice system for the purchase. string 50 InvoiceDescription

Contents

Introduction..................................................................................................................................... 4

Data Field Specifications.................................................................................................................. 5

Soap header............................................................................................................................ 5

Parameter ............................................................................................................................... 5

CreateCustomer...................................................................................................................... 5

CreatePayment ....................................................................................................................... 7

CreateRecurringPayment........................................................................................................ 8

GetCustomerDirectDebitStatus .............................................................................................. 9

GetPayments ........................................................................................................................ 10

QueryCustomer .................................................................................................................... 11

QueryPayment...................................................................................................................... 12

QueryRecurringPayment ...................................................................................................... 13

UpdatePayment.................................................................................................................... 14

UpdateRecurringPayment .................................................................................................... 15

UpdateCustomer .................................................................................................................. 16

DeleteCustomer.................................................................................................................... 18

DeleteRecurringPayment...................................................................................................... 18

DeletePayment ..................................................................................................................... 19

Appendix A: Example Request and Response Formats................................................................. 20

CreateCustomer.................................................................................................................... 20

CreatePayment ..................................................................................................................... 21

CreateRecurringPayment...................................................................................................... 22

GetCustomerDirectStatus..................................................................................................... 23

GetPayments ........................................................................................................................ 24

Page 3: Direct debit web services - eWAY AustraliaCustomerID Direct debit customer id long 12 InvoiceReference A reference to your own invoice system for the purchase. string 50 InvoiceDescription

QueryCustomer .................................................................................................................... 26

QueryPayment...................................................................................................................... 27

QueryRecurringPayment ...................................................................................................... 28

UpdatePayment.................................................................................................................... 29

UpdateRecurringPayment .................................................................................................... 30

UpdateCustomer .................................................................................................................. 31

DeleteRecurringPayment...................................................................................................... 33

DeletePayment ..................................................................................................................... 34

Page 4: Direct debit web services - eWAY AustraliaCustomerID Direct debit customer id long 12 InvoiceReference A reference to your own invoice system for the purchase. string 50 InvoiceDescription

Introduction This document specifies the methods which are available in the direct debit web service. It also

explains the request and response format of the web service; field specification and validation

required in managing direct debit customers and payments.

The following methods are available.

• CancelPayment

• CreateCustomer

• CreatePayment

• CreateRecurringPayment

• GetCustomerDirectDebitStatus

• GetPayments

• QueryCustomer

• QueryPayment

• QueryRecurringPayment

• UpdatePayment

• UpdateRecurringPayment

• UpdateCustomer

• DeleteRecurringPayment

• DeletePayment

To able to call the above web service methods, eWAYCustomerID, username and password

needs to be specified in the soap header for each request

Page 5: Direct debit web services - eWAY AustraliaCustomerID Direct debit customer id long 12 InvoiceReference A reference to your own invoice system for the purchase. string 50 InvoiceDescription

Data Field Specifications The following table lists all the field names, descriptions, their maximum length, and also

specifies the required fields.

Soap header

Parameter Description Data

type

Max

length

Required

ewayCustomerID Your unique eWAY customer ID

assigned to you when you join

eWAY. Eg 11438715.

string

8

Username Your eWAY username string 100

Password Your eWAY password string 50

CreateCustomer

Creates a new direct debit customer

Parameter Description Data

type

Max

length

Required

CustomerReference A reference to your own system

for the customer.

string 20

Title The customer’s Title (eg. Mr.) string 20

FirstName The first name of the customer,

(can contain letters, numbers,

space and ‘).

string

50

LastName The last name of the customer,

(can contain letters, numbers,

space and ‘).

string

50

Page 6: Direct debit web services - eWAY AustraliaCustomerID Direct debit customer id long 12 InvoiceReference A reference to your own invoice system for the purchase. string 50 InvoiceDescription

Company The customer's company name

(can contain number, letters and

space).

string

100

Position The customer's position (eg. Sales

Rep, Manger)

string 50

Email The customer’s email address,

(has to be a valid email address or

left blank)

string

50

Address The customer’s address string 255

Suburb The customer’s suburb string 50

State The customer’s state (has to be

one of the following: ACT, NSW,

QLD, NT, WA, VIC, TAS)

string

3

PostCode The customer’s postcode (can

only contain numbers)

string 6

Country The customer’s country (Only

valid country is Australia)

string 50

PhoneNumber The customer’s phone number

(can contain only numbers, and

have an optional leading ‘+’)

string

15

MobileNumber The customer’s mobile number

(can contain only numbers, and

have an optional leading ‘+’)

string

15

FaxNumber The customer’s fax number (can

contain only numbers, and have

an optional leading ‘+’)

string

15

WebSite The customer’s website (has to string 255

Page 7: Direct debit web services - eWAY AustraliaCustomerID Direct debit customer id long 12 InvoiceReference A reference to your own invoice system for the purchase. string 50 InvoiceDescription

start with a protocol, eg. http://)

Comments Any comments about the

customer (can contain letters,

numbers ‘!’, ’@’, ’.’, ’,’ , ’?’ and

space)

string

255

FormSendMethod Controls how the forms should be

sent to the customer

• 0 = don’t send form at all

• 1 = send form to specified

email

int

2

Return value

• On success, the function returns a string with the number of the created customer

• On error, returns a soap exception

CreatePayment

Creates a non-recurring payment for customer, the customer has to be active.

Parameter Description Data

type

Max

length

Required

CustomerID Direct debit customer id long 12

InvoiceReference A reference to your own invoice

system for the purchase.

string 50

InvoiceDescription String 255

PaymentDate The date for the direct debit, has to

be a future date (YYYY-MM-DD)

Date 10

PaymentAmount The amount for the direct debit ,

minimum $2.00 (Amount is in cents

int 10

Page 8: Direct debit web services - eWAY AustraliaCustomerID Direct debit customer id long 12 InvoiceReference A reference to your own invoice system for the purchase. string 50 InvoiceDescription

eg. 1000 = $10.00)

Return value

• On success, returns the transaction number that was created

• On error, returns a soap exception

CreateRecurringPayment

Creates a recurring payment for customer, the customer has to be active.

Parameter Description Data type Max

length

Required

CustomerID Direct debit customer id long 12

InvoiceReference A reference to your own invoice

system for the purchase. string 50

InitAmount The initial amount, in cents, can be

0, eg. 1000 = $10.00, this field can

be used eg. for setup costs

int 10

InitDate The initial date, has to be earlier

then StartDate, if init amount is 0,

then set this to the current date

(YYYY-MM-DD)

date 10

RecurringAmount The amount to charge, in cents,

minimum 200, eg. 200 = $2.00 int 10

IntervalTypeID Used for recurring payments, can be

• 1 = Day

• 2 = Week

• 3 = Month

• 4 = Year

int 1

PaymentInterval Has to be a positive number (eg. if

IntervalTypeID = 2, and int 5

Page 9: Direct debit web services - eWAY AustraliaCustomerID Direct debit customer id long 12 InvoiceReference A reference to your own invoice system for the purchase. string 50 InvoiceDescription

PaymentInterval = 1, the charge will

be done once per week)

StartDate The date to start the direct debit,

has to be later then InitDate (YYYY-

MM-DD)

date 10

EndDate The date to end the direct debit,

(YYYY-MM-DD), if not set, then it

the recurring charge will continue

indefinitely

date 10

Return value

• On success, returns the transaction id

• On error, returns a soap exception

GetCustomerDirectDebitStatus

Gets the direct debit status of the customer, the customer has to be active

Parameter Description Data type Max

length

Required

CustomerID Direct debit customer id long 12

Return value

• On success, returns a string with one of the following

o Customer created

o Form sent

o Fax received

o Account details entered

o Active

• On error, returns a soap exception

Page 10: Direct debit web services - eWAY AustraliaCustomerID Direct debit customer id long 12 InvoiceReference A reference to your own invoice system for the purchase. string 50 InvoiceDescription

GetPayments

Gets all payments for the customer in the date range, customer has to be active

Parameter Description Data type Max

length

Required

CustomerID Direct debit customer id long 12

StartDate The start date (YYYY-MM-DD) date 10

EndDate The end date (YYYY-MM-DD) date 10

Return value

• On success, returns all the payments in the date range

CustomerID The customerid

InvoiceReference A reference to your own invoice system for the

purchase.

InvoiceDescription The description of the products or services

purchased.

PaymentDate Date when merchant want to charge customer

DateOfDebit Paymentdate or next business day (if this date is

0001-01-01, it means that the payment has not

been processed yet)

SettlementDate The date the money is debited to the merchants

account (if this date is 0001-01-01, it means that

the payment has not been processed yet)

TrxnNumber A unique number for the transaction

ReturnText Used only for declined transactions

Result • 0 = Successful

• 1 = failed

• 2 = scheduled

Page 11: Direct debit web services - eWAY AustraliaCustomerID Direct debit customer id long 12 InvoiceReference A reference to your own invoice system for the purchase. string 50 InvoiceDescription

• 3 = pending

• 4 = unknown

• On error, returns soap exception

QueryCustomer

Gets the details of the customer

Parameter Description Data type Max

length

Required

CustomerID Direct debit customer id long 12

Return value

• On success, returns the details of the customer

FirstName The first name of the customer

LastName The last name of the customer

CompanyName The customer’s company name

Email The customer’s email address

CustomerReference A reference for the customer

Title The customer’s title

Position The customer’s position

Address The customer’s address

Suburb The customer’s suburb

State The customer’s state

PostCode The customer’s post code

Country The customer’s country

PhoneNumber The customer’s phone number

MobileNumber The customer’s mobile phone

number

Page 12: Direct debit web services - eWAY AustraliaCustomerID Direct debit customer id long 12 InvoiceReference A reference to your own invoice system for the purchase. string 50 InvoiceDescription

FaxNumber The customer’s fax number

WebSite The customer’s web site

Comments The customer’s comments

• On failure, returns a soap exception

QueryPayment

Gets the details of a payment

Parameter Description Data type Max

length Required

CustomerID Direct debit customer id long 12

TxnNumber The transaction number long 12

Return value

• On success, returns the details of the payment

CustomerID The customerid

InvoiceReference A reference to your own invoice system for the

purchase.

InvoiceDescription The description of the products or services

purchased.

PaymentDate Date when merchant want to charge customer

DateOfDebit Paymentdate or next business day (if this date is

0001-01-01, it means that the payment has not

been processed yet)

SettlementDate The date the money is debited to the merchants

account (if this date is 0001-01-01, it means that

the payment has not been processed yet)

TrxnNumber A unique number for the transaction

ReturnText Used only for declined transactions

Page 13: Direct debit web services - eWAY AustraliaCustomerID Direct debit customer id long 12 InvoiceReference A reference to your own invoice system for the purchase. string 50 InvoiceDescription

Result • 0 = Successful

• 1 = failed

• 2 = scheduled

• 3 = pending

• 4 = unknown

• On error, returns soap exception

QueryRecurringPayment

Gets the details of a recurring payment

Parameter Description Data type Max

length

Required

CustomerID Direct debit customer id long 12

RebillID The recurring payment transaction long 10

Return value

• On success, returns the details of the payment

RebillID The transaction id for the payment

CustomerID The customerID that this payment

belongs to

InvoiceReference Reference

InvoiceDescription Description of payment

InitDate The date for the initial payment

InitAmount The amount of the initial payment

RecurringAmount The recurring amount

StartDate The start date of the recurring

payment

EndDate The end date of the recurring

Page 14: Direct debit web services - eWAY AustraliaCustomerID Direct debit customer id long 12 InvoiceReference A reference to your own invoice system for the purchase. string 50 InvoiceDescription

payment, if this is empty, no end

date has been set

IntervalTypeID The type of interval, can be a value

of 1 - 4

PaymentInterval The payment interval

NextTransactionDate The next transaction, can be either

InitDate or the next recurring

payment date

NextTransactionAmount The next transaction amount, can

be either InitAmount or the

recurring amount

IsActive Is set to true if the payment is

active

• On error, returns a soap exception

UpdatePayment

Update the payment details; you can only update transactions that have not yet been

processed.

Parameter Description Data type Max

length

Required

txnNumber Transaction id to update long 12

customerID Direct debit customer id long 10

InvoiceReference A reference to your own invoice

system for the purchase.

string 50

InvoiceDescription String 255

totalAmount Amount of payment (1000 =

$10.00)

Int 10

Page 15: Direct debit web services - eWAY AustraliaCustomerID Direct debit customer id long 12 InvoiceReference A reference to your own invoice system for the purchase. string 50 InvoiceDescription

transactionDate Date of payment date 10

Return value

• On success, returns true or false, depending on if the process was successful or not

• On failure, returns soap exception

UpdateRecurringPayment

Update the recurring payment details

Parameter Description Data type Max

length

Required

rebillID Rebill id long 12

customerID Direct debit customer id long 10

InvoiceReference A reference to your own invoice

system for the purchase.

string 50

initAmount The initial amount to charge, when

updating, if the initdate is in the

past, you will not be able to

change this amount and have to

pass in the old value. See:

QueryRecurringPayment

int

10

initDate The date for the initial payment,

when updating, if the payment

already has been made, you have

to pass in the old value

date

10

recurringAmount The amount to charge int 10

intervalTypeID Used for recurring payments, can

be

• 1 = Day

• 2 = Week

int

2

Page 16: Direct debit web services - eWAY AustraliaCustomerID Direct debit customer id long 12 InvoiceReference A reference to your own invoice system for the purchase. string 50 InvoiceDescription

• 3 = Month

• 4 = Year

paymentInterval Has to be a positive number (eg. if

IntervalTypeID = 2, and

PaymentInterval = 1, the charge

will be done once per week)

int

4

startDate The date to start the recurring

payment, has to be later then

InitDate (YYYY-MM-DD). When you

change this for an old payment,

the “next transaction date” will be

changed to this value. See:

QueryRecurringPayment.

date

10

endDate The date to end the direct debit,

(YYYY-MM-DD), if not set, then it

the recurring charge will continue

indefinitely

date

10

Return value

• On success, returns true or false, depending on if the process was successful or not

• On failure, returns soap exception

UpdateCustomer

Update the customer details

Parameter Description Data

type

Max

length

Required

customerID Direct debit customer id Long 10

CustomerReference A reference to your own system

for the customer.

string 20

Page 17: Direct debit web services - eWAY AustraliaCustomerID Direct debit customer id long 12 InvoiceReference A reference to your own invoice system for the purchase. string 50 InvoiceDescription

Title The customer’s Title (eg. Mr.) string 20

FirstName The first name of the customer,

(can contain letters, numbers,

space and ‘).

string

50

LastName The last name of the customer,

(can contain letters, numbers,

space and ‘).

string

50

Company The customer's company name

(can contain number, letters and

space).

string

100

Position The customer's position (eg. Sales

Rep, Manger)

string 50

Email The customer’s email address,

(has to be a valid email address or

left blank)

string

50

Address The customer’s address string 255

Suburb The customer’s suburb string 50

State The customer’s state (has to be

one of the following: ACT, NSW,

QLD, NT, WA, VIC, TAS)

string

3

PostCode The customer’s postcode (can

only contain numbers)

string 6

Country The customer’s country (Only

valid country is Australia)

string 50

PhoneNumber The customer’s phone number

(can contain only numbers, and

have an optional leading ‘+’)

string

15

Page 18: Direct debit web services - eWAY AustraliaCustomerID Direct debit customer id long 12 InvoiceReference A reference to your own invoice system for the purchase. string 50 InvoiceDescription

MobileNumber The customer’s mobile number

(can contain only numbers, and

have an optional leading ‘+’)

string

15

FaxNumber The customer’s fax number (can

contain only numbers, and have

an optional leading ‘+’)

string

15

WebSite The customer’s website (has to

start with a protocol, eg. http://)

string 255

Comments Any comments about the

customer (can contain letters,

numbers ‘!’, ’@’, ’.’, ’,’ , ’?’ and

space)

string

255

Return value

• On success, returns true or false, depending on if the process was successful or not

• On failure, returns soap exception

DeleteCustomer

Delete the customer

Parameter Description Data type Max

length

Required

customerID Direct debit customer id long 10

Return value

• On success, returns true or false, depending on if the process was successful or not

• On failure, returns soap exception

DeleteRecurringPayment

Delete the recurring payment

Page 19: Direct debit web services - eWAY AustraliaCustomerID Direct debit customer id long 12 InvoiceReference A reference to your own invoice system for the purchase. string 50 InvoiceDescription

Parameter Description Data type Max

length

Required

rebillID Recurring id long 12

customerID Direct debit customer id long 10

Return value

• On success, returns true or false, depending on if the process was successful or not

• On failure, returns soap exception

DeletePayment

Delete the payment

Parameter Description Data type Max

length

Required

txnNumber Transaction id long 12

customerID Direct debit customer id long 10

Return value

• On success, returns true or false, depending on if the process was successful or not

• On failure, returns soap exception

Page 20: Direct debit web services - eWAY AustraliaCustomerID Direct debit customer id long 12 InvoiceReference A reference to your own invoice system for the purchase. string 50 InvoiceDescription

Appendix A: Example Request and Response Formats

CreateCustomer

Request

<soapenv:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"

xmlns:pay="https://www.eway.com.au/gateway/DirectDebit">

<soap:Header>

<pay:eWAYHeader>

<pay:eWAYCustomerID>87654321</pay:eWAYCustomerID>

<pay:Username>[email protected]</pay:Username>

<pay:Password>test</pay:Password>

</pay:eWAYHeader>

</soap:Header>

<soap:Body>

<pay:CreateCustomer>

<pay:Title>Mr.</pay:Title>

<pay:Firstname>firstname</pay:Firstname>

<pay:Lastname>lastname</pay:Lastname>

<pay:Email>[email protected]</pay:Email>

<pay:Company>eway</pay:Company>

<pay:WebSite>http://eway.com.au</pay:WebSite>

<pay:Position>developer</pay:Position>

<pay:Address>Address</pay:Address>

<pay:Suburb>phillip</pay:Suburb>

<pay:State>ACT</pay:State>

<pay:Postcode>2606</pay:Postcode>

<pay:Country>Australia</pay:Country>

<pay:PhoneNumber>123456789</pay:PhoneNumber>

<pay:FaxNumber></pay:FaxNumber>

<pay:MobileNumber></pay:MobileNumber>

<pay:CustomerReference></pay:CustomerReference>

<pay:Comments></pay:Comments>

</pay:CreateCustomer>

</soap:Body>

</soap:Envelope>

Successful Response

<soap:Body>

Page 21: Direct debit web services - eWAY AustraliaCustomerID Direct debit customer id long 12 InvoiceReference A reference to your own invoice system for the purchase. string 50 InvoiceDescription

<CreateCustomerResponse

xmlns="https://www.eway.com.au/gateway/DirectDebit">

<CreateCustomerResult>528411135975</CreateCustomerResult>

</CreateCustomerResponse>

</soap:Body>

Failed Response

<soap:Body>

<soap:Fault>

<faultcode>soap:Client</faultcode>

<faultstring>System.Web.Services.Protocols.SoapException: The

'https://www.eway.com.au/gateway/DirectDebit:Address' element is invalid - The value

'street address,

unit 3,

box 2' is invalid according to its datatype

'https://www.eway.com.au/gateway/DirectDebit:defaultstring' - The Pattern constraint

failed.

</faultstring>

<detail/>

</soap:Fault>

</soap:Body>

CreatePayment

Request

<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"

xmlns:pay="https://www.eway.com.au/gateway/DirectDebit">

<soap:Header>

<pay:eWAYHeader >

<pay:eWAYCustomerID>87654321</pay:eWAYCustomerID>

< pay:Username>[email protected]</pay:Username>

< pay:Password>test</pay:Password>

</pay:eWAYHeader>

</ soap:Header>

< soap:Body>

<pay:CreatePayment>

<pay:CustomerID>121393058544</pay:CustomerID>

<pay:InvoiceReference>test</pay:InvoiceReference>

<pay:InvoiceDescription></pay:InvoiceDescription>

<pay:PaymentDate>2008-03-20</pay:PaymentDate>

<pay:PaymentAmount>1000</pay:PaymentAmount>

Page 22: Direct debit web services - eWAY AustraliaCustomerID Direct debit customer id long 12 InvoiceReference A reference to your own invoice system for the purchase. string 50 InvoiceDescription

</pay:CreatePayment>

</soap:Body>

Successful Response

<soap:Body>

<CreatePaymentResponse

xmlns="https://www.eway.com.au/gateway/DirectDebit">

<CreatePaymentResult>1000000000013252</CreatePaymentResult>

</CreatePaymentResponse>

</soap:Body>

Failed Response

<soap:Fault>

<faultcode>soap:Client</faultcode>

<faultstring>System.Web.Services.Protocols.SoapException: Customer details

cannot be found. Cannot create a payment. </faultstring>

<detail/>

</soap:Fault>

CreateRecurringPayment

Request

<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"

xmlns:pay="https://www.eway.com.au/gateway/DirectDebit">

<soap:Header>

<pay:eWAYHeader >

<pay:eWAYCustomerID>87654321</pay:eWAYCustomerID>

< pay:Username>[email protected]</pay:Username>

< pay:Password>test</pay:Password>

</pay:eWAYHeader>

</ soap:Header>

< soap:Body>

<pay:CreateRecurringPayment>

<pay:CustomerID>1000000000000</pay:CustomerID>

<pay:invoiceReference></pay:invoiceReference>

<pay:initAmount>0</pay:initAmount>

<pay:initDate>2008-03-18</pay:initDate>

<pay:recurringAmount>200</pay:recurringAmount>

Page 23: Direct debit web services - eWAY AustraliaCustomerID Direct debit customer id long 12 InvoiceReference A reference to your own invoice system for the purchase. string 50 InvoiceDescription

<pay:intervalTypeID>2</pay:intervalTypeID>

<pay:paymentInterval>1</pay:paymentInterval>

<pay:startDate>2008-03-20</pay:startDate>

</pay:CreateRecurringPayment>

</soap:Body>

</soap:Envelope>

Successful Response

<soap:Body>

<CreateRecurringPaymentResponse

xmlns="https://www.eway.com.au/gateway/DirectDebit">

<CreateRecurringPaymentResult>100033</CreateRecurringPaymentResult>

</CreateRecurringPaymentResponse>

</soap:Body>

Failed Response

<soap:Body>

<soap:Fault>

<faultcode>soap:Client</faultcode>

<faultstring>

System.Web.Services.Protocols.SoapException: The

'https://www.eway.com.au/gateway/DirectDebit:InvoiceReference' element is invalid -

The value '' is invalid according to its datatype

'https://www.eway.com.au/gateway/DirectDebit:invoicereference' - The actual length is

less than the MinLength value.

</faultstring>

<detail/>

</soap:Fault>

</soap:Body>

GetCustomerDirectStatus

Request

<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"

xmlns:pay="https://www.eway.com.au/gateway/DirectDebit">

<soap:Header>

<pay:eWAYHeader >

<pay:eWAYCustomerID>87654321</pay:eWAYCustomerID>

<pay:Username>[email protected]</pay:Username>

<pay:Password>test</pay:Password>

Page 24: Direct debit web services - eWAY AustraliaCustomerID Direct debit customer id long 12 InvoiceReference A reference to your own invoice system for the purchase. string 50 InvoiceDescription

</pay:eWAYHeader>

</soap:Header>

< soap:Body>

<pay:GetCustomerDirectDebitStatus>

<pay:CustomerID>970871505247</pay:CustomerID>

</pay:GetCustomerDirectDebitStatus>

</soap:Body>

</soap:Envelope>

Successful response

<soap:Body>

<GetCustomerDirectDebitStatusResponse

xmlns="https://www.eway.com.au/gateway/DirectDebit">

<GetCustomerDirectDebitStatusResult>

Active

</GetCustomerDirectDebitStatusResult>

</GetCustomerDirectDebitStatusResponse>

</soap:Body>

Failed response

<soap:Fault>

<faultcode>soap:Client</faultcode>

<faultstring>System.Web.Services.Protocols.SoapException: Customer details

cannot be found. Cannot retrieve Direct Debit status.

</faultstring>

<detail/>

</soap:Fault>

GetPayments

Request

<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"

xmlns:pay="https://www.eway.com.au/gateway/DirectDebit">

<soap:Header>

<pay:eWAYHeader >

<pay:eWAYCustomerID>87654321</pay:eWAYCustomerID>

<pay:Username>[email protected]</pay:Username>

<pay:Password>test</pay:Password>

</pay:eWAYHeader>

</soap:Header>

Page 25: Direct debit web services - eWAY AustraliaCustomerID Direct debit customer id long 12 InvoiceReference A reference to your own invoice system for the purchase. string 50 InvoiceDescription

< soap:Body>

<pay:GetPayments>

<pay:CustomerID>100413792563</pay:CustomerID>

<pay:StartDate>2008-01-01</pay:StartDate>

<pay:EndDate>2008-04-01</pay:EndDate>

</pay:GetPayments>

</soap:Body>

</soap:Envelope>

Successful response

<GetPaymentsResponse xmlns="https://www.eway.com.au/gateway/DirectDebit">

<GetPaymentsResult>

<Payment>

<CustomerID>970871505247</CustomerID>

<InvoiceReference>test</InvoiceReference>

<InvoiceDescription/>

<PaymentAmount>200</PaymentAmount>

<TotalAmountDouble>2</TotalAmountDouble>

<PaymentDate>2008-03-26</PaymentDate>

<DateOfDebit>0001-01-01</DateOfDebit>

<SettlementDate>0001-01-01</SettlementDate>

<TrxnNumber>1000000000013252</TrxnNumber>

<ReturnText/>

<Result>2</Result>

</Payment>

</GetPaymentsResult>

<ResultMessage>Record(s): 1</ResultMessage>

</GetPaymentsResponse>

</soap:Body>

Failed response

<soap:Fault>

<faultcode>soap:Client</faultcode>

<faultstring>System.Web.Services.Protocols.SoapException: Customer details

cannot be found. Cannot retrieve payments</faultstring>

<detail/>

</soap:Fault>

Page 26: Direct debit web services - eWAY AustraliaCustomerID Direct debit customer id long 12 InvoiceReference A reference to your own invoice system for the purchase. string 50 InvoiceDescription

QueryCustomer

Request

<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"

xmlns:pay="https://www.eway.com.au/gateway/DirectDebit">

<soap:Header>

<pay:eWAYHeader >

<pay:eWAYCustomerID>87654321</pay:eWAYCustomerID>

<pay:Username>[email protected]</pay:Username>

<pay:Password>test</pay:Password>

</pay:eWAYHeader>

</soap:Header>

< soap:Body>

<pay:QueryCustomer>

<pay:CustomerID>949663515475</pay:CustomerID>

</pay:QueryCustomer>

</soap:Body>

</soap:Envelope>

Successful response

<QueryCustomerResponse xmlns="https://www.eway.com.au/gateway/DirectDebit">

<Customer>

<FirstName>Jo</FirstName>

<LastName>Test 1</LastName>

<CompanyName>eway1</CompanyName>

<Email>[email protected]</Email>

<CustomerReference>JoSmith123</CustomerReference>

<Title>Mr.</Title>

<Position>Manager</Position>

<Address>address</Address>

<Suburb>Phillip</Suburb>

<State>ACT</State>

<PostCode>2606</PostCode>

<Country>Australia</Country>

<PhoneNumber>0255556666</PhoneNumber>

<MobileNumber>0404112233</MobileNumber>

<FaxNumber>0255556655</FaxNumber>

<WebSite>www.eway.com.au</WebSite>

<Comments>Test Customer</Comments>

<ManagedCustomerID>11122233334444</ManagedCustomerID>

</Customer>

Page 27: Direct debit web services - eWAY AustraliaCustomerID Direct debit customer id long 12 InvoiceReference A reference to your own invoice system for the purchase. string 50 InvoiceDescription

</QueryCustomerResponse>

Failed response

<soap:Fault>

<faultcode>soap:Client</faultcode>

<faultstring>System.Web.Services.Protocols.SoapException: CustomerID does not

belong to the eWayCustomerID</faultstring>

<detail/>

</soap:Fault>

QueryPayment

Request

<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"

xmlns:pay="https://www.eway.com.au/gateway/DirectDebit">

<soap:Header>

<pay:eWAYHeader >

<pay:eWAYCustomerID>87654321</pay:eWAYCustomerID>

<pay:Username>[email protected]</pay:Username>

<pay:Password>test</pay:Password>

</pay:eWAYHeader>

</soap:Header>

< soap:Body>

<pay:QueryPayment>

<pay:CustomerID>121393058544</pay:CustomerID>

<pay:TxnNumber>1000000000013250</pay:TxnNumber>

</pay:QueryPayment>

</soap:Body>

</soap:Envelope>

Successful response

<QueryPaymentResponse xmlns="https://www.eway.com.au/gateway/DirectDebit">

<QueryPaymentResult>

<CustomerID>100000000000</CustomerID>

<InvoiceReference>test</InvoiceReference>

<InvoiceDescription/>

<PaymentAmount>200</PaymentAmount>

<PaymentDate>2008-03-26</PaymentDate>

<DateOfDebit>0001-01-01</DateOfDebit>

<SettlementDate>0001-01-01</SettlementDate>

Page 28: Direct debit web services - eWAY AustraliaCustomerID Direct debit customer id long 12 InvoiceReference A reference to your own invoice system for the purchase. string 50 InvoiceDescription

<TrxnNumber>1000000000013252</TrxnNumber>

<ReturnText/>

<Result>2</Result>

</QueryPaymentResult>

</QueryPaymentResponse>

Failed Response

<soap:Fault>

<faultcode>soap:Client</faultcode>

<faultstring>System.Web.Services.Protocols.SoapException: CustomerID does not

belong to the eWayCustomerID</faultstring>

<detail/>

</soap:Fault>

QueryRecurringPayment

Request

<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"

xmlns:pay="https://www.eway.com.au/gateway/DirectDebit">

<soap:Header>

<pay:eWAYHeader >

<pay:eWAYCustomerID>87654321</pay:eWAYCustomerID>

<pay:Username>[email protected]</pay:Username>

<pay:Password>test</pay:Password>

</pay:eWAYHeader>

</soap:Header>

< soap:Body>

<pay:QueryRecurringPayment>

<pay:CustomerID>121393058544</pay:CustomerID>

<pay:RebillID>100005</pay:RebillID>

</pay:QueryRecurringPayment>

</soap:Body>

</soap:Envelope>

Successful response

<QueryRecurringPaymentResponse

xmlns="https://www.eway.com.au/gateway/DirectDebit">

<RebillEvent>

<RebillID>100033</RebillID>

<CustomerID>970871505247</CustomerID>

<InvoiceReference>reg</InvoiceReference>

Page 29: Direct debit web services - eWAY AustraliaCustomerID Direct debit customer id long 12 InvoiceReference A reference to your own invoice system for the purchase. string 50 InvoiceDescription

<InvoiceDescription>reg</InvoiceDescription>

<InitDate>2008-03-25</InitDate>

<InitAmount>0</InitAmount>

<RecurringAmount>200</RecurringAmount>

<StartDate>2008-03-30</StartDate>

<EndDate xsi:nil="true"/>

<IntervalTypeID>2</IntervalTypeID>

<PaymentInterval>1</PaymentInterval>

<NextTransactionDate>2008-03-30</NextTransactionDate>

<NextTransactionAmount>200</NextTransactionAmount>

<IsActive>true</IsActive>

</RebillEvent>

</QueryRecurringPaymentResponse>

Failed response

<soap:Fault>

<faultcode>soap:Client</faultcode>

<faultstring>System.Web.Services.Protocols.SoapException: CustomerID does not

belong to the eWayCustomerID

</faultstring>

<detail/>

</soap:Fault>

UpdatePayment

Request

<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"

xmlns:pay="https://www.eway.com.au/gateway/DirectDebit">

<soap:Header>

<pay:eWAYHeader >

<pay:eWAYCustomerID>87654321</pay:eWAYCustomerID>

<pay:Username>[email protected]</pay:Username>

<pay:Password>test</pay:Password>

</pay:eWAYHeader>

</soap:Header>

< soap:Body>

<pay:UpdatePayment>

<pay:txnNumber>1000000000013263</pay:txnNumber>

<pay:customerID>970871505247</pay:customerID>

<pay:invoiceReference>321 new</pay:invoiceReference>

<pay:invoiceDescription>updated</pay:invoiceDescription>

Page 30: Direct debit web services - eWAY AustraliaCustomerID Direct debit customer id long 12 InvoiceReference A reference to your own invoice system for the purchase. string 50 InvoiceDescription

<pay:totalAmount>1000</pay:totalAmount>

<pay:transactionDate>2008-04-02</pay:transactionDate>

</pay:UpdatePayment>

</soap:Body>

</soap:Envelope>

Successful response

<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"

xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"

xmlns:xsd="http://www.w3.org/2001/XMLSchema">

<soap:Body>

<UpdatePaymentResponse

xmlns="https://www.eway.com.au/gateway/DirectDebit">

<UpdatePaymentResult>true</UpdatePaymentResult>

</UpdatePaymentResponse>

</soap:Body>

</soap:Envelope>

Failed Response

UpdateRecurringPayment

Request

<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"

xmlns:pay="https://www.eway.com.au/gateway/DirectDebit">

<soap:Header>

<pay:eWAYHeader >

<pay:eWAYCustomerID>87654321</pay:eWAYCustomerID>

<pay:Username>[email protected]</pay:Username>

<pay:Password>test</pay:Password>

</pay:eWAYHeader>

</soap:Header>

< soap:Body>

<pay:UpdateRecurringPayment>

<pay:rebillID>1000358</pay:rebillID>

<pay:customerID>970871505247</pay:customerID>

<pay:invoiceReference>test</pay:invoiceReference>

<pay:initAmount>2000</pay:initAmount>

<pay:initDate>2008-04-01</pay:initDate>

<pay:recurringAmount>300</pay:recurringAmount>

<pay:intervalTypeID>1</pay:intervalTypeID>

Page 31: Direct debit web services - eWAY AustraliaCustomerID Direct debit customer id long 12 InvoiceReference A reference to your own invoice system for the purchase. string 50 InvoiceDescription

<pay:paymentInterval>10</pay:paymentInterval>

<pay:startDate>2008-04-02</pay:startDate>

<pay:endDate>2009-04-02</pay:endDate>

</pay:UpdateRecurringPayment>

</soap:Body>

</soap:Envelope>

Successful response

<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"

xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"

xmlns:xsd="http://www.w3.org/2001/XMLSchema">

<soap:Body>

<UpdateRecurringPaymentResponse

xmlns="https://www.eway.com.au/gateway/DirectDebit">

<UpdateRecurringPaymentResult>true</UpdateRecurringPaymentResult>

</UpdateRecurringPaymentResponse>

</soap:Body>

</soap:Envelope>

Failed Response

<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"

xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"

xmlns:xsd="http://www.w3.org/2001/XMLSchema">

<soap:Body>

<soap:Fault>

<faultcode>soap:Client</faultcode>

<faultstring>Can not find the rebill id, make sure you have used a correct

id</faultstring>

<detail/>

</soap:Fault>

</soap:Body>

</soap:Envelope>

UpdateCustomer

Request

<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"

xmlns:pay="https://www.eway.com.au/gateway/DirectDebit">

<soap:Header>

<pay:eWAYHeader >

<pay:eWAYCustomerID>87654321</pay:eWAYCustomerID>

<pay:Username>[email protected]</pay:Username>

Page 32: Direct debit web services - eWAY AustraliaCustomerID Direct debit customer id long 12 InvoiceReference A reference to your own invoice system for the purchase. string 50 InvoiceDescription

<pay:Password>test</pay:Password>

</pay:eWAYHeader>

</soap:Header>

< soap:Body>

<pay:UpdateCustomer>

<pay:customerID>436731582769</pay:customerID>

<pay:Title>Mr.</pay:Title>

<pay:Firstname>firstname</pay:Firstname>

<pay:Lastname>lastname</pay:Lastname>

<pay:Email>[email protected]</pay:Email>

<pay:Company>eway</pay:Company>

<pay:WebSite>http://eway.com.au</pay:WebSite>

<pay:Position>developer</pay:Position>

<pay:Address>address</pay:Address>

<pay:Suburb>suburb</pay:Suburb>

<pay:State>ACT</pay:State>

<pay:Postcode>2600</pay:Postcode>

<pay:Country>Australia</pay:Country>

<pay:PhoneNumber>1800123123</pay:PhoneNumber>

<pay:FaxNumber>1800123124</pay:FaxNumber>

<pay:MobileNumber>0411111111111</pay:MobileNumber>

<pay:CustomerReference>non</pay:CustomerReference>

<pay:Comments>n/a</pay:Comments>

</pay:UpdateCustomer>

</soap:Body>

</soap:Envelope>

Successful response

<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"

xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"

xmlns:xsd="http://www.w3.org/2001/XMLSchema">

<soap:Body>

<UpdateRecurringPaymentResponse

xmlns="https://www.eway.com.au/gateway/DirectDebit">

<UpdateRecurringPaymentResult>true</UpdateRecurringPaymentResult>

</UpdateRecurringPaymentResponse>

</soap:Body>

</soap:Envelope>

Failed Response

Page 33: Direct debit web services - eWAY AustraliaCustomerID Direct debit customer id long 12 InvoiceReference A reference to your own invoice system for the purchase. string 50 InvoiceDescription

<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"

xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"

xmlns:xsd="http://www.w3.org/2001/XMLSchema">

<soap:Body>

<soap:Fault>

<faultcode>soap:Client</faultcode>

<faultstring>Customer does not belong to merchant</faultstring>

<detail/>

</soap:Fault>

</soap:Body>

</soap:Envelope>

DeleteRecurringPayment

Request

<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"

xmlns:pay="https://www.eway.com.au/gateway/DirectDebit">

<soap:Header>

<pay:eWAYHeader >

<pay:eWAYCustomerID>87654321</pay:eWAYCustomerID>

<pay:Username>[email protected]</pay:Username>

<pay:Password>test</pay:Password>

</pay:eWAYHeader>

</soap:Header>

< soap:Body>

<dir:DeleteRecurringPayment>

<dir:rebillID>100033</dir:rebillID>

<dir:customerID>970871505247</dir:customerID>

</dir:DeleteRecurringPayment>

</soap:Body>

</soap:Envelope>

Successful response

<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"

xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"

xmlns:xsd="http://www.w3.org/2001/XMLSchema">

<soap:Body>

<DeleteRecurringPaymentResponse

xmlns="https://www.eway.com.au/gateway/DirectDebit">

<DeleteRecurringPaymentResult>true</DeleteRecurringPaymentResult>

</DeleteRecurringPaymentResponse>

</soap:Body>

Page 34: Direct debit web services - eWAY AustraliaCustomerID Direct debit customer id long 12 InvoiceReference A reference to your own invoice system for the purchase. string 50 InvoiceDescription

</soap:Envelope>

Failed Response

<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"

xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"

xmlns:xsd="http://www.w3.org/2001/XMLSchema">

<soap:Body>

<soap:Fault>

<faultcode>soap:Client</faultcode>

<faultstring>RebillID does not belong to customer</faultstring>

<detail/>

</soap:Fault>

</soap:Body>

</soap:Envelope>

DeletePayment

Request

<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"

xmlns:pay="https://www.eway.com.au/gateway/DirectDebit">

<soap:Header>

<pay:eWAYHeader >

<pay:eWAYCustomerID>87654321</pay:eWAYCustomerID>

<pay:Username>[email protected]</pay:Username>

<pay:Password>test</pay:Password>

</pay:eWAYHeader>

</soap:Header>

< soap:Body>

<dir:DeletePayment>

<dir:txnNumber>1000000000013259</dir:txnNumber>

<dir:customerID>970871505247</dir:customerID>

</dir:DeletePayment>

</soap:Body>

</soap:Envelope>

Successful response

<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"

xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"

xmlns:xsd="http://www.w3.org/2001/XMLSchema">

<soap:Body>

Page 35: Direct debit web services - eWAY AustraliaCustomerID Direct debit customer id long 12 InvoiceReference A reference to your own invoice system for the purchase. string 50 InvoiceDescription

<DeletePaymentResponse

xmlns="https://www.eway.com.au/gateway/DirectDebit">

<DeletePaymentResult>true</DeletePaymentResult>

</DeletePaymentResponse>

</soap:Body>

</soap:Envelope>

Failed Response

<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"

xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"

xmlns:xsd="http://www.w3.org/2001/XMLSchema">

<soap:Body>

<soap:Fault>

<faultcode>soap:Client</faultcode>

<faultstring>You can only delete payments in the future</faultstring>

<detail/>

</soap:Fault>

</soap:Body>

</soap:Envelope>