Security, Privacy, AI and CSR information for all Piano products now lives in one place. Explore our Compliance Center.
Audience
English French
English French

Feed REST API

This API exposes operations to allow management of Feeds within the cX::ad platform.

This API can be accessed by users with the appropriate permissions to manage Feeds and supports the following combination of operations on Ad domain objects:

Object

Supported operations

Feed list

GET

Feed

POST, GET, PUT and DELETE

Retrieving the list of available Feeds

The list of all Feeds available to a user to associate with AdSpace(s) can be retrieved using the GET operation.

GET

Retrieve the list of Feeds available to the user.

https://{cxadbaseurl}/api/secure/feeds

Parameters:

  • cxadbaseurl the base URL of the cX::ad system

Example command:

curl -s -H "Content-type: text/xml" -u jsmith123:password1 -X GET https://cxad.cxense.com/api/secure/feeds

This XML example shows the contents returned from a typical GET call:


<?xml version="1.0"?>
<cx:feeds xmlns:cx="http://cxense.com/cxad/api/cxad">
  <cx:feed>
    <cx:feedId>0000000000004656</cx:feedId>
    <cx:name>Feed (CPC Product, CPM Product)</cx:name>
    <cx:products>
      <cx:productId group="0">0000000000004abc</cx:productId>
      <cx:productId group="1">000000000000123a</cx:productId>
    </cx:products>
    <cx:associableByRoles>
      <cx:role>FULLSERVPUB</cx:role>
      <cx:role>SELFSERVPUB</cx:role>
    </cx:associableByRoles>
  </cx:feed>
</cx:feeds>

Individual Feeds

The POST, GET, PUT and DELETE operations are supported for management of individual Feeds.

POST

Perform a POST operation with the following URL to create a new Feed

https://{cxadbaseurl}/api/secure/feed

Parameters:

  • cxadbaseurl the base URL of the cX::ad system

This XML example shows the contents required to be supplied for a POST call:

<?xml version="1.0" encoding="UTF-8"?>
<cx:feed xmlns:cx="http://cxense.com/cxad/api/cxad">
  <cx:name>Test Feed</cx:name>
  <cx:products>
    <cx:productId group="0">0000000000004abc</cx:productId>
    <cx:productId group="1">000000000000123a</cx:productId>
  </cx:products>
  <cx:associableByRoles>
    <cx:role>FULLSERVPUB</cx:role>
    <cx:role>SELFSERVPUB</cx:role>
  </cx:associableByRoles>
</cx:feed>

Example commands:

curl -s -H "Content-type: text/xml" -u jsmith123:password1 -X POST https://cxad.cxense.com/api/secure/feed -d @input.xml

GET

Retrieve the Feed with the given feedId

https://{cxadbaseurl}/api/secure/feed/{feedId}

Parameters:

  • cxadbaseurl the base URL of the cX::ad system

  • feedId the id of the Feed to be retrieved

This XML example shows the contents returned from a typical GET call:

<?xml version="1.0" encoding="UTF-8"?>
<cx:feed xmlns:cx="http://cxense.com/cxad/api/cxad">
  <cx:feedId>0000000000001212<cx:feedId>
  <cx:name>Test Feed</cx:name>
  <cx:products>
    <cx:productId group="0">0000000000004abc</cx:productId>
    <cx:productId group="1">000000000000123a</cx:productId>
  </cx:products>
  <cx:associableByRoles>
    <cx:role>FULLSERVPUB</cx:role>
    <cx:role>SELFSERVPUB</cx:role>
  </cx:associableByRoles>
</cx:feed>

 

Example command:

curl -s -H "Content-type: text/xml" -u jsmith123:password1 -X GET https://cxad.cxense.com/api/secure/feed/0000000000039306

PUT

Update the Feed with the given feedId

https://{cxadbaseurl}/api/secure/feed/{feedId}

Parameters:

  • cxadbaseurl the base URL of the cX::ad system

  • feedId the id of the Feed to be updated

This XML example shows the contents required to be supplied for a PUT call:

<?xml version="1.0" encoding="UTF-8"?>
<cx:feed xmlns:cx="http://cxense.com/cxad/api/cxad">
  <cx:name>Test Feed</cx:name>
  <cx:products>
    <cx:productId group="0">0000000000004abc</cx:productId>
    <cx:productId group="1">000000000000123a</cx:productId>
  </cx:products>
  <cx:associableByRoles>
    <cx:role>FULLSERVPUB</cx:role>
    <cx:role>SELFSERVPUB</cx:role>
  </cx:associableByRoles>
</cx:feed>

Example command:

curl -s -H "Content-type: text/xml" -u jsmith123:password1 -X PUT https://cxad.cxense.com/api/secure/feed/0000000000039306 -d @input.xml

DELETE

Delete the Feed with the given feedId

https://{cxadbaseurl}/api/secure/feed/{feedId}

Parameters:

  • cxadbaseurl the base URL of the cX::ad system

  • feedId the id of the Feed to be deleted

Example command:

curl -s -H "Content-type: text/xml" -u jsmith123:password1 -X DELETE https://cxad.cxense.com/api/secure/feed/0000000000039306


Last updated: