ACC Distribution Customer API v1.0 (Service document)

1. Product list

POST https://api.accdistribution.net/v1/GetProducts

Payload:

    {
        "request": {
            "LicenseKey": "00000000-0000-0000-0000-000000000000",
            "Locale": "lt",
            "Currency": "EUR",
            "CompanyId": "_al",
            "Offset": "0",
            "Limit": "100",
            "Filters": [
            {
                "id": "updatedAfter",
                "values": [
                    "2017-03-28"
                ]
            },
            {
                "id": "branch",
                "values": [
                    "1490"
                ]
            },
            {
                "id": "producer",
                "values": [
                    "VA",
                    "AX",
                    "AP",
                    "AL"
                ]
            },
            {
                "id": "stockFlag",
                "values": [
                    "hasStock",
                    "byOrder"
                ]
            },
            {
                "id": "saleFlag",
                "values": [
                    "isDefect"
                ]
            }]
        }
    }

Filter types:

    "updatedAfter" - date. Returns only products updated after specified date. (Recommended for daily downloads)
    "branch" - ids of branches
    "producer" - ids of producers
    "stockFlag" - possible values: hasStock, arrivingStock, byOrder
    "saleFlag" - possible values: isDefect
    [id of parameter] - parameter values
    

Note:
"Offset", "Limit" and "Filters" are optional request parameters. If Limit is not specified, then default limit 10000 is applied.
All filter ids begin with lowercase letters.


2. Product specification

POST https://api.accdistribution.net/v1/GetProduct

Payload:
    {
        "request": {
            "LicenseKey": "00000000-0000-0000-0000-000000000000",
            "Locale": "lt",
            "Currency": "EUR",
            "CompanyId": "_al",
            "ProductId": "025328"
        }
    }

3. Product tree branches

POST https://api.accdistribution.net/v1/GetTreeBranches

Payload:
    {
        "request": {
            "LicenseKey": "00000000-0000-0000-0000-000000000000",
            "Locale": "lt"
        }
    }