RestrictedService

Full documentation for this service is available at /documentation/restricted-service.

AddItemXml |WebMethod|

Adds an ItemRequest into the Tradera systems using an XML string. SOAP clients are encouraged to use the AddItem method instead. If uploading images, set the AutoCommit AutoCommit to false, call for every image and then call after the last image. For more information about the different elements in the Request XML, see the ItemRequest class. Note that this is an asynchronous call, which means that the item is not added into the Tradera system when this method returns. It is only added to a queue for processing, see and for additional information.

Parameters
  1. createItemRequestXml, XML data containing the values for the new Item. XML format: <pre> &lt;CreateItemRequest&gt; &lt;AutoCommit&gt;bool&lt;/AutoCommit&gt; &lt;ItemType&gt;int&lt;/ItemType&gt; &lt;Title&gt;string&lt;/Title&gt; &lt;ShippingCondition&gt;string&lt;/ShippingCondition&gt; &lt;PaymentCondition&gt;string&lt;/PaymentCondition&gt; &lt;CategoryId&gt;int&lt;/CategoryId&gt; &lt;Duration&gt;int&lt;/Duration&gt; &lt;Restarts&gt;int&lt;/Restarts&gt; &lt;StartPrice&gt;int&lt;/StartPrice&gt; &lt;ReservePrice&gt;int&lt;/ReservePrice&gt; &lt;BuyItNowPrice&gt;int&lt;/BuyItNowPrice&gt; &lt;Description&gt;string&lt;/Description&gt; &lt;AcceptedBidderId&gt;int&lt;/AcceptedBidderId&gt; &lt;VAT&gt;int&lt;/VAT&gt; &lt;OwnReferences&gt; &lt;OwnReference&gt;string&lt;/OwnReference&gt; &lt;OwnReference&gt;string&lt;/OwnReference&gt; &lt;OwnReference&gt;string&lt;/OwnReference&gt; &lt;OwnReference&gt;string&lt;/OwnReference&gt; &lt;/OwnReferences&gt; &lt;ExpoItemIds&gt; &lt;ExpoItemId&gt;int&lt;/ExpoItemId&gt; &lt;ExpoItemId&gt;int&lt;/ExpoItemId&gt; &lt;/ExpoItemIds&gt; &lt;PaymentOptionIds&gt; &lt;PaymentOptionId&gt;int&lt;/PaymentOptionId&gt; &lt;PaymentOptionId&gt;int&lt;/PaymentOptionId&gt; &lt;/PaymentOptionIds&gt; &lt;ShippingOptions&gt; &lt;ShippingOption&gt; &lt;Id&gt;int&lt;/Id&gt; &lt;Cost&gt;int&lt;/Cost&gt; &lt;/ShippingOption&gt; &lt;ShippingOption&gt; &lt;Id&gt;int&lt;/Id&gt; &lt;Cost&gt;int&lt;/Cost&gt; &lt;/ShippingOption&gt; &lt;/ShippingOptions&gt; &lt;ItemAttributes&gt; &lt;ItemAttribute&gt;int&lt;/ItemAttribute&gt; &lt;ItemAttribute&gt;int&lt;/ItemAttribute&gt; &lt;/ItemAttributes&gt; &lt;/CreateItemRequest&gt; </pre> See the ItemRequest class for a description of the parameters.
Returns

Response data (QueuedRequestResponse) with request id and item id. The item id is the id of the new item on Tradera. The request id is the identifier of the current request and is used together with API metthod GetRequestResults to get final result of this call.

SOAP 1.1

The following is a sample SOAP 1.1 request and response. The placeholders shown need to be replaced with actual values.

POST /v3/RestrictedService.asmx HTTP/1.1
Host: api.tradera.com
Content-Type: text/xml; charset=utf-8
SOAPAction: "http://api.tradera.com/AddItemXml"
Content-Length: length

<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
  <soap:Body>
    <AddItemXml xmlns="http://api.tradera.com">
      <createItemRequestXml>createItemRequestXml</createItemRequestXml>
    </AddItemXml>
  </soap:Body>
</soap:Envelope>
HTTP/1.1 200 OK
Content-Type: text/xml; charset=utf-8
Content-Length: length

<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
  <soap:Body>
    <AddItemXmlResponse xmlns="http://api.tradera.com">
      <AddItemXmlResult>Response data (QueuedRequestResponse) with request id and item id. The item id is the id of
             the new item on Tradera. The request id is the identifier of the current request and is used together with API metthod GetRequestResults to
             get final result of this call.</AddItemXmlResult>
    </AddItemXmlResponse>
  </soap:Body>
</soap:Envelope>

SOAP 1.2

The following is a sample SOAP 1.2 request and response. The placeholders shown need to be replaced with actual values.

POST /v3/RestrictedService.asmx HTTP/1.1
Host: api.tradera.com
Content-Type: application/soap+xml; charset=utf-8
Content-Length: length

<?xml version="1.0" encoding="utf-8"?>
<soap12:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap12="http://www.w3.org/2003/05/soap-envelope">
  <soap12:Body>
    <AddItemXml xmlns="http://api.tradera.com">
      <createItemRequestXml>createItemRequestXml</createItemRequestXml>
    </AddItemXml>
  </soap12:Body>
</soap12:Envelope>
HTTP/1.1 200 OK
Content-Type: application/soap+xml; charset=utf-8
Content-Length: length

<?xml version="1.0" encoding="utf-8"?>
<soap12:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap12="http://www.w3.org/2003/05/soap-envelope">
  <soap12:Body>
    <AddItemXmlResponse xmlns="http://api.tradera.com">
      <AddItemXmlResult>Response data (QueuedRequestResponse) with request id and item id. The item id is the id of
             the new item on Tradera. The request id is the identifier of the current request and is used together with API metthod GetRequestResults to
             get final result of this call.</AddItemXmlResult>
    </AddItemXmlResponse>
  </soap12:Body>
</soap12:Envelope>

HTTP GET

The following is a sample HTTP GET request and response. The placeholders shown need to be replaced with actual values.

GET /v3/RestrictedService.asmx/AddItemXml?appId=string&appKey=string&createItemRequestXml=string HTTP/1.1
Host: api.tradera.com
HTTP/1.1 200 OK
Content-Type: text/xml; charset=utf-8
Content-Length: length

<?xml version="1.0" encoding="utf-8"?>
<AddItemXmlResult xmlns="http://api.tradera.com">Response data (QueuedRequestResponse) with request id and item id. The item id is the id of
             the new item on Tradera. The request id is the identifier of the current request and is used together with API metthod GetRequestResults to
             get final result of this call.</AddItemXmlResult>

HTTP POST

The following is a sample HTTP POST request and response. The placeholders shown need to be replaced with actual values.

POST /v3/RestrictedService.asmx/AddItemXml HTTP/1.1
Host: api.tradera.com
Content-Type: application/x-www-form-urlencoded
Content-Length: length

appId=string&appKey=string&createItemRequestXml=string
HTTP/1.1 200 OK
Content-Type: text/xml; charset=utf-8
Content-Length: length

<?xml version="1.0" encoding="utf-8"?>
<AddItemXmlResult xmlns="http://api.tradera.com">Response data (QueuedRequestResponse) with request id and item id. The item id is the id of
             the new item on Tradera. The request id is the identifier of the current request and is used together with API metthod GetRequestResults to
             get final result of this call.</AddItemXmlResult>