pixiSetItemStatus
The API call updates the item status. In case we provide also parameter @SupplierID. We can use the call to update the "Active" status for a specific supplier for the item.
Since pixi version: LOU Official (6.3.0.4452) Additional notes:
Request
Request body
Name | Type | Required | Description |
---|---|---|---|
Enabled | boolean | false | Used for setting the item to enabled/active. (Default value: 1) Type: bit Default value: 1 Example: Available from: LOU Official (6.3.0.4452) |
ItemKey | integer | false | pixi* Item ID. (Optional in case value for parameter @ItemNrInt is provided) Type: int Default value: NULL Example: Available from: LOU Official (6.3.0.4452) |
ItemNrInt | string | false | pixi* Item number internal. (Optional in case value for parameter @ItemKey is provided) Type: varchar(50) Default value: NULL Example: Available from: LOU Official (6.3.0.4452) |
SupplierID | string | false | pixi* Supplier ID. Used when updating the "Active" status for an item for specific supplier. Type: varchar(4) Default value: NULL Example: Available from: AVA 17.02 (8.4.26.28957) |
Request Example
<Envelope xmlns="http://schemas.xmlsoap.org/soap/envelope/">
<Body xmlns="">
<pixiSetItemStatus>
<ItemNrInt>string</ItemNrInt>
<ItemKey>0</ItemKey>
<Enabled>true</Enabled>
<SupplierID>string</SupplierID>
</pixiSetItemStatus>
</Body>
</Envelope>
Response
1. Return status
Name | Type | Description |
---|---|---|
Active | boolean | Item active status Type: bit Available from: 25.06 (25.6.0.58802) |
Enabled | boolean | 1 = item is marked as active in pixi* 0 = item is marked as inactive in pixi* Type: bit Available from: 25.06 (25.6.0.58802) |
ItemKey | integer | pixi* internal item key Type: int Available from: 25.06 (25.6.0.58802) |
SupplNr | string | Suplier Id Type: varchar Available from: 25.06 (25.6.0.58802) |
ItemNrInt | string | shop-specific id (SUPPLIER_AID) Type: varchar Available from: 25.06 (25.6.0.58802) |
Response Example
<PixiSetItemStatusPost200TextXmlResponse>
<ItemKey>0</ItemKey>
<ItemNrInt>string</ItemNrInt>
<Enabled>true</Enabled>
<SupplNr>string</SupplNr>
<Active>true</Active>
</PixiSetItemStatusPost200TextXmlResponse>
2. Return status
Name | Type | Description |
---|---|---|
Status | string | Status Type: varchar Available from: 25.06 (25.6.0.58802) |
ErrorMsg | string | Error message Type: varchar Available from: 25.06 (25.6.0.58802) |
Response Example
<PixiSetItemStatusPost200TextXmlResponse>
<ItemKey>0</ItemKey>
<ItemNrInt>string</ItemNrInt>
<Enabled>true</Enabled>
<SupplNr>string</SupplNr>
<Active>true</Active>
</PixiSetItemStatusPost200TextXmlResponse>
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:pixiSetItemStatus>
<Enabled xsi:type="xsd:boolean"></Enabled>
<ItemKey xsi:type="xsd:integer"></ItemKey>
<ItemNrInt xsi:type="xsd:string"></ItemNrInt>
<SupplierID xsi:type="xsd:string"></SupplierID>
</ns1:pixiSetItemStatus>
</SOAP-ENV:Body>
</SOAP-ENV:Envelope>
PHP Example
<?php
getPixiSoapClientResponse('pixiSetItemStatus', [
'Enabled' => '', // boolean
'ItemKey' => '', // integer
'ItemNrInt' => '', // string
'SupplierID' => '', // 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);
}