Skip to main content

Inventory API

Inventory

The structure and makeup of the places where ads are going to be delivered.

Publishers

List a publisher

GET /v1/inventory/publisher/{id}

Retrieves details of a publisher by it's ID.

Request body

Parameter In Required Type Description
id path Yes integer The publisher's ID.

Response - 200

{
    "id": 1,
    "parentId": 0,
    "companyName": "Main Publisher",
    "quote": "",
    "active": 1,
    "companyAddress": "",
    "companyNumber": "",
    "companyZip": "",
    "companyCity": "",
    "companyCountry": "",
    "companyTelephone": "",
    "companyFax": "",
    "companyEmail": "",
    "companyURL": "",
    "companyVat": "",
    "companyBankAccount": "",
    "contactName": "",
    "contactFirstName": "",
    "contactAddress": "",
    "contactNumber": "",
    "contactZip": "",
    "contactCity": "",
    "contactCountry": "",
    "contactTelephone": "",
    "contactFax": "",
    "contactEmail": "",
    "description": "",
    "paymentMethod": "",
    "invoicingParty": ""
}

Response codes

Status Meaning
200 Publisher retrieved.
400 Bad request - invalid input or parameters.
401/403 Not authenticated / not allowed.
404 Not Found - Resource not found.
405 Method not allowed
406 Not acceptable
409 Conflict.
415 Unssuported media type
500 Internal Server Error - Unexpected failure.

Update a publisher

PUT /v1/inventory/publisher/{id}

Updates the name, parent publisher, and active status of an existing publisher. Fields the request omits are left as they are.

Request body

Parameter In Required Type Description
parentPublisherId body No integer The ID of the parent publisher.
name body No string Name of the publisher
active body No boolean Is the publisher active?

Updating a publisher

{
    "name": "Demo Publisher"
}

Response - 200

{
    "id": 1,
    "parentId": 0,
    "companyName": "Demo Publisher",
    "quote": "",
    "active": 1,
    "companyAddress": "",
    "companyNumber": "",
    "companyZip": "",
    "companyCity": "",
    "companyCountry": "",
    "companyTelephone": "",
    "companyFax": "",
    "companyEmail": "",
    "companyURL": "",
    "companyVat": "",
    "companyBankAccount": "",
    "contactName": "",
    "contactFirstName": "",
    "contactAddress": "",
    "contactNumber": "",
    "contactZip": "",
    "contactCity": "",
    "contactCountry": "",
    "contactTelephone": "",
    "contactFax": "",
    "contactEmail": "",
    "description": "",
    "paymentMethod": "",
    "invoicingParty": ""
}

Response codes

Status Meaning
200 Publisher updated.
400 Bad request - invalid input or parameters.
401/403 Not authenticated / not allowed.
404 Not Found - Resource not found.
405 Method not allowed
406 Not acceptable
409 Conflict.
415 Unsupported media type
500 Internal Server Error - Unexpected failure.

Delete a publisher

DELETE /v1/inventory/publisher/{id}

Sets a publisher to inactive.

Request body

Parameter In Required Type Description
id path Yes integer The publisher's ID.

Response codes

Status Meaning
204 Publisher set to inactive.
400 Bad request - invalid input or parameters.
401/403 Not authenticated / not allowed.
404 Not Found - Resource not found.
405 Method not allowed
406 Not acceptable
409 Conflict.
415 Unsupported media type
500 Internal Server Error - Unexpected failure.

List publishers

GET /v1/inventory/publisher

Retrieves all publishers and their information.

Response - 200

[
    {
        "id": 1,
        "parentId": 0,
        "companyName": "Demo Publisher",
        "quote": "",
        "active": 1,
        "companyAddress": "",
        "companyNumber": "",
        "companyZip": "",
        "companyCity": "",
        "companyCountry": "",
        "companyTelephone": "",
        "companyFax": "",
        "companyEmail": "",
        "companyURL": "",
        "companyVat": "",
        "companyBankAccount": "",
        "contactName": "",
        "contactFirstName": "",
        "contactAddress": "",
        "contactNumber": "",
        "contactZip": "",
        "contactCity": "",
        "contactCountry": "",
        "contactTelephone": "",
        "contactFax": "",
        "contactEmail": "",
        "description": "",
        "paymentMethod": "",
        "invoicingParty": ""
    },
    {
        "id": 2,
        "parentId": 1,
        "companyName": "Example Demo Publisher",
        "quote": "",
        "active": 0,
        "companyAddress": "",
        "companyNumber": "",
        "companyZip": "",
        "companyCity": "",
        "companyCountry": "",
        "companyTelephone": "",
        "companyFax": "",
        "companyEmail": "",
        "companyURL": "",
        "companyVat": "",
        "companyBankAccount": "",
        "contactName": "",
        "contactFirstName": "",
        "contactAddress": "",
        "contactNumber": "",
        "contactZip": "",
        "contactCity": "",
        "contactCountry": "",
        "contactTelephone": "",
        "contactFax": "",
        "contactEmail": "",
        "description": "",
        "paymentMethod": "-",
        "invoicingParty": ""
    }
]

Create a publisher

POST /v1/inventory/publisher

Creates a new publisher.

Request body

Parameter In Required Type Description
parentPublisherId body No integer The ID of the parent publisher. Leave blank if the new publisher is a main publisher
name body Yes string Name of the publisher
active body No boolean Is the publisher active? Default is true

Creating a new publisher

{
  "parentPublisherId": 1,
  "name": "Example API Publisher",
  "active": true
}

Response - 201

{
    "id": 3,
    "parentId": 1,
    "companyName": "Example API Publisher",
    "quote": "",
    "active": 1,
    "companyAddress": "",
    "companyNumber": "",
    "companyZip": "",
    "companyCity": "",
    "companyCountry": "",
    "companyTelephone": "",
    "companyFax": "",
    "companyEmail": "",
    "companyURL": "",
    "companyVat": "",
    "companyBankAccount": "",
    "contactName": "",
    "contactFirstName": "",
    "contactAddress": "",
    "contactNumber": "",
    "contactZip": "",
    "contactCity": "",
    "contactCountry": "",
    "contactTelephone": "",
    "contactFax": "",
    "contactEmail": "",
    "description": "",
    "paymentMethod": "-",
    "invoicingParty": ""
}

Response codes

Status Meaning
201 Publisher created.
400 Bad request - invalid input or parameters.
401/403 Not authenticated / not allowed.
404 Not Found - Resource not found.
405 Method not allowed
406 Not acceptable
409 Conflict.
415 Unsupported media type
500 Internal Server Error - Unexpected failure.

Publications

List a publication

GET /v1/inventory/publication/{id}

List a single publication by ID.

Request body

Parameter In Required Type Description
id path Yes integer The publisher's ID.

Response - 200

{
    "id": 3,
    "companyName": "Demo Sponsored Placements",
    "companyAddress": "",
    "companyNumber": "",
    "companyZip": "",
    "companyCity": "",
    "companyCountry": "",
    "companyTel": "",
    "companyFax": "",
    "companyUrl": "https://pool-demo.adhese.com/projects/marketing/index.html",
    "companyEmail": "",
    "publishersId": 1,
    "quote": "",
    "parentPublicationsId": 0,
    "description": "",
    "comment": "",
    "active": 1,
    "rank": 0,
    "screenshotExtension": "",
    "catchphrase": "",
    "language": "",
    "numberOfAuthors": 0,
    "inventoryCategory": "sponsored_product"
}

Response codes

Status Meaning
200 Publication retrieved.
400 Bad request - invalid input or parameters.
401/403 Not authenticated / not allowed.
404 Not Found - Resource not found.
405 Method not allowed
406 Not acceptable
409 Conflict.
415 Unsupported media type
500 Internal Server Error - Unexpected failure.

Update a publication

PUT /v1/inventory/publication/{id}

Updates the name, parent publisher, active status, quote and website of an existing publication. Fields the request omits are left as they are.

Request body

Parameter In Required Type Description
parentPublisherId body No integer The ID of the publication's publisher.
active body No boolean Is the publication active? Default is true.
name body Yes string Name of the publication.
quote body No string Quote field of the publication.
website body Yes string Website of the publication.

Updating a publication

{
  "publisherId": 1,
  "active": true,
  "name": "Demo Display",
  "quote": "DD",
  "website": "https://pool-demo.adhese.com/projects/marketing/index.html"
}

Response - 200

{
    "id": 1,
    "companyName": "Demo Display",
    "companyAddress": "",
    "companyNumber": "",
    "companyZip": "",
    "companyCity": "",
    "companyCountry": "",
    "companyTel": "",
    "companyFax": "",
    "companyUrl": "https://pool-demo.adhese.com/projects/marketing/index.html",
    "companyEmail": "",
    "publishersId": 1,
    "quote": "DD",
    "parentPublicationsId": 0,
    "description": "",
    "comment": "",
    "active": 1,
    "rank": 0,
    "screenshotExtension": "",
    "catchphrase": "",
    "language": "",
    "numberOfAuthors": 0,
    "inventoryCategory": "display"
}

Response codes

Status Meaning
200 Publication retrieved.
400 Bad request - invalid input or parameters.
401/403 Not authenticated / not allowed.
404 Not Found - Resource not found.
405 Method not allowed
406 Not acceptable
409 Conflict.
415 Unsupported media type
500 Internal Server Error - Unexpected failure.

Delete a publication

DELETE /v1/inventory/publication/{id}

Sets a publication to inactive.

Request body

Parameter In Required Type Description
id path Yes integer The publication's ID.

Response codes

Status Meaning
204 Publication set to inactive.
400 Bad request - invalid input or parameters.
401/403 Not authenticated / not allowed.
404 Not Found - Resource not found.
405 Method not allowed
406 Not acceptable
409 Conflict.
415 Unsupported media type
500 Internal Server Error - Unexpected failure.

List all publications under a publisher

GET /v1/inventory/publication

List all publications under one or more publishers.

Request body

Parameter In Required Type Description
publisherIds parameter Yes integer The publisher IDs whose publications you want listed. The publisher IDs are comma separated.

Response - 200

[
    {
        "id": 1,
        "companyName": "Demo Display",
        "companyAddress": "",
        "companyNumber": "",
        "companyZip": "",
        "companyCity": "",
        "companyCountry": "",
        "companyTel": "",
        "companyFax": "",
        "companyUrl": "https://pool-demo.adhese.com/projects/marketing/index.html",
        "companyEmail": "",
        "publishersId": 1,
        "quote": "DD",
        "parentPublicationsId": 0,
        "description": "",
        "comment": "",
        "active": 1,
        "rank": 0,
        "screenshotExtension": "",
        "catchphrase": "",
        "language": "",
        "numberOfAuthors": 0,
        "inventoryCategory": "display"
    },
    {
        "id": 2,
        "companyName": "Demo DOOH",
        "companyAddress": "",
        "companyNumber": "",
        "companyZip": "",
        "companyCity": "",
        "companyCountry": "",
        "companyTel": "",
        "companyFax": "",
        "companyUrl": "https://adhese.eu",
        "companyEmail": "",
        "publishersId": 1,
        "quote": "",
        "parentPublicationsId": 0,
        "description": "",
        "comment": "",
        "active": 1,
        "rank": 0,
        "screenshotExtension": "",
        "catchphrase": "",
        "language": "",
        "numberOfAuthors": 0,
        "inventoryCategory": "in_store"
    },
    {
        "id": 3,
        "companyName": "Demo Sponsored Placements",
        "companyAddress": "",
        "companyNumber": "",
        "companyZip": "",
        "companyCity": "",
        "companyCountry": "",
        "companyTel": "",
        "companyFax": "",
        "companyUrl": "https://pool-demo.adhese.com/projects/marketing/index.html",
        "companyEmail": "",
        "publishersId": 1,
        "quote": "",
        "parentPublicationsId": 0,
        "description": "",
        "comment": "",
        "active": 1,
        "rank": 0,
        "screenshotExtension": "",
        "catchphrase": "",
        "language": "",
        "numberOfAuthors": 0,
        "inventoryCategory": "sponsored_product"
    }
]

Response codes

Status Meaning
200 Publications retrieved.
400 Bad request - invalid input or parameters.
401/403 Not authenticated / not allowed.
404 Not Found - Resource not found.
405 Method not allowed
406 Not acceptable
409 Conflict.
415 Unsupported media type
500 Internal Server Error - Unexpected failure.

Create a publication

POST /v1/inventory/publication

Create a new publication.

Request body

Parameter In Required Type Description
publisherId body No integer The ID of the parent publisher. Leave blank if the new publisher is a main publisher
active body No boolean Is the publication active? Default is true.
name body Yes string Name of the publication.
quote body No string Quote field of the publication.
website body Yes string Website of the publication.

Creating a new publication

{
  "publisherId": 3,
  "active": true,
  "name": "String Created Publication",
  "quote": "SCP",
  "website": "https://pool-demo.adhese.com/projects/marketing/index.html"
}

Response - 201

{
    "id": 5,
    "companyName": "String Created Publication",
    "companyAddress": "",
    "companyNumber": "",
    "companyZip": "",
    "companyCity": "",
    "companyCountry": "",
    "companyTel": "",
    "companyFax": "",
    "companyUrl": "https://pool-demo.adhese.com/projects/marketing/index.html",
    "companyEmail": "",
    "publishersId": 3,
    "quote": "SCP",
    "parentPublicationsId": 0,
    "description": "",
    "comment": "",
    "active": 1,
    "rank": 0,
    "screenshotExtension": "",
    "catchphrase": "",
    "language": "",
    "numberOfAuthors": 0,
    "inventoryCategory": null
}

Response codes

Status Meaning
201 Publication created.
400 Bad request - invalid input or parameters.
401/403 Not authenticated / not allowed.
404 Not Found - Resource not found.
405 Method not allowed
406 Not acceptable
409 Conflict.
415 Unsupported media type
500 Internal Server Error - Unexpected failure.

Positions

List a single position

GET /v1/inventory/position/{id}

Lists the chosen positions information by ID.

Request body

Parameter In Required Type Description
positionId path Yes integer The position ID whose information you want listed.

Response - 200

{
    "id": 9,
    "publisherId": 1,
    "transferId": 0,
    "active": true,
    "creation": "Mar 25, 2026, 2:31:29 PM CET",
    "edited": "Mar 25, 2026, 2:31:29 PM CET",
    "name": "",
    "formatId": 4,
    "formatName": "Billboard",
    "formatWidth": 970,
    "formatHeight": 250,
    "formatSize": 0,
    "locationId": 5,
    "locationName": "ROS",
    "locationTypeId": 10,
    "publicationName": "Demo Display",
    "previewUrl": "",
    "url": ""
}

Response codes

Status Meaning
200 Position listed.
400 Bad request - invalid input or parameters.
401/403 Not authenticated / not allowed.
404 Not Found - Resource not found.
405 Method not allowed
406 Not acceptable
409 Conflict.
415 Unsupported media type
500 Internal Server Error - Unexpected failure.

Updating a position

PUT /v1/inventory/position/{id}

Updates a chosen positions name, format, location, position type, active status, and URL. Fields the request omits are left as they are.

Request body

Parameter In Required Type Description
id path Yes integer The positions ID.
active body No boolean Whether the position is active or not.
name body No string Name of the position, recommended for use with the Campaign Manager UI.
formatId body No integer ID of the positions format.
locationId body No integer ID of the positions location.
url body No string URL for identifying the position.
positionTypeId body No integer ID of the position type (when applicable).

Updating a position

{
  "active": true,
  "name": "SCP Halfpage",
  "formatId": 1,
  "locationId": 9,
  "url": "_scp_halfpage",
  "positionTypeId": 10
}

Response - 200

{
    "id": 19,
    "publisherId": 5,
    "transferId": 0,
    "active": true,
    "creation": "Sep 22, 2026, 11:46:01 AM CEST",
    "edited": "Sep 22, 2026, 11:52:26 AM CEST",
    "name": "SCP Halfpage",
    "formatId": 1,
    "formatName": "Halfpage",
    "formatWidth": 300,
    "formatHeight": 600,
    "formatSize": 0,
    "locationId": 9,
    "locationName": "SCP",
    "locationTypeId": 10,
    "publicationName": "String Created Publication",
    "previewUrl": "",
    "url": "_scp_halfpage"
}

Response codes

Status Meaning
200 Position updated.
400 Bad request - invalid input or parameters.
401/403 Not authenticated / not allowed.
404 Not Found - Resource not found.
405 Method not allowed
406 Not acceptable
409 Conflict.
415 Unsupported media type
500 Internal Server Error - Unexpected failure.

Delete a position

DELETE /v1/inventory/position/{id}

Sets a position to inactive by ID.

Request body

Parameter In Required Type Description
positionId path Yes integer The ID of the position you want deactivated.

Response codes

Status Meaning
204 Position set to inactive.
400 Bad request - invalid input or parameters.
401/403 Not authenticated / not allowed.
404 Not Found - Resource not found.
405 Method not allowed
406 Not acceptable
409 Conflict.
415 Unsupported media type
500 Internal Server Error - Unexpected failure.

List all positions

GET /v1/inventory/position

List the details of all positions.

Request body

Parameter In Required Type Description
publicationId body No integer The publication ID of the publication you want to filter positions on.
active body No boolean Filter on the active or inactive status of positions.

Response - 200

[
    {
        "id": 1,
        "publisherId": 1,
        "transferId": 0,
        "active": true,
        "creation": "Mar 13, 2026, 3:09:34 PM CET",
        "edited": "Mar 13, 2026, 3:09:34 PM CET",
        "name": "",
        "formatId": 4,
        "formatName": "Billboard",
        "formatWidth": 970,
        "formatHeight": 250,
        "formatSize": 0,
        "locationId": 2,
        "locationName": "Kitchen",
        "locationTypeId": 10,
        "publicationName": "Demo Display",
        "previewUrl": "",
        "url": ""
    },
    {
        "id": 2,
        "publisherId": 1,
        "transferId": 0,
        "active": true,
        "creation": "Mar 13, 2026, 3:09:46 PM CET",
        "edited": "Mar 13, 2026, 3:12:44 PM CET",
        "name": "",
        "formatId": 1,
        "formatName": "Halfpage",
        "formatWidth": 300,
        "formatHeight": 600,
        "formatSize": 0,
        "locationId": 2,
        "locationName": "Kitchen",
        "locationTypeId": 10,
        "publicationName": "Demo Display",
        "previewUrl": "",
        "url": ""
    },
    {
        "id": 3,
        "publisherId": 1,
        "transferId": 0,
        "active": true,
        "creation": "Mar 13, 2026, 3:09:59 PM CET",
        "edited": "Mar 13, 2026, 3:12:56 PM CET",
        "name": "",
        "formatId": 3,
        "formatName": "Wide Skyscraper",
        "formatWidth": 160,
        "formatHeight": 600,
        "formatSize": 0,
        "locationId": 3,
        "locationName": "Electronics",
        "locationTypeId": 10,
        "publicationName": "Demo Display",
        "previewUrl": "",
        "url": ""
    },
]

Response codes

Status Meaning
200 Positions listed.
400 Bad request - invalid input or parameters.
401/403 Not authenticated / not allowed.
404 Not Found - Resource not found.
405 Method not allowed
406 Not acceptable
409 Conflict.
415 Unsupported media type
500 Internal Server Error - Unexpected failure.

Create a position

POST /v1/inventory/position

Creates a new position (ad slot) linked to a location, format, and position type. A request that omits the active status creates an active position.

Request body

Parameter In Required Type Description
active body No boolean Whether the position is active or not. A request that omits the active status creates an active position.
name body No string Name of the position, recommended for use with the Campaign Manager UI.
formatId body Yes integer ID of the positions format.
locationId body Yes integer ID of the positions location.
url body No string URL for identifying the position.
positionTypeId body No integer ID of the position type (when applicable).

Creating a new position

{
  "active": true,
  "name": "SCP Billboard",
  "formatId": 4,
  "locationId": 9,
  "url": "_scp_billboard",
  "positionTypeId": 10
}

Response - 201

{
    "id": 20,
    "publisherId": 5,
    "transferId": 0,
    "active": true,
    "creation": "Sep 22, 2026, 1:56:07 PM CEST",
    "edited": "Sep 22, 2026, 1:56:07 PM CEST",
    "name": "SCP Billboard",
    "formatId": 4,
    "formatName": "Billboard",
    "formatWidth": 970,
    "formatHeight": 250,
    "formatSize": 0,
    "locationId": 9,
    "locationName": "SCP",
    "locationTypeId": 10,
    "publicationName": "String Created Publication",
    "previewUrl": null,
    "url": "_scp_billboard"
}

Response codes

Status Meaning
201 Position created.
400 Bad request - invalid input or parameters.
401/403 Not authenticated / not allowed.
404 Not Found - Resource not found.
405 Method not allowed
406 Not acceptable
409 Conflict.
415 Unsupported media type
500 Internal Server Error - Unexpected failure.

Locations

List a single location

GET /v1/inventory/location/{id}

Retrieves a single location by its ID.

Request body

Parameter In Required Type Description
locationId path Yes integer The location ID of the location you want to list.

Response - 200

{
    "id": 9,
    "name": "SCP",
    "publicationId": 5,
    "publicationQuote": "SCP",
    "impressions": 0,
    "impressionsWeekend": 0,
    "contacts": 0,
    "contactsWeekend": 0,
    "isChannel": 0,
    "url": "scp_home",
    "previewUrl": "",
    "code": null,
    "price": 0.0,
    "active": true,
    "locationTypes": [
        "full",
        "guaranteed"
    ],
    "numberOfBookings": 0
}

Response codes

Status Meaning
200 Location listed.
400 Bad request - invalid input or parameters.
401/403 Not authenticated / not allowed.
404 Not Found - Resource not found.
405 Method not allowed
406 Not acceptable
409 Conflict.
415 Unsupported media type
500 Internal Server Error - Unexpected failure.

Update a location

PUT /v1/inventory/location/{id}

Updates the name, URL, channel option code, publication, and location types of an existing location.

Request body

Parameter In Required Type Description
locationId path Yes integer The location ID of the location you want to list.
publicationId body Yes integer ID of the publication to which the location belongs.
name body No string Name of the location.
url body No string URL for identifying the location on the webpage.
channelOptionCode body No integer Determines if the location is for single positions or Channels. 0 means single position. Use Use GET /v1/inventory/location-channel-option for other valid channelOptionCode values for your account.
locationTypes body No string Location types that belong to this location. Options are guranteed and/or full
code body No string Location code.
price body No integer Location price.

Response - 200

{
    "id": 9,
    "name": "SCP",
    "publicationId": 5,
    "publicationQuote": "SCP",
    "impressions": 0,
    "impressionsWeekend": 0,
    "contacts": 0,
    "contactsWeekend": 0,
    "isChannel": 0,
    "url": "scp_overview",
    "previewUrl": "",
    "code": "001",
    "price": 1.0,
    "active": true,
    "locationTypes": [
        "full",
        "guaranteed"
    ],
    "numberOfBookings": 0
}

Response codes

Status Meaning
200 Location updated.
400 Bad request - invalid input or parameters.
401/403 Not authenticated / not allowed.
404 Not Found - Resource not found.
405 Method not allowed
406 Not acceptable
409 Conflict.
415 Unsupported media type
500 Internal Server Error - Unexpected failure.

Delete a location

DELETE /v1/inventory/location/{id}

Set a location to inactive by ID.

Request body

Parameter In Required Type Description
locationId path Yes integer The ID of the location that you want deactivated.

Response codes

Status Meaning
204 Location set to inactive.
400 Bad request - invalid input or parameters.
401/403 Not authenticated / not allowed.
404 Not Found - Resource not found.
405 Method not allowed
406 Not acceptable
409 Conflict.
415 Unsupported media type
500 Internal Server Error - Unexpected failure.

List all locations by publication

GET /v1/inventory/location

Lists all locations under a publication by it's ID.

Request body

Parameter In Required Type Description
publicationId parameters Yes integer The ID of the publication for which you want to list all locations.

Response - 200

[
    {
        "id": 4,
        "name": "Audio",
        "publicationId": 1,
        "publicationQuote": "DD",
        "impressions": 0,
        "impressionsWeekend": 0,
        "contacts": 0,
        "contactsWeekend": 0,
        "isChannel": 0,
        "url": "demo.com_audio",
        "previewUrl": "",
        "code": null,
        "price": 5.0,
        "active": true,
        "locationTypes": [
            "full"
        ],
        "numberOfBookings": 0
    },
    {
        "id": 3,
        "name": "Electronics",
        "publicationId": 1,
        "publicationQuote": "DD",
        "impressions": 0,
        "impressionsWeekend": 0,
        "contacts": 0,
        "contactsWeekend": 0,
        "isChannel": 0,
        "url": "demo.com_electronics",
        "previewUrl": "",
        "code": null,
        "price": 5.0,
        "active": true,
        "locationTypes": [
            "full",
            "guaranteed"
        ],
        "numberOfBookings": 0
    },
    {
        "id": 1,
        "name": "Home",
        "publicationId": 1,
        "publicationQuote": "DD",
        "impressions": 0,
        "impressionsWeekend": 0,
        "contacts": 0,
        "contactsWeekend": 0,
        "isChannel": 0,
        "url": "demo.com_home",
        "previewUrl": "",
        "code": "demo_web_home",
        "price": 5.0,
        "active": true,
        "locationTypes": [
            "full",
            "guaranteed"
        ],
        "numberOfBookings": 3
    },
    {
        "id": 2,
        "name": "Kitchen",
        "publicationId": 1,
        "publicationQuote": "DD",
        "impressions": 0,
        "impressionsWeekend": 0,
        "contacts": 0,
        "contactsWeekend": 0,
        "isChannel": 0,
        "url": "demo.com_kitchen",
        "previewUrl": "",
        "code": null,
        "price": 5.0,
        "active": true,
        "locationTypes": [
            "full"
        ],
        "numberOfBookings": 0
    },
    {
        "id": 5,
        "name": "ROS",
        "publicationId": 1,
        "publicationQuote": "DD",
        "impressions": 0,
        "impressionsWeekend": 0,
        "contacts": 0,
        "contactsWeekend": 0,
        "isChannel": 3,
        "url": "",
        "previewUrl": "",
        "code": null,
        "price": 5.0,
        "active": true,
        "locationTypes": [
            "full"
        ],
        "numberOfBookings": 1
    }
]

Response codes

Status Meaning
200 Locations listed.
400 Bad request - invalid input or parameters.
401/403 Not authenticated / not allowed.
404 Not Found - Resource not found.
405 Method not allowed
406 Not acceptable
409 Conflict.
415 Unsupported media type
500 Internal Server Error - Unexpected failure.

Create a new location

POST /v1/inventory/location

Create a new location under a publication by ID.

Request body

Parameter In Required Type Description
publicationId body Yes integer ID of the publication to which the location belongs.
name body No string Name of the location.
url body No string URL for identifying the location on the webpage.
channelOptionCode body No integer Determines if the location is for single positions or Channels. 0 means single position. Use Use GET /v1/inventory/location-channel-option for other valid channelOptionCode values for your account.
locationTypes body No string Location types that belong to this location. Options are guranteed and/or full
code body No string Location code.
price body No integer Location price.

Response - 201

{
    "id": 11,
    "name": "SCP BR",
    "publicationId": 5,
    "publicationQuote": "SCP",
    "impressions": 0,
    "impressionsWeekend": 0,
    "contacts": 0,
    "contactsWeekend": 0,
    "isChannel": 0,
    "url": "scp_br",
    "previewUrl": null,
    "code": "002",
    "price": 1.2,
    "active": true,
    "locationTypes": [
        "full",
        "guaranteed"
    ],
    "numberOfBookings": 0
}

Response codes

Status Meaning
201 Location created.
400 Bad request - invalid input or parameters.
401/403 Not authenticated / not allowed.
404 Not Found - Resource not found.
405 Method not allowed
406 Not acceptable
409 Conflict.
415 Unsupported media type
500 Internal Server Error - Unexpected failure.

Miscellaneous Inventory APIs

List position types

GET /v1/inventory/position-type

Lists all available position types for the account.

Response - 200

[
    {
        "id": 1,
        "name": "",
        "templateFile": "",
        "thirdPartyQuotum": 0
    },
    {
        "id": 13,
        "name": "newsletter img tag",
        "templateFile": "",
        "thirdPartyQuotum": 0
    },
    {
        "id": 10,
        "name": "normal javascript",
        "templateFile": "",
        "thirdPartyQuotum": 0
    },
    {
        "id": 12,
        "name": "normal javascript / no empty",
        "templateFile": "",
        "thirdPartyQuotum": 0
    }
]

Response codes

Status Meaning 200 Position types retrieved. 400 Bad request - invalid input or parameters. 401/403 Not authenticated / not allowed. 404 Not Found - Resource not found. 405 Method not allowed 406 Not acceptable 409 Conflict. 415 Unsupported media type 500 Internal Server Error - Unexpected failure.

List location channel options

GET /v1/inventory/location-channel-option

Lists all location channel options (such as normal position and available group levels).

Response - 200

[
    {
        "code": 0,
        "name": "normal position (no group)"
    },
    {
        "code": 1,
        "name": "group level 1"
    },
    {
        "code": 2,
        "name": "group level 2"
    },
    {
        "code": 3,
        "name": "group level 3"
    },
    {
        "code": 4,
        "name": "group level 4"
    },
    {
        "code": 5,
        "name": "group level 5"
    }
]

Response codes

Status Meaning 200 Location channel options retrieved. 400 Bad request - invalid input or parameters. 401/403 Not authenticated / not allowed. 404 Not Found - Resource not found. 405 Method not allowed 406 Not acceptable 409 Conflict. 415 Unsupported media type 500 Internal Server Error - Unexpected failure.

List available formats

GET /v1/inventory/format

Retrieves all available ad formats (templates) that can be assigned to positions.

Response - 200

[
    {
        "id": 4,
        "name": "Billboard",
        "width": 970,
        "height": 250,
        "active": true,
        "comment": "",
        "templateFile": "",
        "allTogetherOrder": 0,
        "hasCompletionRateEvents": 0,
        "codeTag": "billboard",
        "codeBook": "billboard"
    },
    {
        "id": 1,
        "name": "Halfpage",
        "width": 300,
        "height": 600,
        "active": true,
        "comment": "",
        "templateFile": "",
        "allTogetherOrder": 0,
        "hasCompletionRateEvents": 0,
        "codeTag": "halfpage",
        "codeBook": "halfpage"
    },
    {
        "id": 6,
        "name": "Landscape Screen",
        "width": 16,
        "height": 9,
        "active": true,
        "comment": "",
        "templateFile": "",
        "allTogetherOrder": 0,
        "hasCompletionRateEvents": 0,
        "codeTag": "landscape",
        "codeBook": "landscape"
    },
    {
        "id": 5,
        "name": "Leaderboard",
        "width": 728,
        "height": 90,
        "active": true,
        "comment": "",
        "templateFile": "",
        "allTogetherOrder": 0,
        "hasCompletionRateEvents": 0,
        "codeTag": "leaderboard",
        "codeBook": "leaderboard"
    },
    {
        "id": 2,
        "name": "Medium Rectangle",
        "width": 300,
        "height": 250,
        "active": true,
        "comment": "",
        "templateFile": "",
        "allTogetherOrder": 0,
        "hasCompletionRateEvents": 0,
        "codeTag": "imu",
        "codeBook": "imu;halfpage"
    },
    {
        "id": 7,
        "name": "Portrait Screen",
        "width": 9,
        "height": 16,
        "active": true,
        "comment": "",
        "templateFile": "",
        "allTogetherOrder": 0,
        "hasCompletionRateEvents": 0,
        "codeTag": "portrait",
        "codeBook": "portrait"
    },
    {
        "id": 3,
        "name": "Wide Skyscraper",
        "width": 160,
        "height": 600,
        "active": true,
        "comment": "",
        "templateFile": "",
        "allTogetherOrder": 0,
        "hasCompletionRateEvents": 0,
        "codeTag": "skyscraper",
        "codeBook": "skyscraper"
    }
]

Response codes

Status Meaning 200 Formats retrieved. 400 Bad request - invalid input or parameters. 401/403 Not authenticated / not allowed. 404 Not Found - Resource not found. 405 Method not allowed 406 Not acceptable 409 Conflict. 415 Unsupported media type 500 Internal Server Error - Unexpected failure.