Hosted Items

Overview

The Hosted Items endpoint allows you to retrieve information about the Hosted Items stored in your account.

Note: If you need to upload new Hosted Items into your account, or to replace an existing Hosted Item,  you need to use the Media Upload endpoint.

For more details on the Hosted Items API, please see the Media Upload / Hosted Item API Technical Guide.

GET Method

The Hosted Items endpoint supports the following GET operations. These operations are intended to retrieve information about the Hosted Items stored in your account.

Retrieve All Hosted Item Folders

This endpoint allows you to retrieve a list of your Hosted Item folders. Please note that Hosted Items use a different folder structure than the folders where you save other Messaging assets, like Filters or Campaigns. Hosted Items have their own unique folder structure, and their own unique item type. This endpoint will return only Hosted Item folders, and not regular folders. The response message will include the Hosted Item folder name and Folder ID.

Click hereClick here to see a sample response message in JSON format.

[

  {

    "id": 11437,

    "name": "Web Files"

  },

  {

    "id": 37216,

    "name": "Image Files"

  },

  {

    "id": 46105,

    "name": "Email Content Files"

  }

]

 

 

Retrieve All Hosted Items in a Folder

This endpoint allows you to retrieve a list all the Hosted Items stored within a specified folder. You must provide the Folder ID for the desired folder (you can use the GET method described above to retrieve a list of all the Hosted Item Folder IDs in your account. The response message includes the filename and Object Reference ID for each item in the folder. The response does not include the base64-encoded content of the Hosted Item.

Click hereClick here to see a sample response message in JSON format.

[

  {

    "item_id": 15003,

    "filename": "Koala.jpg",

    "parent_obj_id": 11437,

    "data": ""

  },

  {

    "item_id": 15017,

    "filename": "Chrysanthemum.jpg",

    "parent_obj_id": 11437,

    "data": ""

  },

  {

    "item_id": 15174,

    "filename": "Car-speakers-590x90.swf",

    "parent_obj_id": 11437,

    "data": ""

  },

  {

    "item_id": 15403,

    "filename": "SneakPeak_code.HTML",

    "parent_obj_id": 11437,

    "data": ""

  },

  {

    "item_id": 15525,

    "filename": "silver_christmas_balls-wide.jpg",

    "parent_obj_id": 11437,

    "data": ""

  },

  {

    "item_id": 15569,

    "filename": "images22.jpg",

    "parent_obj_id": 11437,

    "data": ""

  }

]

 

Back to API Category - Data Management