-
Notifications
You must be signed in to change notification settings - Fork 10
/
package.json
156 lines (156 loc) · 4.93 KB
/
package.json
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
{
"name": "test-youtube-api",
"version": "2.0.2",
"description": "Test Youtube API NodeJS module",
"author": "Ionică Bizău <[email protected]> (https://ionicabizau.net)",
"contributors": [
"Ionică Bizău <[email protected]>",
"Fernando Derkoski <[email protected]>"
],
"main": "index.js",
"dependencies": {
"bug-killer": "^4.4.4",
"lien": "^1.0.2",
"opn": "^4.0.1",
"r-json": "^1.2.2",
"request": "^2.36.0",
"try-async": "^1.1.1",
"youtube-api": "^2.0.1"
},
"devDependencies": {},
"scripts": {
"start": "node index"
},
"repository": {
"type": "git",
"url": "https://github.com/IonicaBizau/test-youtube-api.git"
},
"keywords": [
"youtube",
"api",
"node",
"test"
],
"license": "MIT",
"bugs": {
"url": "https://github.com/IonicaBizau/test-youtube-api/issues"
},
"homepage": "https://github.com/IonicaBizau/test-youtube-api",
"blah": {
"title": "YouTube API Test Application",
"description": [
{
"p": "This is an example application how to use the [`youtube-api`](https://github.com/IonicaBizau/youtube-api) library and explore the YouTube API resources."
},
{
"h2": "Before you start"
},
{
"ol": [
"You need a [Google Account](https://www.google.com/accounts/NewAccount) to access the Google APIs Console, request an API key, and register your application.",
"[Register your application](https://console.developers.google.com/project) with Google so that it can submit API requests:",
[
"After registering your application, select **YouTube Data API** as one of the services that your application uses.",
{
"ul": [
"Go to the [APIs Console](https://console.developers.google.com/project) and select the project that you just registered.",
"Click on *APIs & auth* on the left side. Then a dropdown will be opened.",
"Select *APIs*.",
"Search for *YouTube Data API v3*, click it and click <kbd>Enable API</kbd>"
]
}
]
]
}
],
"show_usage": false,
"show_installation": false,
"show_docs": false,
"installation": [
{
"h2": "Installation and usage"
},
{
"ol": [
[
"Download this repository by running:",
{
"code": {
"language": "sh",
"content": "git clone http://github.com/IonicaBizau/test-youtube-api"
}
}
],
[
"Enter in the downloaded directory and run `npm install`:",
{
"code": {
"language": "sh",
"content": [
"cd test-youtube-api",
"npm install"
]
}
}
],
"Go back in your Google app and click again on *APIs & auth* and then select *Credentials*.",
[
"Click <kbd>Create new Client ID</kbd>. This will create new OAuth 2.0 credentials:",
{
"ul": [
"Select *Web application*",
"Click <kbd>Configure consent screen</kbd>",
[
"Complete the required fields:",
{
"ul": [
"Product name: what ever you want (e.g. \"Youtube API Test\")",
"Product logo is optional",
"Home page is optional",
"Save the changes"
]
}
],
[
"Now you will have to set the auth urls. This test application uses the following urls:",
{
"ul": [
"Authorized JavaScript origins: `http://localhost:5000/` (paste it in the first textarea)",
"Authorized redirect URIs: `http://localhost:5000/oauth2callback` (paste it in the second textarea)"
]
}
],
"Finally, click <kbd>Create Client ID</kbd>"
]
}
]
]
},
[
"OK, at this step you have the credentials (in your Google app). Now you have to use them in this test application:",
{
"ol": [
"Rename `credentials.templ.json` into `credentials.json`.",
"Open `credentials.json` and replace `yourClientId` with the **client id** and `yourSecretKey` with **client secret** generated previously.",
"Now you are ready. Start the script (`npm start`) and open `http://localhost:5000`."
]
}
]
]
},
"files": [
"bin/",
"app/",
"lib/",
"dist/",
"src/",
"scripts/",
"resources/",
"menu/",
"cli.js",
"index.js",
"bloggify.js",
"bloggify.json",
"bloggify/"
]
}