How to get your YouTube API credentials – cloud console

In order to allow your platform users to publish their videos on YouTube, you need to get YouTube API credentials.

Important: the Admin needs to create two different sets of credentials:

OAuth 2.0 Client ID

API key

 

The first step in getting the YouTube API credentials is creating the API for your application into your Google account. You can do that, clicking on the following link: http://code.google.com/apis/console/.

After you log into your Goggle account, start creating a new project:

00-projects

1. Click here to create a new API Project

 

On Google API Projects page, you have the possibility to add a new project or edit an existing one:

01-create-new-project

1. Enter here the name of the project

2. Click here to edit the project ID

3. Click here to save the project

 

After the project is created you will see it on the list of projects from your account:

02-projects-list

To get the API of the project, click on project name.

 

You will land on the Overview page, from here you will have to enable the YouTube Data API, as shown on the following image:

003-enable-api

 

On the page that opens you will have to click on Enable button in order to enable the YouTube Data API, as shown on the following image:

004-enable-api

 

After that you will have to navigate to Credentials tab:

03-api-management

 

From the Credentials page click on Create credentials button and select the QAuth client ID option:

04-create-new-credential

1. Click here to select the API credential type

2. Click here to create an QAuth client ID

 

Then you will have to create a Web application:

05-create-client-id

 

To create an OAuth client ID, you must first set a product name on the consent screen:

06-configure-consent-screen

 

Click on Configure consent screen button:

07-configure-consent-screen

1. Enter here the name of the product – this is the name that will be shown to users

2. Enter the homepage URL – this is the URL of your website

3. Enter here the URL of your product logo (this is optional)

4. Click here to save the QAth consent screen

 

Once you created the consent screen, you will be able to set the application type:

08-create-client-id

1. Insert here the name of the web client

2. Enter here the callback URL – the one that our team provided you on the ticket system

3. Click here to create the Client ID

Example of redirect URLs:

  • http://yoursite.com/services/youtube/oauth2callback.php
  • http://testarea.yoursite.com/services/youtube/oauth2callback.php

where “yoursite.com” with your site domain name

 

Once the client ID is created you can view the QAuth client ID and secret:

09-OAuth-client-id

1. Here you can view the client ID

2. Here you can see the client secret ID

3. Click here to close the overlay window

 

After you created the QAuth key, you need to create an API key:

10-create-api-key

1. Click here to select the API credential type

2. Click here to create an API key

 

 

The next step is to select the Server key:

11-select-api-key

 

An overlay window will be displayed and you can view the API key:

12-api-key

 

Copy the codes from the API access page into your website Site Settings page:

upload videos to youtube

1. Paste here client ID code

2. Paste here secret client ID code

3. Paste here developer API key

4. Click here to save the settings

 

Once these settings done, users will be able to upload videos to YouTube directly from their user dashboard account.