API Documentation

In-depth reference documentation for iQmetrix API's.

NAV

OVERVIEW

The endpoints on this page are restricted to Suppliers, and a Supplier can only obtain data as it relates to their organization.

Authentication

Data Connect supports many different methods of authentication, see Authentication Options.

ENDPOINTS

RESOURCES

SupplierAvailability

[
    {
        "Supplier": "Contoso",
        "SubscriptionList": "Contoso – Dropship",
        "ProductName": "ADATA DashDrive C008 USB2.0 FlashDrive 16GB Blk/Re",
        "SupplierSku": "407281",
        "Price": 25.99,
        "Dropshippable": true,
        "IsAvailable": false,
        "Quantity": 0
    }
]
Name Description
Supplier (NVARCHAR(4000)) Supplier name
SubscriptionList (NVARCHAR(4000)) Name of a SubscribableList
ProductName (NVARCHAR(4000)) Product name
SupplierSku (NVARCHAR(4000)) Supplier SKU
Price (MONEY) Price
Dropshippable (BIT) A flag to indicate if the product is Dropshippable (true) or not (false)
IsAvailable (BIT) A flag to indicate if the product is available to be sold (true) or not (false)
Quantity (INT) A flag to indicate quantity

REQUESTS

GET Supplier Availability

This endpoint returns all of a supplier’s products and availability across all subscription lists.

Definition

GET /Supplier/Availability

Headers

Example Request

GET /Supplier/Availability
Authorization: Bearer (Access Token)
Accept-Encoding: gzip

curl -X GET "https://dataconnectdemo.iqmetrix.net/Supplier/Availability" -H "Authorization: Bearer (Access Token)" -H "Accept-Encoding: gzip"
static IRestResponse GettingSupplierAvailability()
{
    var client = new RestClient("https://dataconnectdemo.iqmetrix.net/Supplier/Availability");
    var request = new RestRequest(Method.GET);
     
    request.AddHeader("Authorization", "Bearer (Access Token)"); 
    request.AddHeader("Accept-Encoding", "gzip"); 

    

    return client.Execute(request);
}

import org.apache.http.client.methods.CloseableHttpResponse;
import org.apache.http.client.methods.HttpGet;
import org.apache.http.impl.client.CloseableHttpClient;
import org.apache.http.impl.client.HttpClients;
import java.io.IOException;

public static CloseableHttpResponse GettingSupplierAvailability() throws IOException {
    CloseableHttpClient httpClient = HttpClients.createDefault();
    HttpGet request = new HttpGet("https://dataconnectdemo.iqmetrix.net/Supplier/Availability");
     
    request.addHeader("Authorization", "Bearer (Access Token)"); 
    request.addHeader("Accept-Encoding", "gzip"); 
    
    return httpClient.execute(request);
}
require 'rest-client'


response = RestClient.get 'https://dataconnectdemo.iqmetrix.net/Supplier/Availability', {
     :'Authorization' => 'Bearer (Access Token)',
     :'Accept-Encoding' => 'gzip',
    } 

puts response

Response Parameters

Array[SupplierAvailability]

Example Response (Default)

HTTP 200 Content-Type: application/json
[
    {
        "Supplier": "Contoso",
        "SubscriptionList": "Contoso – Dropship",
        "ProductName": "ADATA DashDrive C008 USB2.0 FlashDrive 16GB Blk/Re",
        "SupplierSku": "407281",
        "Price": 25.99,
        "Dropshippable": true,
        "IsAvailable": false,
        "Quantity": 0
    }
]

Example Response (JsonDataTable)

HTTP 200 Content-Type: application/json
{
    "Records": [
        {
            "Supplier": "Contoso",
            "SubscriptionList": "Contoso – Dropship",
            "ProductName": "ADATA DashDrive C008 USB2.0 FlashDrive 16GB Blk/Re",
            "SupplierSku": "407281",
            "Price": 25.99,
            "Dropshippable": true,
            "IsAvailable": false,
            "Quantity": 0
        }
    ],
    "Schema": [
        {
            "Column_Name": "ColumnName",
            "Type": "datatype",
            "SafeType": "safetype",
            "Length": 100
        }
    ]
}

Example Response (XmlDataTable)

HTTP 200 Content-Type: text/xml
<Table>
  <Record>
    <Supplier>Contoso</Supplier>
    <SubscriptionList>Contoso – Dropship</SubscriptionList>
    <ProductName>ADATA DashDrive C008 USB2.0 FlashDrive 16GB Blk/Re</ProductName>
    <SupplierSku>407281</SupplierSku>
    <Price>25.99</Price>
    <Dropshippable>true</Dropshippable>
    <IsAvailable>false</IsAvailable>
    <Quantity>0</Quantity>
  </Record>
  <Schema>
    <Column_Name>ColumnName</Column_Name>
    <Type>datatybe</Type>
    <SafeType>safetype</SafeType>
    <Length>100</Length>
  </Schema>
</Table>

Example Response (CSV)

HTTP 200 Content-Type: text/csv
Supplier,SubscriptionList,ProductName,SupplierSku,Price,Dropshippable,IsAvailable,Quantity
Contoso,Contoso  Dropship,ADATA DashDrive C008 USB2.0 FlashDrive 16GB Blk/Re,407281,25.99,true,false,0

Example Response (Excel)

HTTP 200 Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet
content-disposition: attachment;filename=reportname-2016-07-11.xlsx
Binary *.xlsx file

ERRORS

HTTP Status Code Description How to Resolve
HTTP 400 Bad Request Ensure request body is formatted properly
HTTP 401 Tokan is invalid Ensure Access Token is valid and has not expired
HTTP 403 Unauthorized Ensure Access Token is valid and user has appropriate security
HTTP 404 Not Found Ensure URI is valid
HTTP 500 Unexpected Error See Message in response for more information
Was this page helpful?