pixiAddReturnCaseLine
This call adds an item to a return case in pixi* Repairs
Since pixi version: LOU Official (6.3.0.4452) Additional notes:
This API call is used to create new return lines to a return case which can be worked on in pixi* Repairs.
Return cases this call is referring to are not shown in Customer Service, Web and can also not be opened in pixi* Mobile.
Request
Request body
Name | Type | Required | Description |
---|---|---|---|
ItemOk | boolean | false | Item condition; 0 = Damaged, 1 = OK Type: bit Default value: 1 Example: 0 or 1 Available from: LOU Official (6.3.0.4452) |
RET_ID | integer | false | Return case ID from pixi* Repairs Type: int Default value: Example: 123 Available from: LOU Official (6.3.0.4452) |
Employee | string | false | User that added the item Type: varchar(50) Default value: NULL Example: abcdefg Available from: LOU Official (6.3.0.4452) |
InvLineKey | integer | true | Invoice line ID used as reference Type: int Default value: Example: 123 Available from: LOU Official (6.3.0.4452) |
ReturnDate | string | false | Date the item was returned Type: datetime Default value: NULL Example: YYYY-MM-DD hh:mm:ss Available from: LOU Official (6.3.0.4452) |
ReturnReason | string | false | Return reason Type: varchar(2048) Default value: Example: abcdefg Available from: LOU Official (6.3.0.4452) |
CustomersComment | string | false | Customer comment Type: varchar(2048) Default value: Example: abcdefg Available from: LOU Official (6.3.0.4452) |
QuantityToReturn | integer | true | Item quantity that should be returned Type: int Default value: Example: 123 Available from: LOU Official (6.3.0.4452) |
ReceiversComment | string | false | Receiver comment Type: varchar(2048) Default value: Example: abcdefg Available from: LOU Official (6.3.0.4452) |
Request Example
<Envelope xmlns="http://schemas.xmlsoap.org/soap/envelope/">
<Body xmlns="">
<pixiAddReturnCaseLine>
<InvLineKey>0</InvLineKey>
<QuantityToReturn>0</QuantityToReturn>
<ItemOk>true</ItemOk>
<RET_ID>0</RET_ID>
<ReturnReason>string</ReturnReason>
<CustomersComment>string</CustomersComment>
<ReceiversComment>string</ReceiversComment>
<Employee>string</Employee>
<ReturnDate>string</ReturnDate>
</pixiAddReturnCaseLine>
</Body>
</Envelope>
Response
Name | Type | Description |
---|---|---|
RET_LINE_ID | integer | Return case line ID that was created Type: int Available from: 25.06 (25.6.0.58802) |
UPDATED_RETURN_ID | integer | Return case ID that was updated Type: int Available from: 25.06 (25.6.0.58802) |
Response Example
<PixiAddReturnCaseLinePost200TextXmlResponse>
<UPDATED_RETURN_ID>0</UPDATED_RETURN_ID>
<RET_LINE_ID>0</RET_LINE_ID>
</PixiAddReturnCaseLinePost200TextXmlResponse>
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:pixiAddReturnCaseLine>
<ItemOk xsi:type="xsd:boolean">0 or 1</ItemOk>
<RET_ID xsi:type="xsd:integer">123</RET_ID>
<Employee xsi:type="xsd:string">abcdefg</Employee>
<InvLineKey xsi:type="xsd:integer">123</InvLineKey> <!-- required -->
<ReturnDate xsi:type="xsd:string">YYYY-MM-DD hh:mm:ss</ReturnDate>
<ReturnReason xsi:type="xsd:string">abcdefg</ReturnReason>
<CustomersComment xsi:type="xsd:string">abcdefg</CustomersComment>
<QuantityToReturn xsi:type="xsd:integer">123</QuantityToReturn> <!-- required -->
<ReceiversComment xsi:type="xsd:string">abcdefg</ReceiversComment>
</ns1:pixiAddReturnCaseLine>
</SOAP-ENV:Body>
</SOAP-ENV:Envelope>
PHP Example
<?php
getPixiSoapClientResponse('pixiAddReturnCaseLine', [
'ItemOk' => '0 or 1', // boolean
'RET_ID' => '123', // integer
'Employee' => 'abcdefg', // string
'InvLineKey' => '123', // integer (required)
'ReturnDate' => 'YYYY-MM-DD hh:mm:ss', // string
'ReturnReason' => 'abcdefg', // string
'CustomersComment' => 'abcdefg', // string
'QuantityToReturn' => '123', // integer (required)
'ReceiversComment' => 'abcdefg', // string
]);
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);
}