GET /ad/byVendor/{vendorId}

GET /ad/byVendor/{vendorId} v5 | GET /ad/byVendor/{vendorId} v3 | GET /ad/byVendor/{vendorId} v2

Warning

GET /ad/byVendor/{vendorId} v2 is now officially deprecated and scheduled for removal on May, 1st 2023. Please move to use GET /ad/byVendor/{vendorId} v5.

GET /ad/byVendor/{vendorId} v3 is now officially deprecated and scheduled for removal on May, 1st 2023. Please move to use GET /ad/byVendor/{vendorId} v5.

GET /ad/byVendor/{vendorId} v5

Scope

api_ro or console_ro

Accept

application/sellside.ad-v5+json, application/json

This URL returns a single ad with the given vendorId.

If the ad does not exist or does not belong to the user the server returns 404 Not Found. If the vendorId is bigger than 64 characters the server returns 400 Bad Request.

Example

GET /ad/byVendor/OURSHOP-1423453-34
Accept: application/sellside.ad-v5+json, application/json

200 OK
Content-Type: application/sellside.ad-v5+json; charset=utf-8

{
    "id": 42,
    "title": "Brother Fax voor 99,99",
    "description": "<b>NU extra voordelig op ourshop.com.</b> Fax nu voor slechts <b>99,99!</b>",
    "categoryId": 826,
    "status": "ACTIVE",
    "price": {
        "priceType": "FIXED_PRICE",
        "priceUnit": "per_sqm",
        "amountCents": 5600,
        "originalAmountCents": 6500
    },
    "bidMicros": "10000",
    "budgets": {
        "daily": {
            "limitMicros": "UNLIMITED",
            "spentMicros": "1255000"
        },
        "total": {
            "limitMicros": "350000000",
            "spentMicros": "24370000"
        }
    },
    "salutation": "COMPANY",
    "sellerName": "My Shop",
    "postcode": "1097DN",
    "regionId": 1700195,
    "phoneNumber": "0207894561",
    "allowContactByEmail": true,
    "dateCreated": "2012-08-31T16:12:53Z",
    "dateLastUpdated": "2012-09-05T04:03:42Z",
    "vendorId": "OURSHOP-1423453-34",
    "campaignId": 58456,
    "links": {
        "self": "/ad/42",
        "category": "/category/826",
        "displayUrl": "www.ourshop.com/Faxes",
        "url": "http://www.ourshop.com/index.php?param1=value1&amp;param2=value2&amp;param3=value3"
    },
    "images": [
        {
            "src": "http://www.ourshop.com/img/brother_fax_big.jpg",
            "status": "OK",
            "dateLastUpdated": "2012-09-10T13:11:05Z",
            "links": {
                "50x70": "//i.marktplaats.nl/image23434_abc.jpg",
                "120x180": "//i.marktplaats.nl/image23434_def.jpg"
            }
        },
        {
            "src": "http://www.ourshop.com/img/brother_fax_side.jpg",
            "status": "OK",
            "dateLastUpdated": "2012-09-10T13:11:05Z",
            "links": {
                "50x70": "//i.marktplaats.nl/image397493_abc.jpg",
                "120x180": "//i.marktplaats.nl/image397493_def.jpg"
            }
        }
    ],
    "attributes": [
        {
            "key": "color",
            "label": "Kleur",
            "locale": "nl",
            "type": "STRING",
            "value": "Zwart",
            "recognized": true
        },
        {
            "key": "size",
            "label": "Maat",
            "locale": "nl",
            "type": "NUMBER",
            "value": 6,
            "recognized": true
        },
        {
            "key": "software",
            "label": "Software",
            "locale": "nl",
            "type": "LIST",
            "value": [
                "Apple OSX",
                "Microsoft Windows 7"
            ],
            "recognized": false
        }
    ],
    "shippingOptions": [
        {
            "type": "SHIP",
            "costCents": 495,
            "time": "2d-5d"
        },
        {
            "type": "PICKUP",
            "pickupLocation": "1097DN"
        }
    ]
}

GET /ad/byVendor/{vendorId} v3

Scope

api_ro or console_ro

Accept

application/sellside.ad-v3+json, application/json

Version 3 works just like GET /ad/byVendor/{vendorId} v2, except the response body contains an additional field statusReasons. This field is currently used to indicate the reason why a certain ad might be set to a certain status by our system. This could be due to, for example, an action (like new website domain approval) pending from the user, which is a mechanism used to prevent account takeovers from setting the website URL to a malicious one.

Example

GET /ad/byVendor/OURSHOP-1423453-34
Accept: application/sellside.ad-v3+json, application/json

200 OK
Content-Type: application/sellside.ad-v3+json; charset=utf-8

{
    "id": 42,
    "title": "Brother Fax voor 99,99",
    "description": "<b>NU extra voordelig op ourshop.com.</b> Fax nu voor slechts <b>99,99!</b>",
    "categoryId": 826,
    "externalId": "OURSHOP-1423453-34",
    "status": "ACTIVE",
    "currency": "EUR",
    "priceType": "FIXED_PRICE",
    "priceUnit": "per_sqm",
    "price": 9999,
    "cpc": 10,
    "totalBudget": 5000,
    "dailyBudget": 2000,
    "spentBudget": 2534,
    "salutation": "COMPANY",
    "sellerName": "My Shop",
    "postcode": "1097DN",
    "regionId": 1700195,
    "pageNumber": 27,
    "suggestedCpcForPageOne": 74,
    "phoneNumber": "0207894561",
    "allowContactByEmail": true,
    "allowPaypal": true,
    "dateCreated": "2012-08-31T16:12:53Z",
    "dateLastUpdated": "2012-09-05T04:03:42Z",
    "vendorId": "OURSHOP-1423453-34",
    "links": {
        "self": "/ad/42",
        "category": "/category/826",
        "displayUrl": "www.ourshop.com/Faxes",
        "url": "http://www.ourshop.com/index.php?param1=value1&amp;param2=value2&amp;param3=value3"
    },
    "images": [
        {
            "src": "http://www.ourshop.com/img/brother_fax_big.jpg",
            "status": "OK",
            "dateLastUpdated": "2012-09-10T13:11:05Z",
            "links": {
                "50x70": "//i.marktplaats.nl/image23434_abc.jpg",
                "120x180": "//i.marktplaats.nl/image23434_def.jpg"
            }
        },
        {
            "src": "http://www.ourshop.com/img/brother_fax_side.jpg",
            "status": "OK",
            "dateLastUpdated": "2012-09-10T13:11:05Z",
            "links": {
                "50x70": "//i.marktplaats.nl/image397493_abc.jpg",
                "120x180": "//i.marktplaats.nl/image397493_def.jpg"
            }
        }
    ],
    "attributes": [
        {
            "key": "color",
            "label": "Kleur",
            "locale": "nl",
            "type": "STRING",
            "value": "Zwart",
            "recognized": true
        },
        {
            "key": "size",
            "label": "Maat",
            "locale": "nl",
            "type": "NUMBER",
            "value": 6,
            "recognized": true
        },
        {
            "key": "software",
            "label": "Software",
            "locale": "nl",
            "type": "LIST",
            "value": [
                "Apple OSX",
                "Microsoft Windows 7"
            ],
            "recognized": false
        }
    ],
    "shippingOptions": [
        {
            "type": "SHIP",
            "cost": 0,
            "time": "2d-5d"
        },
        {
            "type": "PICKUP",
            "pickupLocation": "1097DN"
        }
    ],
    "statusReasons": [
        "DOMAIN_PENDING"
    ]
}

GET /ad/byVendor/{vendorId} v2

Scope

api_ro or console_ro

Accept

application/sellside.ad-v2+json, application/json

This URL returns a single ad with the given vendorId.

If the ad does not exist or does not belong to the user the server returns 404 Not Found. If the vendorId is bigger than 64 characters the server returns 400 Bad Request.

Note

The fields pageNumber and suggestedCpcForPageOne are currently expensive to compute. If you do not need their values consider excluding them to speed up the response. To exclude the fields add the following parameter to the request URL.

?_exclude=pageNumber,suggestedCpcForPageOne

Parameters

Name

Type

Description

_include

string

Comma-separated-list of fields to include. Optional, default is all fields.

_exclude

string

Comma-separated-list of fields to omit. Optional, default empty.

Errors

Field

Code

Error message

Description

vendorId

2005

value too long

max. length is 64 characters

Example

GET /ad/byVendor/OURSHOP-1423453-34
Accept: application/sellside.ad-v2+json, application/json

200 OK
Content-Type: application/sellside.ad-v2+json; charset=utf-8

{
    "id": 42,
    "title": "Brother Fax voor 99,99",
    "description": "<b>NU extra voordelig op ourshop.com.</b> Fax nu voor slechts <b>99,99!</b>",
    "categoryId": 826,
    "externalId": "OURSHOP-1423453-34",
    "status": "ACTIVE",
    "currency": "EUR",
    "priceType": "FIXED_PRICE",
    "priceUnit": "per_sqm",
    "price": 9999,
    "cpc": 10,
    "totalBudget": 5000,
    "dailyBudget": 2000,
    "spentBudget": 2534,
    "salutation": "COMPANY",
    "sellerName": "My Shop",
    "postcode": "1097DN",
    "regionId": 1700195,
    "pageNumber": 27,
    "suggestedCpcForPageOne": 74,
    "phoneNumber": "0207894561",
    "allowContactByEmail": true,
    "allowPaypal": true,
    "dateCreated": "2012-08-31T16:12:53Z",
    "dateLastUpdated": "2012-09-05T04:03:42Z",
    "vendorId": "OURSHOP-1423453-34",
    "links": {
        "self": "/ad/42",
        "category": "/category/826",
        "displayUrl": "www.ourshop.com/Faxes",
        "url": "http://www.ourshop.com/index.php?param1=value1&amp;param2=value2&amp;param3=value3"
    },
    "images": [
        {
            "src": "http://www.ourshop.com/img/brother_fax_big.jpg",
            "status": "OK",
            "dateLastUpdated": "2012-09-10T13:11:05Z",
            "links": {
                "50x70": "//i.marktplaats.nl/image23434_abc.jpg",
                "120x180": "//i.marktplaats.nl/image23434_def.jpg"
            }
        },
        {
            "src": "http://www.ourshop.com/img/brother_fax_side.jpg",
            "status": "OK",
            "dateLastUpdated": "2012-09-10T13:11:05Z",
            "links": {
                "50x70": "//i.marktplaats.nl/image397493_abc.jpg",
                "120x180": "//i.marktplaats.nl/image397493_def.jpg"
            }
        }
    ],
    "attributes": [
        {
            "key": "color",
            "label": "Kleur",
            "locale": "nl",
            "type": "STRING",
            "value": "Zwart",
            "recognized": true
        },
        {
            "key": "size",
            "label": "Maat",
            "locale": "nl",
            "type": "NUMBER",
            "value": 6,
            "recognized": true
        },
        {
            "key": "software",
            "label": "Software",
            "locale": "nl",
            "type": "LIST",
            "value": [
                "Apple OSX",
                "Microsoft Windows 7"
            ],
            "recognized": false
        }
    ],
    "shippingOptions": [
        {
            "type": "SHIP",
            "cost": 0,
            "time": "2d-5d"
        },
        {
            "type": "PICKUP",
            "pickupLocation": "1097DN"
        }
    ]
}