pixiPaySetInvoiceCapture
API Call made for Payment-Apps to set invoices to paid or to unpaid after capturing the amount
Since pixi version: LOU Official - Update 46 (6.9.46.27927) Additional notes: @Success - Was the capture successful? IF not(@Success = 0), the call sets the PayedSum in Invoices to "0" and all connected payment data for the invoice will be reset to unpaid. IF yes(@Success = 1), the call will create manual booking event in Customer Account.
Request
Request body
Name | Type | Required | Description |
---|---|---|---|
PayID | string | true | Unique TransactionID Type: varchar(50) Default value: Example: 31HA07BC812E3C3FDD691A7818766939 Available from: LOU Official - Update 46 (6.9.46.27927) |
EventID | string | false | Mandatory when @Success = 1 - the EventID of the payment event in Customer Account Type: varchar(3) Default value: Example: MIN Available from: LOU Official - Update 46 (6.9.46.27927) |
Message | string | true | Message will be saved to the Credit Card Log in pixi Control Center Type: varchar(200) Default value: Example: Amount of 46.18 EUR was captured Available from: LOU Official - Update 46 (6.9.46.27927) |
PayCode | string | true | CC = Credit Card Type: varchar(50) Default value: Example: CC Available from: LOU Official - Update 46 (6.9.46.27927) |
Success | boolean | true | @Success = 0 -> PaidSum = 0, @Success = 1 -> PaidSum > 0 Type: bit Default value: Example: 0 or 1 Available from: LOU Official - Update 46 (6.9.46.27927) |
InvoiceNr | string | true | Invoice number of the invoice that was captured Type: varchar(20) Default value: Example: DEM0000021 Available from: LOU Official - Update 46 (6.9.46.27927) |
CaptureSum | number | true | Sum that should be captured. @PaidSum in pixiSetInvoicePaid Type: money Default value: Example: 46.18 Available from: LOU Official - Update 46 (6.9.46.27927) |
SetRemainingOrdersToHAL | boolean | true | If items of the order remain on ANG (e.g. for partial deliveries) they can be set back to HAL =1 Type: bit Default value: Example: 0 or 1 Available from: LOU Official - Update 46 (6.9.46.27927) |
Request Example
<Envelope xmlns="http://schemas.xmlsoap.org/soap/envelope/">
<Body xmlns="">
<pixiPaySetInvoiceCapture>
<InvoiceNr>string</InvoiceNr>
<Success>true</Success>
<PayID>string</PayID>
<PayCode>string</PayCode>
<Message>string</Message>
<CaptureSum>0</CaptureSum>
<EventID>string</EventID>
<SetRemainingOrdersToHAL>true</SetRemainingOrdersToHAL>
</pixiPaySetInvoiceCapture>
</Body>
</Envelope>
Response
1. Return status
Name | Type | Description |
---|---|---|
Status | string | Result of API Call Type: varchar(10) Available from: 25.06 (25.6.0.58802) |
Message | string | Extended Result of API Call Type: varchar(100) Available from: 25.06 (25.6.0.58802) |
Response Example
<PixiPaySetInvoiceCapturePost200TextXmlResponse>
<Status>string</Status>
<Message>string</Message>
</PixiPaySetInvoiceCapturePost200TextXmlResponse>
HTTP Example
POST https://apigateway.descartes.com/tms/pixi/
Content-Type: text/xml; charset=utf-8
# echo -n '{{username}}:{{password}}' | base64 | pbcopy
Authorization: Basic {{token}}
<?xml version="1.0" encoding="UTF-8"?>
<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:ns1="https://apigateway.descartes.com/tms/pixi/"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/">
<SOAP-ENV:Body>
<ns1:pixiPaySetInvoiceCapture>
<PayID xsi:type="xsd:string">31HA07BC812E3C3FDD691A7818766939</PayID> <!-- required -->
<EventID xsi:type="xsd:string">MIN</EventID>
<Message xsi:type="xsd:string">Amount of 46.18 EUR was captured</Message> <!-- required -->
<PayCode xsi:type="xsd:string">CC</PayCode> <!-- required -->
<Success xsi:type="xsd:boolean">0 or 1</Success> <!-- required -->
<InvoiceNr xsi:type="xsd:string">DEM0000021</InvoiceNr> <!-- required -->
<CaptureSum xsi:type="xsd:number">46.18</CaptureSum> <!-- required -->
<SetRemainingOrdersToHAL xsi:type="xsd:boolean">0 or 1</SetRemainingOrdersToHAL> <!-- required -->
</ns1:pixiPaySetInvoiceCapture>
</SOAP-ENV:Body>
</SOAP-ENV:Envelope>
PHP Example
<?php
getPixiSoapClientResponse('pixiPaySetInvoiceCapture', [
'PayID' => '31HA07BC812E3C3FDD691A7818766939', // string (required)
'EventID' => 'MIN', // string
'Message' => 'Amount of 46.18 EUR was captured', // string (required)
'PayCode' => 'CC', // string (required)
'Success' => '0 or 1', // boolean (required)
'InvoiceNr' => 'DEM0000021', // string (required)
'CaptureSum' => '46.18', // number (required)
'SetRemainingOrdersToHAL' => '0 or 1', // boolean (required)
]);
function getPixiSoapClientResponse(string $method, array $arguments = [])
{
$soapArguments = [];
foreach ($arguments as $key => $value) {
$soapArguments[] = new SoapVar($value, null, '', '', $key);
}
$soapClient = new SoapClient(null, [
'login' => '...',
'password' => '...',
'uri' => 'https://apigateway.descartes.com/tms/pixi/',
'location' => 'https://apigateway.descartes.com/tms/pixi/',
]);
return $soapClient->__call($method, $soapArguments);
}