The API documentation is attached at the end of the article.
To upload a Debit Order batch via API, you can use the sample below.
Please make sure you add your key in the endpoint, and your client code in the request.
Endpoint: https://test.peachpay.co.za/API/DebitOrder?key=fc301277-xxxx
To make a request, include the parameter 'request' in the body of your request and use a value that (for example) looks like:
<APIDebitOrdersRequest> <Header> <PsVer>2.0.1</PsVer> <Client>XXX001</Client> <Service>DebitOrder</Service> <ServiceType>2Day</ServiceType> <UniqueId>123</UniqueId> <Duedate>20180707</Duedate> <Reference>Peach test</Reference> <CallBackUrl></CallBackUrl> </Header> <DebitOrders> <FileContents> <FirstNames>xxx</FirstNames> <Surname>xxx</Surname> <BranchCode>203809</BranchCode> <AccountNumber>xxxx</AccountNumber> <FileAmount>5.00</FileAmount> <AmountMultiplier>1</AmountMultiplier> <Reference>peach test 1234</Reference> </FileContents> </DebitOrders> <Totals> <Records>1</Records> <Amount>5.00</Amount> <BranchHash>203809</BranchHash> <AccountHash>xxxx</AccountHash> </Totals> </APIDebitOrdersRequest> |
A tokenized <FileContents> sample could be:
<FileContents> <CustomerCode>456</CustomerCode> <Token>35E7D515C510874xxxx</Token> <AmountMultiplier>1</AmountMultiplier> <FileAmount>5.00</FileAmount> <Reference>Peach test</Reference> </FileContents> |
You can tokenize customers in the portal or via the API.