Responses

Impression

Contains data for displaying sponsored content. Can take different forms, depending on the value of acceptContent, that passed in request.

Values of acceptContent:

  • string
  • productIds
  • banners
  • sharedBanners

StringImpression

Field nameMandatoryTypeDescription
idYesstringImpression id
contentTypeYesstringContent type. Always has string
contentYesStringImpressionContentImpression content

StringImpressionContent

Строковое Impression content

Field nameMandatoryTypeDescription
idYesstringContent id
stringYesstringCustom text

Examples

An object of Impression type with a content field of type "string".

{
    "id": "impression identifier",
    "contentType": "string",
    "content": {
        "id": "content identifier",
        "string": "any string"
    }
}

ProductIdsImpression

Field nameMandatoryTypeDescription
idYesstringImpression id
contentTypeYesstringContent type. Always has productIds
contentYesProductIdsImpressionContentImpression content

ProductIdsImpressionContent

Impression content for product shelf.

Field nameMandatoryTypeDescription
idYesstringContent id
productIdsYesnumber arrayArray of product identifiers for impression

Examples

An object of Impression type with a content field of type "product shelf".

{
    "id": "impression identifier",
    "contentType": "productIds",
    "content": {
        "id": "content identifier",
        "productIds": [123, 321]
    }
}

BannersImpression

Field nameMandatoryTypeDescription
idYesstringImpression id
contentTypeYesstringContent type. Always has banners
contentYesBannersImpressionContentImpression content

BannersImpressionContent

Content for banner impression

Field nameMandatoryTypeDescription
idYesstringContent id
bannersYesBanner arrayBanners for impression

Banner

Banner information

Field nameMandatoryTypeDescription
targetUrlNostringURL for redirecting after click on banner
pictureURlYesstringImage URL

Examples

An object of Impression type with a content field of type "banners".

{
    "id": "impression identifier",
    "contentType": "banners",
    "content": {
        "id": "content identifier",
        "banners": [
            {
                "targetUrl" : "http://host/path",
                "pictureUrl": "http://host/path/image.png"
            },
            {
                "targetUrl" : "http://host/path",
                "pictureUrl": "http://host/path/image.png"
            },
        ]
    }
}

SharedBannersImpression

Impression content for shared banners. It differs from BannersImpression in that there can be banners from different advertisers.

Field nameMandatoryTypeDescription
idYesstringImpression id
contentTypeYesstringContent type. Always has sharedBanners
contentYesBannersImpressionContent arrayImpression content

BannerImpressionContent

Content for banner impression

Field nameMandatoryTypeDescription
idYesstringContent id
bannerYesBannerBanner for impression

Examples

An object of Impression type with a content field of type "shared banners".

{
    "id": "impression identifier",
    "contentType": "sharedBanners",
    "content": [
        {
            "id": "content identifier",
            "banner": {
                "targetUrl" : "http://host/path",
                "pictureUrl": "http://host/path/image.png"
            }
        },
        {
            "id": "content identifier",
            "banner": {
                "targetUrl" : "http://host/path",
                "pictureUrl": "http://host/path/image.png"
            }
        }
    ]
}