Skip to Content

TwentyThree™ API

API Method: /api/action/get

List all calls-to-action for an object.

A list can be retrieved either for a video using a combinatin of photo_id/token or for any relevant object using object_id. The first method doesn't require special signing or permissions, whereas the seconds requires write permissions.

Parameters

ParameterDescription
photo_id The ID of the video to fetch call-to-action for.
token The corresponding token for the photo_id.
The token may be explicitly time-limited in which case expire becomes a required parameter.
object_id The ID of the object to fetch call-to-action for. Using `object_id` requires `write` permissions.
action_id The ID of the action to be lookedd up. Using `action_id` requires `write` permissions.
player_id When retrieving a list from a player, specify the playback context by sending along a `player_id`.
exclude_items_p Boolean to specify whether excluded/disabled actions should be omitted from the result. The default is `1` and this parameter only has effect with `write` permissions and lookups by `object_id`.

Permission level

The minimum required permission level is:

none

For non-public sites, the minimum level is:

anonymous

When looking up non-video objects, the minimun level is:

write

Example XML Response

<response status="ok" permission_level="anonymous" 
  p="1" size="3" total_count="3" cached="1" 
  cache_time="1384295763">
    <action action_id="3526910" name="Test 1" type="ad" 
      start_time="before" exclude_objects="" end_time="after" 
      vast_url="http://yahoo.com/..."/>
    (...)
</response>

Example JSON Response

{
  "status": "ok", 
  "permission_level":"anonymous",
  "cached":"1",
  "cache_time":"1384296443",
  "actions":[
    {"action_id": "3526910", "name": "Test 1", "type": "ad", "start_time": "before", 
    "exclude_objects": "", "end_time": "after", "vast_url": "http://yahoo.com/..."},
    (...)
  ],
  "p": "1",
  "size": "3",
  "total_count": "3",
  "site": {...},
  "endpoint": "/api/action/get"
}