Collect video ids

You can use the Platform API to easily collect video IDs in order to embed your content on your properties.

In this article, you'll learn the different privacy settings available in our Platform API, and how to easily collect the right content ID for the embed.


Understand content privacy

Depending on the privacy set on the content, the embed code will require a specific content id:

  • Public or password protected content - You must use the id field to embed your content.
  • Private content - You must use the private_id field to embed your content.

If you want to get more information about the content privacy options, please read our video privacy guide.

⚠️

Collect private_id:

When a content privacy is set on private=true, the private_id is not accessible publicly and requires API authentication. Only Organization members with proper access will be able to retrieve it.


Collect video ID

We suggest you to always request the following fields when collecting video IDs to make sure you always have all the necessary information, no matter the embed method used (direct integration, CMS...):

  • title - Allows you to easily identify the content you would like to migrate.
  • id - The unique video identifier.
  • private_id - The ID allowing a user to access to a private content (set to null if the content is public).

Request exemples:

### List all video IDs of a specific user 

https://api.dailymotion.com/user/USERNAME/videos?fields=title,id,private_id
### List all video IDs of a specific user 

https://partner.api.dailymotion.com/user/USERNAME/videos?fields=title,id,private_id
### List all video IDs of a specific playlist

https://api.dailymotion.com/playlist/x7q1er/videos?fields=title,id,private_id
### List all video IDs of a specific playlist

https://partner.api.dailymotion.com/playlist/x7q1er/videos?fields=title,id,private_id
### List all video IDs of a specific video

https://api.dailymotion.com/video/x84sh87?fields=title,id,private_id
### List all video IDs of a specific video

https://partner.api.dailymotion.com/video/x84sh87?fields=title,id,private_id

Response example:

{
"title": "CEO interview",
"id": "x123456",
"private_id": "k12345654321",
"private": true,
},

{
"title": "Christmas hackathon",
"id": "x1y2z3b",
"private_id": null,
"private": false,
},

Embed your content

You should now have all the necessary elements to proceed with the integration.

We invite you to continue with our dedicated embed method guides to learn how to pick the best integration method and start your step-by-step integration: