tmdb-ts 0.1.8 → 0.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/api.d.ts +1 -1
- package/dist/api.js +5 -3
- package/dist/api.js.map +1 -1
- package/dist/endpoints/account.d.ts +2 -1
- package/dist/endpoints/account.js.map +1 -1
- package/dist/endpoints/certification.js.map +1 -1
- package/dist/endpoints/changes.js +3 -7
- package/dist/endpoints/changes.js.map +1 -1
- package/dist/endpoints/collections.js +3 -7
- package/dist/endpoints/collections.js.map +1 -1
- package/dist/endpoints/configuration.js.map +1 -1
- package/dist/endpoints/credits.js.map +1 -1
- package/dist/endpoints/discover.js +2 -5
- package/dist/endpoints/discover.js.map +1 -1
- package/dist/endpoints/find.js +1 -3
- package/dist/endpoints/find.js.map +1 -1
- package/dist/endpoints/genre.js.map +1 -1
- package/dist/endpoints/index.js.map +1 -1
- package/dist/endpoints/keywords.js +1 -3
- package/dist/endpoints/keywords.js.map +1 -1
- package/dist/endpoints/movies.js +9 -19
- package/dist/endpoints/movies.js.map +1 -1
- package/dist/endpoints/people.js +3 -7
- package/dist/endpoints/people.js.map +1 -1
- package/dist/endpoints/search.js +6 -13
- package/dist/endpoints/search.js.map +1 -1
- package/dist/endpoints/trending.js.map +1 -1
- package/dist/endpoints/tv-shows.d.ts +3 -3
- package/dist/endpoints/tv-shows.js +10 -18
- package/dist/endpoints/tv-shows.js.map +1 -1
- package/dist/types/account.d.ts +15 -0
- package/dist/types/account.js +3 -0
- package/dist/types/account.js.map +1 -0
- package/dist/types/index.d.ts +2 -2
- package/dist/types/index.js.map +1 -1
- package/dist/types/movies.d.ts +13 -7
- package/dist/types/movies.js.map +1 -1
- package/dist/types/tv-shows.d.ts +22 -8
- package/dist/utils/getImagePath.js.map +1 -1
- package/dist/utils/parseOptions.d.ts +1 -3
- package/dist/utils/parseOptions.js +2 -3
- package/dist/utils/parseOptions.js.map +1 -1
- package/package.json +17 -8
package/dist/api.d.ts
CHANGED
package/dist/api.js
CHANGED
|
@@ -4,21 +4,23 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
4
4
|
};
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
const cross_fetch_1 = __importDefault(require("cross-fetch"));
|
|
7
|
+
const utils_1 = require("./utils");
|
|
7
8
|
const BASE_URL_V3 = 'https://api.themoviedb.org/3';
|
|
8
9
|
class Api {
|
|
9
10
|
constructor(accessToken) {
|
|
10
11
|
this.accessToken = accessToken;
|
|
11
12
|
this.accessToken = accessToken;
|
|
12
13
|
}
|
|
13
|
-
async get(path) {
|
|
14
|
-
const
|
|
14
|
+
async get(path, options) {
|
|
15
|
+
const params = (0, utils_1.parseOptions)(options);
|
|
16
|
+
const response = await (0, cross_fetch_1.default)(`${BASE_URL_V3}${path}?${params}`, {
|
|
15
17
|
method: 'GET',
|
|
16
18
|
headers: {
|
|
17
19
|
Authorization: `Bearer ${this.accessToken}`,
|
|
18
20
|
'Content-Type': 'application/json;charset=utf-8',
|
|
19
21
|
},
|
|
20
22
|
});
|
|
21
|
-
return await response.json();
|
|
23
|
+
return (await response.json());
|
|
22
24
|
}
|
|
23
25
|
}
|
|
24
26
|
exports.default = Api;
|
package/dist/api.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"api.js","sourceRoot":"","sources":["../src/api.ts"],"names":[],"mappings":";;;;;AAAA,8DAAgC;
|
|
1
|
+
{"version":3,"file":"api.js","sourceRoot":"","sources":["../src/api.ts"],"names":[],"mappings":";;;;;AAAA,8DAAgC;AAChC,mCAAuC;AAEvC,MAAM,WAAW,GAAG,8BAA8B,CAAC;AAEnD,MAAqB,GAAG;IACtB,YAAoB,WAAmB;QAAnB,gBAAW,GAAX,WAAW,CAAQ;QACrC,IAAI,CAAC,WAAW,GAAG,WAAW,CAAC;IACjC,CAAC;IAED,KAAK,CAAC,GAAG,CAAI,IAAY,EAAE,OAA6B;QACtD,MAAM,MAAM,GAAG,IAAA,oBAAY,EAAC,OAAO,CAAC,CAAC;QACrC,MAAM,QAAQ,GAAG,MAAM,IAAA,qBAAK,EAAC,GAAG,WAAW,GAAG,IAAI,IAAI,MAAM,EAAE,EAAE;YAC9D,MAAM,EAAE,KAAK;YACb,OAAO,EAAE;gBACP,aAAa,EAAE,UAAU,IAAI,CAAC,WAAW,EAAE;gBAC3C,cAAc,EAAE,gCAAgC;aACjD;SACF,CAAC,CAAC;QACH,OAAO,CAAC,MAAM,QAAQ,CAAC,IAAI,EAAE,CAAM,CAAC;IACtC,CAAC;CACF;AAhBD,sBAgBC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"account.js","sourceRoot":"","sources":["../../src/endpoints/account.ts"],"names":[],"mappings":";;;AAAA,iCAAsC;
|
|
1
|
+
{"version":3,"file":"account.js","sourceRoot":"","sources":["../../src/endpoints/account.ts"],"names":[],"mappings":";;;AAAA,iCAAsC;AAGtC,MAAa,eAAgB,SAAQ,mBAAY;IAC/C,YAAY,WAAmB;QAC7B,KAAK,CAAC,WAAW,CAAC,CAAC;IACrB,CAAC;IAED,KAAK,CAAC,OAAO;QACX,OAAO,MAAM,IAAI,CAAC,GAAG,CAAC,GAAG,CAAC,UAAU,CAAC,CAAC;IACxC,CAAC;CACF;AARD,0CAQC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"certification.js","sourceRoot":"","sources":["../../src/endpoints/certification.ts"],"names":[],"mappings":";;;AAAA,
|
|
1
|
+
{"version":3,"file":"certification.js","sourceRoot":"","sources":["../../src/endpoints/certification.ts"],"names":[],"mappings":";;;AAAA,iCAAsC;AAGtC,MAAa,qBAAsB,SAAQ,mBAAY;IACrD,YAA+B,WAAmB;QAChD,KAAK,CAAC,WAAW,CAAC,CAAC;QADU,gBAAW,GAAX,WAAW,CAAQ;IAElD,CAAC;IAED,KAAK,CAAC,MAAM;QACV,OAAO,MAAM,IAAI,CAAC,GAAG,CAAC,GAAG,CAAiB,2BAA2B,CAAC,CAAC;IACzE,CAAC;IAED,KAAK,CAAC,OAAO;QACX,OAAO,MAAM,IAAI,CAAC,GAAG,CAAC,GAAG,CAAiB,wBAAwB,CAAC,CAAC;IACtE,CAAC;CACF;AAZD,sDAYC"}
|
|
@@ -2,23 +2,19 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.ChangeEndpoint = void 0;
|
|
4
4
|
const base_1 = require("./base");
|
|
5
|
-
const utils_1 = require("../utils");
|
|
6
5
|
class ChangeEndpoint extends base_1.BaseEndpoint {
|
|
7
6
|
constructor(accessToken) {
|
|
8
7
|
super(accessToken);
|
|
9
8
|
this.accessToken = accessToken;
|
|
10
9
|
}
|
|
11
10
|
async movies(options) {
|
|
12
|
-
|
|
13
|
-
return await this.api.get(`/movie/changes?${params}`);
|
|
11
|
+
return await this.api.get(`/movie/changes`, options);
|
|
14
12
|
}
|
|
15
13
|
async tvShows(options) {
|
|
16
|
-
|
|
17
|
-
return await this.api.get(`/tv/changes?${params}`);
|
|
14
|
+
return await this.api.get(`/tv/changes`, options);
|
|
18
15
|
}
|
|
19
16
|
async person(options) {
|
|
20
|
-
|
|
21
|
-
return await this.api.get(`/person/changes${params}`);
|
|
17
|
+
return await this.api.get(`/person/change`, options);
|
|
22
18
|
}
|
|
23
19
|
}
|
|
24
20
|
exports.ChangeEndpoint = ChangeEndpoint;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"changes.js","sourceRoot":"","sources":["../../src/endpoints/changes.ts"],"names":[],"mappings":";;;AAAA,iCAAsC;
|
|
1
|
+
{"version":3,"file":"changes.js","sourceRoot":"","sources":["../../src/endpoints/changes.ts"],"names":[],"mappings":";;;AAAA,iCAAsC;AAGtC,MAAa,cAAe,SAAQ,mBAAY;IAC9C,YAA+B,WAAmB;QAChD,KAAK,CAAC,WAAW,CAAC,CAAC;QADU,gBAAW,GAAX,WAAW,CAAQ;IAElD,CAAC;IAED,KAAK,CAAC,MAAM,CAAC,OAAuB;QAClC,OAAO,MAAM,IAAI,CAAC,GAAG,CAAC,GAAG,CAAU,gBAAgB,EAAE,OAAO,CAAC,CAAC;IAChE,CAAC;IAED,KAAK,CAAC,OAAO,CAAC,OAAuB;QACnC,OAAO,MAAM,IAAI,CAAC,GAAG,CAAC,GAAG,CAAU,aAAa,EAAE,OAAO,CAAC,CAAC;IAC7D,CAAC;IAED,KAAK,CAAC,MAAM,CAAC,OAAuB;QAClC,OAAO,MAAM,IAAI,CAAC,GAAG,CAAC,GAAG,CAAU,gBAAgB,EAAE,OAAO,CAAC,CAAC;IAChE,CAAC;CACF;AAhBD,wCAgBC"}
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.CollectionsEndpoint = void 0;
|
|
4
|
-
const utils_1 = require("../utils");
|
|
5
4
|
const base_1 = require("./base");
|
|
6
5
|
const BASE_COLLECTION = '/collection';
|
|
7
6
|
class CollectionsEndpoint extends base_1.BaseEndpoint {
|
|
@@ -10,16 +9,13 @@ class CollectionsEndpoint extends base_1.BaseEndpoint {
|
|
|
10
9
|
this.accessToken = accessToken;
|
|
11
10
|
}
|
|
12
11
|
async details(id, options) {
|
|
13
|
-
|
|
14
|
-
return await this.api.get(`${BASE_COLLECTION}/${id}?${params}`);
|
|
12
|
+
return await this.api.get(`${BASE_COLLECTION}/${id}`, options);
|
|
15
13
|
}
|
|
16
14
|
async images(id, options) {
|
|
17
|
-
|
|
18
|
-
return await this.api.get(`${BASE_COLLECTION}/${id}/images?${params}`);
|
|
15
|
+
return await this.api.get(`${BASE_COLLECTION}/${id}/images`, options);
|
|
19
16
|
}
|
|
20
17
|
async translations(id, options) {
|
|
21
|
-
|
|
22
|
-
return await this.api.get(`${BASE_COLLECTION}/${id}/translations?${params}`);
|
|
18
|
+
return await this.api.get(`${BASE_COLLECTION}/${id}/translations`, options);
|
|
23
19
|
}
|
|
24
20
|
}
|
|
25
21
|
exports.CollectionsEndpoint = CollectionsEndpoint;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"collections.js","sourceRoot":"","sources":["../../src/endpoints/collections.ts"],"names":[],"mappings":";;;
|
|
1
|
+
{"version":3,"file":"collections.js","sourceRoot":"","sources":["../../src/endpoints/collections.ts"],"names":[],"mappings":";;;AAMA,iCAAsC;AAEtC,MAAM,eAAe,GAAG,aAAa,CAAC;AAEtC,MAAa,mBAAoB,SAAQ,mBAAY;IACnD,YAA+B,WAAmB;QAChD,KAAK,CAAC,WAAW,CAAC,CAAC;QADU,gBAAW,GAAX,WAAW,CAAQ;IAElD,CAAC;IAED,KAAK,CAAC,OAAO,CACX,EAAU,EACV,OAAwB;QAExB,OAAO,MAAM,IAAI,CAAC,GAAG,CAAC,GAAG,CACvB,GAAG,eAAe,IAAI,EAAE,EAAE,EAC1B,OAAO,CACR,CAAC;IACJ,CAAC;IAED,KAAK,CAAC,MAAM,CAAC,EAAU,EAAE,OAAwB;QAC/C,OAAO,MAAM,IAAI,CAAC,GAAG,CAAC,GAAG,CACvB,GAAG,eAAe,IAAI,EAAE,SAAS,EACjC,OAAO,CACR,CAAC;IACJ,CAAC;IAED,KAAK,CAAC,YAAY,CAChB,EAAU,EACV,OAAwB;QAExB,OAAO,MAAM,IAAI,CAAC,GAAG,CAAC,GAAG,CACvB,GAAG,eAAe,IAAI,EAAE,eAAe,EACvC,OAAO,CACR,CAAC;IACJ,CAAC;CACF;AA/BD,kDA+BC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"configuration.js","sourceRoot":"","sources":["../../src/endpoints/configuration.ts"],"names":[],"mappings":";;;AAAA,iCAAsC;AAGtC,MAAa,qBAAsB,SAAQ,mBAAY;IACrD,YAA+B,WAAmB;QAChD,KAAK,CAAC,WAAW,CAAC,CAAC;QADU,gBAAW,GAAX,WAAW,CAAQ;IAElD,CAAC;IAED,KAAK,CAAC,UAAU;QACd,OAAO,MAAM,IAAI,CAAC,GAAG,CAAC,GAAG,CAAgB,gBAAgB,CAAC,CAAC;IAC7D,CAAC;
|
|
1
|
+
{"version":3,"file":"configuration.js","sourceRoot":"","sources":["../../src/endpoints/configuration.ts"],"names":[],"mappings":";;;AAAA,iCAAsC;AAGtC,MAAa,qBAAsB,SAAQ,mBAAY;IACrD,YAA+B,WAAmB;QAChD,KAAK,CAAC,WAAW,CAAC,CAAC;QADU,gBAAW,GAAX,WAAW,CAAQ;IAElD,CAAC;IAED,KAAK,CAAC,UAAU;QACd,OAAO,MAAM,IAAI,CAAC,GAAG,CAAC,GAAG,CAAgB,gBAAgB,CAAC,CAAC;IAC7D,CAAC;CACF;AARD,sDAQC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"credits.js","sourceRoot":"","sources":["../../src/endpoints/credits.ts"],"names":[],"mappings":";;;AAAA,iCAAsC;
|
|
1
|
+
{"version":3,"file":"credits.js","sourceRoot":"","sources":["../../src/endpoints/credits.ts"],"names":[],"mappings":";;;AAAA,iCAAsC;AAGtC,MAAa,eAAgB,SAAQ,mBAAY;IAC/C,YAA+B,WAAmB;QAChD,KAAK,CAAC,WAAW,CAAC,CAAC;QADU,gBAAW,GAAX,WAAW,CAAQ;IAElD,CAAC;IAED,KAAK,CAAC,OAAO,CAAC,EAAU;QACtB,OAAO,MAAM,IAAI,CAAC,GAAG,CAAC,GAAG,CAAiB,WAAW,EAAE,EAAE,CAAC,CAAC;IAC7D,CAAC;CACF;AARD,0CAQC"}
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.DiscoverEndpoint = void 0;
|
|
4
|
-
const utils_1 = require("../utils");
|
|
5
4
|
const base_1 = require("./base");
|
|
6
5
|
const BASE_DISCOVER = '/discover';
|
|
7
6
|
class DiscoverEndpoint extends base_1.BaseEndpoint {
|
|
@@ -9,12 +8,10 @@ class DiscoverEndpoint extends base_1.BaseEndpoint {
|
|
|
9
8
|
super(accessToken);
|
|
10
9
|
}
|
|
11
10
|
async movie(options) {
|
|
12
|
-
|
|
13
|
-
return await this.api.get(`${BASE_DISCOVER}/movie?${params}`);
|
|
11
|
+
return await this.api.get(`${BASE_DISCOVER}/movie`, options);
|
|
14
12
|
}
|
|
15
13
|
async tvShow(options) {
|
|
16
|
-
|
|
17
|
-
return await this.api.get(`${BASE_DISCOVER}/tv?${params}`);
|
|
14
|
+
return await this.api.get(`${BASE_DISCOVER}/tv`, options);
|
|
18
15
|
}
|
|
19
16
|
}
|
|
20
17
|
exports.DiscoverEndpoint = DiscoverEndpoint;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"discover.js","sourceRoot":"","sources":["../../src/endpoints/discover.ts"],"names":[],"mappings":";;;
|
|
1
|
+
{"version":3,"file":"discover.js","sourceRoot":"","sources":["../../src/endpoints/discover.ts"],"names":[],"mappings":";;;AAKA,iCAAsC;AAEtC,MAAM,aAAa,GAAG,WAAW,CAAC;AA0DlC,MAAa,gBAAiB,SAAQ,mBAAY;IAChD,YAAY,WAAmB;QAC7B,KAAK,CAAC,WAAW,CAAC,CAAC;IACrB,CAAC;IAED,KAAK,CAAC,KAAK,CAAC,OAA2B;QACrC,OAAO,MAAM,IAAI,CAAC,GAAG,CAAC,GAAG,CACvB,GAAG,aAAa,QAAQ,EACxB,OAAO,CACR,CAAC;IACJ,CAAC;IAED,KAAK,CAAC,MAAM,CAAC,OAA4B;QACvC,OAAO,MAAM,IAAI,CAAC,GAAG,CAAC,GAAG,CACvB,GAAG,aAAa,KAAK,EACrB,OAAO,CACR,CAAC;IACJ,CAAC;CACF;AAlBD,4CAkBC"}
|
package/dist/endpoints/find.js
CHANGED
|
@@ -2,14 +2,12 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.FindEndpoint = void 0;
|
|
4
4
|
const base_1 = require("./base");
|
|
5
|
-
const utils_1 = require("../utils");
|
|
6
5
|
class FindEndpoint extends base_1.BaseEndpoint {
|
|
7
6
|
constructor(accessToken) {
|
|
8
7
|
super(accessToken);
|
|
9
8
|
}
|
|
10
9
|
async byId(externalId, options) {
|
|
11
|
-
|
|
12
|
-
return await this.api.get(`/find/${externalId}?${params}`);
|
|
10
|
+
return await this.api.get(`/find/${externalId}`, options);
|
|
13
11
|
}
|
|
14
12
|
}
|
|
15
13
|
exports.FindEndpoint = FindEndpoint;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"find.js","sourceRoot":"","sources":["../../src/endpoints/find.ts"],"names":[],"mappings":";;;AAAA,iCAAsC;
|
|
1
|
+
{"version":3,"file":"find.js","sourceRoot":"","sources":["../../src/endpoints/find.ts"],"names":[],"mappings":";;;AAAA,iCAAsC;AAGtC,MAAa,YAAa,SAAQ,mBAAY;IAC5C,YAAY,WAAmB;QAC7B,KAAK,CAAC,WAAW,CAAC,CAAC;IACrB,CAAC;IAED,KAAK,CAAC,IAAI,CACR,UAAkB,EAClB,OAA0B;QAE1B,OAAO,MAAM,IAAI,CAAC,GAAG,CAAC,GAAG,CAAa,SAAS,UAAU,EAAE,EAAE,OAAO,CAAC,CAAC;IACxE,CAAC;CACF;AAXD,oCAWC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"genre.js","sourceRoot":"","sources":["../../src/endpoints/genre.ts"],"names":[],"mappings":";;;AAAA,
|
|
1
|
+
{"version":3,"file":"genre.js","sourceRoot":"","sources":["../../src/endpoints/genre.ts"],"names":[],"mappings":";;;AAAA,iCAAsC;AAMtC,MAAa,aAAc,SAAQ,mBAAY;IAC7C,YAA+B,WAAmB;QAChD,KAAK,CAAC,WAAW,CAAC,CAAC;QADU,gBAAW,GAAX,WAAW,CAAQ;IAElD,CAAC;IAED,KAAK,CAAC,MAAM;QACV,OAAO,MAAM,IAAI,CAAC,GAAG,CAAC,GAAG,CAAS,mBAAmB,CAAC,CAAC;IACzD,CAAC;IAED,KAAK,CAAC,OAAO;QACX,OAAO,MAAM,IAAI,CAAC,GAAG,CAAC,GAAG,CAAS,gBAAgB,CAAC,CAAC;IACtD,CAAC;CACF;AAZD,sCAYC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/endpoints/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/endpoints/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,4CAA0B;AAC1B,kDAAgC;AAChC,4CAA0B;AAC1B,4CAA0B;AAC1B,2CAAyB;AACzB,0CAAwB;AACxB,2CAAyB;AACzB,kDAAgC;AAChC,6CAA2B;AAC3B,6CAA2B;AAC3B,2CAAyB;AACzB,2CAAyB;AACzB,6CAA2B;AAC3B,yCAAuB;AACvB,6CAA2B;AAC3B,gDAA8B"}
|
|
@@ -2,7 +2,6 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.KeywordsEndpoint = void 0;
|
|
4
4
|
const base_1 = require("./base");
|
|
5
|
-
const utils_1 = require("../utils");
|
|
6
5
|
const BASE_Keyword = '/keyword';
|
|
7
6
|
class KeywordsEndpoint extends base_1.BaseEndpoint {
|
|
8
7
|
constructor(accessToken) {
|
|
@@ -12,8 +11,7 @@ class KeywordsEndpoint extends base_1.BaseEndpoint {
|
|
|
12
11
|
return await this.api.get(`${BASE_Keyword}/${keywordId}`);
|
|
13
12
|
}
|
|
14
13
|
async belongingMovies(keywordId, options) {
|
|
15
|
-
|
|
16
|
-
return await this.api.get(`${BASE_Keyword}/${keywordId}/movies?${params}`);
|
|
14
|
+
return await this.api.get(`${BASE_Keyword}/${keywordId}/movies`, options);
|
|
17
15
|
}
|
|
18
16
|
}
|
|
19
17
|
exports.KeywordsEndpoint = KeywordsEndpoint;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"keywords.js","sourceRoot":"","sources":["../../src/endpoints/keywords.ts"],"names":[],"mappings":";;;AAAA,iCAAsC;
|
|
1
|
+
{"version":3,"file":"keywords.js","sourceRoot":"","sources":["../../src/endpoints/keywords.ts"],"names":[],"mappings":";;;AAAA,iCAAsC;AAGtC,MAAM,YAAY,GAAG,UAAU,CAAC;AAEhC,MAAa,gBAAiB,SAAQ,mBAAY;IAChD,YAAY,WAAmB;QAC7B,KAAK,CAAC,WAAW,CAAC,CAAC;IACrB,CAAC;IAED,KAAK,CAAC,OAAO,CAAC,SAAiB;QAC7B,OAAO,MAAM,IAAI,CAAC,GAAG,CAAC,GAAG,CAAU,GAAG,YAAY,IAAI,SAAS,EAAE,CAAC,CAAC;IACrE,CAAC;IAED,KAAK,CAAC,eAAe,CACnB,SAAiB,EACjB,OAAyB;QAEzB,OAAO,MAAM,IAAI,CAAC,GAAG,CAAC,GAAG,CACvB,GAAG,YAAY,IAAI,SAAS,SAAS,EACrC,OAAO,CACR,CAAC;IACJ,CAAC;CACF;AAlBD,4CAkBC"}
|
package/dist/endpoints/movies.js
CHANGED
|
@@ -2,7 +2,6 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.MoviesEndpoint = void 0;
|
|
4
4
|
const base_1 = require("./base");
|
|
5
|
-
const utils_1 = require("../utils");
|
|
6
5
|
const BASE_MOVIE = '/movie';
|
|
7
6
|
class MoviesEndpoint extends base_1.BaseEndpoint {
|
|
8
7
|
constructor(accessToken) {
|
|
@@ -16,8 +15,7 @@ class MoviesEndpoint extends base_1.BaseEndpoint {
|
|
|
16
15
|
return await this.api.get(`${BASE_MOVIE}/${id}/alternative_titles`);
|
|
17
16
|
}
|
|
18
17
|
async changes(id, options) {
|
|
19
|
-
|
|
20
|
-
return await this.api.get(`${BASE_MOVIE}/${id}/changes?${params}`);
|
|
18
|
+
return await this.api.get(`${BASE_MOVIE}/${id}/changes`, options);
|
|
21
19
|
}
|
|
22
20
|
async credits(id) {
|
|
23
21
|
return await this.api.get(`${BASE_MOVIE}/${id}/credits`);
|
|
@@ -32,23 +30,19 @@ class MoviesEndpoint extends base_1.BaseEndpoint {
|
|
|
32
30
|
return await this.api.get(`${BASE_MOVIE}/${id}/keywords`);
|
|
33
31
|
}
|
|
34
32
|
async lists(id, options) {
|
|
35
|
-
|
|
36
|
-
return await this.api.get(`${BASE_MOVIE}/${id}/lists?${params}`);
|
|
33
|
+
return await this.api.get(`${BASE_MOVIE}/${id}/lists`, options);
|
|
37
34
|
}
|
|
38
35
|
async recommendations(id, options) {
|
|
39
|
-
|
|
40
|
-
return await this.api.get(`${BASE_MOVIE}/${id}/recommendations?${params}`);
|
|
36
|
+
return await this.api.get(`${BASE_MOVIE}/${id}/recommendations`, options);
|
|
41
37
|
}
|
|
42
38
|
async releaseDates(id) {
|
|
43
39
|
return await this.api.get(`${BASE_MOVIE}/${id}/release_dates`);
|
|
44
40
|
}
|
|
45
41
|
async reviews(id, options) {
|
|
46
|
-
|
|
47
|
-
return await this.api.get(`${BASE_MOVIE}/${id}/reviews?${params}`);
|
|
42
|
+
return await this.api.get(`${BASE_MOVIE}/${id}/reviews`, options);
|
|
48
43
|
}
|
|
49
44
|
async similar(id, options) {
|
|
50
|
-
|
|
51
|
-
return await this.api.get(`${BASE_MOVIE}/${id}/similar?${params}`);
|
|
45
|
+
return await this.api.get(`${BASE_MOVIE}/${id}/similar`, options);
|
|
52
46
|
}
|
|
53
47
|
async translations(id) {
|
|
54
48
|
return await this.api.get(`${BASE_MOVIE}/${id}/translations`);
|
|
@@ -67,20 +61,16 @@ class MoviesEndpoint extends base_1.BaseEndpoint {
|
|
|
67
61
|
return await this.api.get(`${BASE_MOVIE}/latest`);
|
|
68
62
|
}
|
|
69
63
|
async nowPlaying(options) {
|
|
70
|
-
|
|
71
|
-
return await this.api.get(`${BASE_MOVIE}/now_playing?${params}`);
|
|
64
|
+
return await this.api.get(`${BASE_MOVIE}/now_playing`, options);
|
|
72
65
|
}
|
|
73
66
|
async popular(options) {
|
|
74
|
-
|
|
75
|
-
return await this.api.get(`${BASE_MOVIE}/popular?${params}`);
|
|
67
|
+
return await this.api.get(`${BASE_MOVIE}/popular`, options);
|
|
76
68
|
}
|
|
77
69
|
async topRated(options) {
|
|
78
|
-
|
|
79
|
-
return await this.api.get(`${BASE_MOVIE}/top_rated?${params}`);
|
|
70
|
+
return await this.api.get(`${BASE_MOVIE}/top_rated`, options);
|
|
80
71
|
}
|
|
81
72
|
async upcoming(options) {
|
|
82
|
-
|
|
83
|
-
return await this.api.get(`${BASE_MOVIE}/upcoming?${params}`);
|
|
73
|
+
return await this.api.get(`${BASE_MOVIE}/upcoming`, options);
|
|
84
74
|
}
|
|
85
75
|
}
|
|
86
76
|
exports.MoviesEndpoint = MoviesEndpoint;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"movies.js","sourceRoot":"","sources":["../../src/endpoints/movies.ts"],"names":[],"mappings":";;;AAAA,iCAAsC;
|
|
1
|
+
{"version":3,"file":"movies.js","sourceRoot":"","sources":["../../src/endpoints/movies.ts"],"names":[],"mappings":";;;AAAA,iCAAsC;AA4BtC,MAAM,UAAU,GAAG,QAAQ,CAAC;AAE5B,MAAa,cAAe,SAAQ,mBAAY;IAC9C,YAA+B,WAAmB;QAChD,KAAK,CAAC,WAAW,CAAC,CAAC;QADU,gBAAW,GAAX,WAAW,CAAQ;IAElD,CAAC;IAED,KAAK,CAAC,OAAO,CAAC,EAAU;QACtB,OAAO,MAAM,IAAI,CAAC,GAAG,CAAC,GAAG,CAAe,GAAG,UAAU,IAAI,EAAE,EAAE,CAAC,CAAC;IACjE,CAAC;IAED,KAAK,CAAC,iBAAiB,CAAC,EAAU;QAChC,OAAO,MAAM,IAAI,CAAC,GAAG,CAAC,GAAG,CACvB,GAAG,UAAU,IAAI,EAAE,qBAAqB,CACzC,CAAC;IACJ,CAAC;IAED,KAAK,CAAC,OAAO,CAAC,EAAU,EAAE,OAAuB;QA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,CACvB,GAAG,UAAU,YAAY,EACzB,OAAO,CACR,CAAC;IACJ,CAAC;IAED,KAAK,CAAC,QAAQ,CACZ,OAAoD;QAEpD,OAAO,MAAM,IAAI,CAAC,GAAG,CAAC,GAAG,CACvB,GAAG,UAAU,WAAW,EACxB,OAAO,CACR,CAAC;IACJ,CAAC;CACF;AA5HD,wCA4HC"}
|
package/dist/endpoints/people.js
CHANGED
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.PeopleEndpoint = void 0;
|
|
4
|
-
const utils_1 = require("../utils");
|
|
5
4
|
const base_1 = require("./base");
|
|
6
5
|
const BASE_PERSON = '/person';
|
|
7
6
|
class PeopleEndpoint extends base_1.BaseEndpoint {
|
|
@@ -12,8 +11,7 @@ class PeopleEndpoint extends base_1.BaseEndpoint {
|
|
|
12
11
|
return await this.api.get(`${BASE_PERSON}/${id}`);
|
|
13
12
|
}
|
|
14
13
|
async changes(id, options) {
|
|
15
|
-
|
|
16
|
-
return await this.api.get(`${BASE_PERSON}/${id}/changes?${params}`);
|
|
14
|
+
return await this.api.get(`${BASE_PERSON}/${id}/changes`, options);
|
|
17
15
|
}
|
|
18
16
|
async movieCredits(id) {
|
|
19
17
|
return await this.api.get(`${BASE_PERSON}/${id}/movie_credits`);
|
|
@@ -31,8 +29,7 @@ class PeopleEndpoint extends base_1.BaseEndpoint {
|
|
|
31
29
|
return await this.api.get(`${BASE_PERSON}/${id}/images`);
|
|
32
30
|
}
|
|
33
31
|
async taggedImages(id, options) {
|
|
34
|
-
|
|
35
|
-
return await this.api.get(`${BASE_PERSON}/${id}/tagged_images?${params}`);
|
|
32
|
+
return await this.api.get(`${BASE_PERSON}/${id}/tagged_images`, options);
|
|
36
33
|
}
|
|
37
34
|
async translation(id) {
|
|
38
35
|
return await this.api.get(`${BASE_PERSON}/${id}/translations`);
|
|
@@ -41,8 +38,7 @@ class PeopleEndpoint extends base_1.BaseEndpoint {
|
|
|
41
38
|
return await this.api.get(`${BASE_PERSON}/latest`);
|
|
42
39
|
}
|
|
43
40
|
async popular(options) {
|
|
44
|
-
|
|
45
|
-
return await this.api.get(`${BASE_PERSON}/popular?${params}`);
|
|
41
|
+
return await this.api.get(`${BASE_PERSON}/popular`, options);
|
|
46
42
|
}
|
|
47
43
|
}
|
|
48
44
|
exports.PeopleEndpoint = PeopleEndpoint;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"people.js","sourceRoot":"","sources":["../../src/endpoints/people.ts"],"names":[],"mappings":";;;AAcA,
|
|
1
|
+
{"version":3,"file":"people.js","sourceRoot":"","sources":["../../src/endpoints/people.ts"],"names":[],"mappings":";;;AAcA,iCAAsC;AAEtC,MAAM,WAAW,GAAG,SAAS,CAAC;AAE9B,MAAa,cAAe,SAAQ,mBAAY;IAC9C,YAAY,WAAmB;QAC7B,KAAK,CAAC,WAAW,CAAC,CAAC;IACrB,CAAC;IAED,KAAK,CAAC,OAAO,CAAC,EAAU;QACtB,OAAO,MAAM,IAAI,CAAC,GAAG,CAAC,GAAG,CAAe,GAAG,WAAW,IAAI,EAAE,EAAE,CAAC,CAAC;IAClE,CAAC;IAED,KAAK,CAAC,OAAO,CAAC,EAAU,EAAE,OAAuB;QAC/C,OAAO,MAAM,IAAI,CAAC,GAAG,CAAC,GAAG,CACvB,GAAG,WAAW,IAAI,EAAE,UAAU,EAC9B,OAAO,CACR,CAAC;IACJ,CAAC;IAED,KAAK,CAAC,YAAY,CAAC,EAAU;QAC3B,OAAO,MAAM,IAAI,CAAC,GAAG,CAAC,GAAG,CACvB,GAAG,WAAW,IAAI,EAAE,gBAAgB,CACrC,CAAC;IACJ,CAAC;IAED,KAAK,CAAC,aAAa,CAAC,EAAU;QAC5B,OAAO,MAAM,IAAI,CAAC,GAAG,CAAC,GAAG,CACvB,GAAG,WAAW,IAAI,EAAE,aAAa,CAClC,CAAC;IACJ,CAAC;IAED,KAAK,CAAC,eAAe,CAAC,EAAU;QAC9B,OAAO,MAAM,IAAI,CAAC,GAAG,CAAC,GAAG,CACvB,GAAG,WAAW,IAAI,EAAE,mBAAmB,CACxC,CAAC;IACJ,CAAC;IAED,KAAK,CAAC,UAAU,CAAC,EAAU;QACzB,OAAO,MAAM,IAAI,CAAC,GAAG,CAAC,GAAG,CAAc,GAAG,WAAW,IAAI,EAAE,eAAe,CAAC,CAAC;IAC9E,CAAC;IAED,KAAK,CAAC,MAAM,CAAC,EAAU;QACrB,OAAO,MAAM,IAAI,CAAC,GAAG,CAAC,GAAG,CACvB,GAAG,WAAW,IAAI,EAAE,SAAS,CAC9B,CAAC;IACJ,CAAC;IAED,KAAK,CAAC,YAAY,CAAC,EAAU,EAAE,OAAoB;QACjD,OAAO,MAAM,IAAI,CAAC,GAAG,CAAC,GAAG,CACvB,GAAG,WAAW,IAAI,EAAE,gBAAgB,EACpC,OAAO,CACR,CAAC;IACJ,CAAC;IAED,KAAK,CAAC,WAAW,CAAC,EAAU;QAC1B,OAAO,MAAM,IAAI,CAAC,GAAG,CAAC,GAAG,CACvB,GAAG,WAAW,IAAI,EAAE,eAAe,CACpC,CAAC;IACJ,CAAC;IAED,KAAK,CAAC,MAAM;QACV,OAAO,MAAM,IAAI,CAAC,GAAG,CAAC,GAAG,CAAe,GAAG,WAAW,SAAS,CAAC,CAAC;IACnE,CAAC;IAED,KAAK,CAAC,OAAO,CAAC,OAAoB;QAChC,OAAO,MAAM,IAAI,CAAC,GAAG,CAAC,GAAG,CACvB,GAAG,WAAW,UAAU,EACxB,OAAO,CACR,CAAC;IACJ,CAAC;CACF;AAnED,wCAmEC"}
|
package/dist/endpoints/search.js
CHANGED
|
@@ -2,7 +2,6 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.SearchEndpoint = void 0;
|
|
4
4
|
const base_1 = require("./base");
|
|
5
|
-
const utils_1 = require("../utils");
|
|
6
5
|
const BASE_SEARCH = '/search';
|
|
7
6
|
class SearchEndpoint extends base_1.BaseEndpoint {
|
|
8
7
|
constructor(accessToken) {
|
|
@@ -10,29 +9,23 @@ class SearchEndpoint extends base_1.BaseEndpoint {
|
|
|
10
9
|
this.accessToken = accessToken;
|
|
11
10
|
}
|
|
12
11
|
async companies(options) {
|
|
13
|
-
|
|
14
|
-
return await this.api.get(`${BASE_SEARCH}/company?${params}`);
|
|
12
|
+
return await this.api.get(`${BASE_SEARCH}/company`, options);
|
|
15
13
|
}
|
|
16
14
|
async collections(options) {
|
|
17
|
-
|
|
18
|
-
return await this.api.get(`${BASE_SEARCH}/collection?${params}`);
|
|
15
|
+
return await this.api.get(`${BASE_SEARCH}/collection`, options);
|
|
19
16
|
}
|
|
20
17
|
async keywords(options) {
|
|
21
|
-
|
|
22
|
-
return await this.api.get(`${BASE_SEARCH}/keyword?${params}`);
|
|
18
|
+
return await this.api.get(`${BASE_SEARCH}/keyword`, options);
|
|
23
19
|
}
|
|
24
20
|
async movies(options) {
|
|
25
|
-
|
|
26
|
-
return await this.api.get(`${BASE_SEARCH}/movie?${params}`);
|
|
21
|
+
return await this.api.get(`${BASE_SEARCH}/movie`, options);
|
|
27
22
|
}
|
|
28
23
|
async people(options) {
|
|
29
|
-
|
|
30
|
-
return await this.api.get(`${BASE_SEARCH}/person?${params}`);
|
|
24
|
+
return await this.api.get(`${BASE_SEARCH}/person`, options);
|
|
31
25
|
}
|
|
32
26
|
// TODO: Multi search
|
|
33
27
|
async tvShows(options) {
|
|
34
|
-
|
|
35
|
-
return await this.api.get(`${BASE_SEARCH}/tv?${params}`);
|
|
28
|
+
return await this.api.get(`${BASE_SEARCH}/tv`, options);
|
|
36
29
|
}
|
|
37
30
|
}
|
|
38
31
|
exports.SearchEndpoint = SearchEndpoint;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"search.js","sourceRoot":"","sources":["../../src/endpoints/search.ts"],"names":[],"mappings":";;;AAAA,iCAAsC;
|
|
1
|
+
{"version":3,"file":"search.js","sourceRoot":"","sources":["../../src/endpoints/search.ts"],"names":[],"mappings":";;;AAAA,iCAAsC;AAItC,MAAM,WAAW,GAAG,SAAS,CAAC;AAsB9B,MAAa,cAAe,SAAQ,mBAAY;IAC9C,YAA+B,WAAmB;QAChD,KAAK,CAAC,WAAW,CAAC,CAAC;QADU,gBAAW,GAAX,WAAW,CAAQ;IAElD,CAAC;IAED,KAAK,CAAC,SAAS,CAAC,OAAsB;QACpC,OAAO,MAAM,IAAI,CAAC,GAAG,CAAC,GAAG,CACvB,GAAG,WAAW,UAAU,EACxB,OAAO,CACR,CAAC;IACJ,CAAC;IAED,KAAK,CAAC,WAAW,CAAC,OAAsB;QACtC,OAAO,MAAM,IAAI,CAAC,GAAG,CAAC,GAAG,CACvB,GAAG,WAAW,aAAa,EAC3B,OAAO,CACR,CAAC;IACJ,CAAC;IAED,KAAK,CAAC,QAAQ,CACZ,OAAsB;QAEtB,OAAO,MAAM,IAAI,CAAC,GAAG,CAAC,GAAG,CACvB,GAAG,WAAW,UAAU,EACxB,OAAO,CACR,CAAC;IACJ,CAAC;IAED,KAAK,CAAC,MAAM,CAAC,OAA2B;QACtC,OAAO,MAAM,IAAI,CAAC,GAAG,CAAC,GAAG,CAAgB,GAAG,WAAW,QAAQ,EAAE,OAAO,CAAC,CAAC;IAC5E,CAAC;IAED,KAAK,CAAC,MAAM,CAAC,OAA4B;QACvC,OAAO,MAAM,IAAI,CAAC,GAAG,CAAC,GAAG,CAAiB,GAAG,WAAW,SAAS,EAAE,OAAO,CAAC,CAAC;IAC9E,CAAC;IAED,qBAAqB;IAErB,KAAK,CAAC,OAAO,CAAC,OAAwB;QACpC,OAAO,MAAM,IAAI,CAAC,GAAG,CAAC,GAAG,CAAa,GAAG,WAAW,KAAK,EAAE,OAAO,CAAC,CAAC;IACtE,CAAC;CACF;AAzCD,wCAyCC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"trending.js","sourceRoot":"","sources":["../../src/endpoints/trending.ts"],"names":[],"mappings":";;;AACA,iCAAsC;AAEtC,MAAa,gBAAiB,SAAQ,mBAAY;IAChD,YAAY,WAAmB;QAC7B,KAAK,CAAC,WAAW,CAAC,CAAC;IACrB,CAAC;IAED,KAAK,CAAC,QAAQ,
|
|
1
|
+
{"version":3,"file":"trending.js","sourceRoot":"","sources":["../../src/endpoints/trending.ts"],"names":[],"mappings":";;;AACA,iCAAsC;AAEtC,MAAa,gBAAiB,SAAQ,mBAAY;IAChD,YAAY,WAAmB;QAC7B,KAAK,CAAC,WAAW,CAAC,CAAC;IACrB,CAAC;IAED,KAAK,CAAC,QAAQ,CACZ,SAAY,EACZ,UAAsB;QAEtB,OAAO,MAAM,IAAI,CAAC,GAAG,CAAC,GAAG,CACvB,aAAa,SAAS,IAAI,UAAU,EAAE,CACvC,CAAC;IACJ,CAAC;CACF;AAbD,4CAaC"}
|
|
@@ -20,9 +20,9 @@ export declare class TvShowsEndpoint extends BaseEndpoint {
|
|
|
20
20
|
translations(id: number): Promise<Translations>;
|
|
21
21
|
videos(id: number): Promise<Videos>;
|
|
22
22
|
/**
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
23
|
+
* Powered by JustWatch
|
|
24
|
+
* @param id
|
|
25
|
+
*/
|
|
26
26
|
watchProviders(id: number): Promise<WatchProviders>;
|
|
27
27
|
latest(): Promise<LatestTvShows>;
|
|
28
28
|
onTheAir(): Promise<OnTheAir>;
|
|
@@ -2,7 +2,6 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.TvShowsEndpoint = void 0;
|
|
4
4
|
const base_1 = require("./base");
|
|
5
|
-
const utils_1 = require("../utils");
|
|
6
5
|
const BASE_TV = '/tv';
|
|
7
6
|
class TvShowsEndpoint extends base_1.BaseEndpoint {
|
|
8
7
|
constructor(accessToken) {
|
|
@@ -16,8 +15,7 @@ class TvShowsEndpoint extends base_1.BaseEndpoint {
|
|
|
16
15
|
return await this.api.get(`${BASE_TV}/${id}/alternative_titles`);
|
|
17
16
|
}
|
|
18
17
|
async changes(id, options) {
|
|
19
|
-
|
|
20
|
-
return await this.api.get(`${BASE_TV}/${id}/changes?${params}`);
|
|
18
|
+
return await this.api.get(`${BASE_TV}/${id}/changes`, options);
|
|
21
19
|
}
|
|
22
20
|
async contentRatings(id) {
|
|
23
21
|
return await this.api.get(`${BASE_TV}/${id}/content_ratings`);
|
|
@@ -41,19 +39,16 @@ class TvShowsEndpoint extends base_1.BaseEndpoint {
|
|
|
41
39
|
return await this.api.get(`${BASE_TV}/${id}/keywords`);
|
|
42
40
|
}
|
|
43
41
|
async recommendations(id, options) {
|
|
44
|
-
|
|
45
|
-
return await this.api.get(`${BASE_TV}/${id}/recommendations?${params}`);
|
|
42
|
+
return await this.api.get(`${BASE_TV}/${id}/recommendations`, options);
|
|
46
43
|
}
|
|
47
44
|
async reviews(id, options) {
|
|
48
|
-
|
|
49
|
-
return await this.api.get(`${BASE_TV}/${id}/reviews?${params}`);
|
|
45
|
+
return await this.api.get(`${BASE_TV}/${id}/reviews`, options);
|
|
50
46
|
}
|
|
51
47
|
async screenedTheatrically(id) {
|
|
52
48
|
return await this.api.get(`${BASE_TV}/${id}/screened_theatrically`);
|
|
53
49
|
}
|
|
54
50
|
async similar(id, options) {
|
|
55
|
-
|
|
56
|
-
return await this.api.get(`${BASE_TV}/${id}/similar?${params}`);
|
|
51
|
+
return await this.api.get(`${BASE_TV}/${id}/similar`, options);
|
|
57
52
|
}
|
|
58
53
|
async translations(id) {
|
|
59
54
|
return await this.api.get(`${BASE_TV}/${id}/translations`);
|
|
@@ -62,9 +57,9 @@ class TvShowsEndpoint extends base_1.BaseEndpoint {
|
|
|
62
57
|
return await this.api.get(`${BASE_TV}/${id}/videos`);
|
|
63
58
|
}
|
|
64
59
|
/**
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
60
|
+
* Powered by JustWatch
|
|
61
|
+
* @param id
|
|
62
|
+
*/
|
|
68
63
|
async watchProviders(id) {
|
|
69
64
|
return await this.api.get(`${BASE_TV}/${id}/watch/providers`);
|
|
70
65
|
}
|
|
@@ -75,16 +70,13 @@ class TvShowsEndpoint extends base_1.BaseEndpoint {
|
|
|
75
70
|
return await this.api.get(`${BASE_TV}/on_the_air`);
|
|
76
71
|
}
|
|
77
72
|
async airingToday(options) {
|
|
78
|
-
|
|
79
|
-
return await this.api.get(`${BASE_TV}/airing_today?${params}`);
|
|
73
|
+
return await this.api.get(`${BASE_TV}/airing_today`, options);
|
|
80
74
|
}
|
|
81
75
|
async popular(options) {
|
|
82
|
-
|
|
83
|
-
return await this.api.get(`${BASE_TV}/popular?${params}`);
|
|
76
|
+
return await this.api.get(`${BASE_TV}/popular`, options);
|
|
84
77
|
}
|
|
85
78
|
async topRated(options) {
|
|
86
|
-
|
|
87
|
-
return await this.api.get(`${BASE_TV}/top_rated?${params}`);
|
|
79
|
+
return await this.api.get(`${BASE_TV}/top_rated`, options);
|
|
88
80
|
}
|
|
89
81
|
}
|
|
90
82
|
exports.TvShowsEndpoint = TvShowsEndpoint;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"tv-shows.js","sourceRoot":"","sources":["../../src/endpoints/tv-shows.ts"],"names":[],"mappings":";;;AAAA,iCAAsC;
|
|
1
|
+
{"version":3,"file":"tv-shows.js","sourceRoot":"","sources":["../../src/endpoints/tv-shows.ts"],"names":[],"mappings":";;;AAAA,iCAAsC;AA8BtC,MAAM,OAAO,GAAG,KAAK,CAAC;AAEtB,MAAa,eAAgB,SAAQ,mBAAY;IAC/C,YAA+B,WAAmB;QAChD,KAAK,CAAC,WAAW,CAAC,CAAC;QADU,gBAAW,GAAX,WAAW,CAAQ;IAElD,CAAC;IAED,KAAK,CAAC,OAAO,CAAC,EAAU;QACtB,OAAO,MAAM,IAAI,CAAC,GAAG,CAAC,GAAG,CAAgB,GAAG,OAAO,IAAI,EAAE,EAAE,CAAC,CAAC;IAC/D,CAAC;IAED,KAAK,CAAC,iBAAiB,CAAC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ACV,OAAO,MAAM,IAAI,CAAC,GAAG,CAAC,GAAG,CAAgB,GAAG,OAAO,SAAS,CAAC,CAAC;IAChE,CAAC;IAED,KAAK,CAAC,QAAQ;QACZ,OAAO,MAAM,IAAI,CAAC,GAAG,CAAC,GAAG,CAAW,GAAG,OAAO,aAAa,CAAC,CAAC;IAC/D,CAAC;IAED,KAAK,CAAC,WAAW,CACf,OAAoD;QAEpD,OAAO,MAAM,IAAI,CAAC,GAAG,CAAC,GAAG,CACvB,GAAG,OAAO,eAAe,EACzB,OAAO,CACR,CAAC;IACJ,CAAC;IAED,KAAK,CAAC,OAAO,CACX,OAAoD;QAEpD,OAAO,MAAM,IAAI,CAAC,GAAG,CAAC,GAAG,CAAiB,GAAG,OAAO,UAAU,EAAE,OAAO,CAAC,CAAC;IAC3E,CAAC;IAED,KAAK,CAAC,QAAQ,CACZ,OAAoD;QAEpD,OAAO,MAAM,IAAI,CAAC,GAAG,CAAC,GAAG,CAAkB,GAAG,OAAO,YAAY,EAAE,OAAO,CAAC,CAAC;IAC9E,CAAC;CACF;AA/HD,0CA+HC"}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
export interface Gravatar {
|
|
2
|
+
hash: string;
|
|
3
|
+
}
|
|
4
|
+
export interface Avatar {
|
|
5
|
+
gravatar: Gravatar;
|
|
6
|
+
}
|
|
7
|
+
export interface AccountDetails {
|
|
8
|
+
avatar: Avatar;
|
|
9
|
+
id: number;
|
|
10
|
+
include_adult: boolean;
|
|
11
|
+
iso_3166_1: string;
|
|
12
|
+
iso_639_1: string;
|
|
13
|
+
name: string;
|
|
14
|
+
username: string;
|
|
15
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"account.js","sourceRoot":"","sources":["../../src/types/account.ts"],"names":[],"mappings":""}
|
package/dist/types/index.d.ts
CHANGED
|
@@ -120,14 +120,14 @@ export interface ContentRatingsResult {
|
|
|
120
120
|
}
|
|
121
121
|
export interface Recommendation {
|
|
122
122
|
adult: boolean;
|
|
123
|
-
backdrop_path?:
|
|
123
|
+
backdrop_path?: string;
|
|
124
124
|
genre_ids: number[];
|
|
125
125
|
id: number;
|
|
126
126
|
original_language: string;
|
|
127
127
|
original_title: string;
|
|
128
128
|
overview: string;
|
|
129
129
|
release_date: string;
|
|
130
|
-
poster_path?:
|
|
130
|
+
poster_path?: string;
|
|
131
131
|
popularity: number;
|
|
132
132
|
title: string;
|
|
133
133
|
video: boolean;
|
package/dist/types/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/types/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,4CAA0B;AAC1B,kDAAgC;AAChC,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/types/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,4CAA0B;AAC1B,kDAAgC;AAChC,4CAA0B;AAC1B,kDAAgC;AAChC,4CAA0B;AAC1B,2CAAyB;AACzB,2CAAyB;AACzB,6CAA2B;AAC3B,oDAAkC;AAClC,2CAAyB;AACzB,6CAA2B;AAC3B,2CAAyB;AACzB,6CAA2B;AAC3B,yCAAuB;AACvB,6CAA2B;AAC3B,gDAA8B"}
|
package/dist/types/movies.d.ts
CHANGED
|
@@ -1,8 +1,14 @@
|
|
|
1
1
|
import { Genre, Movie, ProductionCompany, ProductionCountry, SpokenLanguage } from './';
|
|
2
|
+
export interface BelongsToCollection {
|
|
3
|
+
id: number;
|
|
4
|
+
name: string;
|
|
5
|
+
poster_path: string;
|
|
6
|
+
backdrop_path: string;
|
|
7
|
+
}
|
|
2
8
|
export interface MovieDetails {
|
|
3
9
|
adult: boolean;
|
|
4
10
|
backdrop_path: string;
|
|
5
|
-
belongs_to_collection?:
|
|
11
|
+
belongs_to_collection?: BelongsToCollection;
|
|
6
12
|
budget: number;
|
|
7
13
|
genres: Genre[];
|
|
8
14
|
homepage: string;
|
|
@@ -12,7 +18,7 @@ export interface MovieDetails {
|
|
|
12
18
|
original_title: string;
|
|
13
19
|
overview: string;
|
|
14
20
|
popularity: number;
|
|
15
|
-
poster_path?:
|
|
21
|
+
poster_path?: string;
|
|
16
22
|
production_companies: ProductionCompany[];
|
|
17
23
|
production_countries: ProductionCountry[];
|
|
18
24
|
release_date: string;
|
|
@@ -89,8 +95,8 @@ export interface MovieChanges {
|
|
|
89
95
|
}
|
|
90
96
|
export interface LatestMovie {
|
|
91
97
|
adult: boolean;
|
|
92
|
-
backdrop_path?:
|
|
93
|
-
belongs_to_collection?:
|
|
98
|
+
backdrop_path?: string;
|
|
99
|
+
belongs_to_collection?: BelongsToCollection;
|
|
94
100
|
budget: number;
|
|
95
101
|
genres: Genre[];
|
|
96
102
|
homepage: string;
|
|
@@ -101,12 +107,12 @@ export interface LatestMovie {
|
|
|
101
107
|
overview: string;
|
|
102
108
|
popularity: number;
|
|
103
109
|
poster_path: string;
|
|
104
|
-
production_companies:
|
|
105
|
-
production_countries:
|
|
110
|
+
production_companies: ProductionCompany[];
|
|
111
|
+
production_countries: ProductionCountry[];
|
|
106
112
|
release_date: string;
|
|
107
113
|
revenue: number;
|
|
108
114
|
runtime: number;
|
|
109
|
-
spoken_languages:
|
|
115
|
+
spoken_languages: SpokenLanguage[];
|
|
110
116
|
status: string;
|
|
111
117
|
tagline: string;
|
|
112
118
|
title: string;
|
package/dist/types/movies.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"movies.js","sourceRoot":"","sources":["../../src/types/movies.ts"],"names":[],"mappings":";;;
|
|
1
|
+
{"version":3,"file":"movies.js","sourceRoot":"","sources":["../../src/types/movies.ts"],"names":[],"mappings":";;;AA2CA,IAAY,eAOX;AAPD,WAAY,eAAe;IACzB,6DAAc,CAAA;IACd,qFAAsB,CAAA;IACtB,iEAAY,CAAA;IACZ,2DAAS,CAAA;IACT,6DAAU,CAAA;IACV,iDAAI,CAAA;AACN,CAAC,EAPW,eAAe,GAAf,uBAAe,KAAf,uBAAe,QAO1B"}
|
package/dist/types/tv-shows.d.ts
CHANGED
|
@@ -6,6 +6,20 @@ export interface CreatedBy {
|
|
|
6
6
|
gender: number;
|
|
7
7
|
profile_path: string;
|
|
8
8
|
}
|
|
9
|
+
export interface NextEpisodeToAir {
|
|
10
|
+
id: number;
|
|
11
|
+
name: string;
|
|
12
|
+
overview: string;
|
|
13
|
+
vote_average: number;
|
|
14
|
+
vote_count: number;
|
|
15
|
+
air_date: string;
|
|
16
|
+
episode_number: number;
|
|
17
|
+
production_code: string;
|
|
18
|
+
runtime: number;
|
|
19
|
+
season_number: number;
|
|
20
|
+
show_id: number;
|
|
21
|
+
still_path: string;
|
|
22
|
+
}
|
|
9
23
|
export interface LastEpisodeToAir {
|
|
10
24
|
air_date: string;
|
|
11
25
|
episode_number: number;
|
|
@@ -46,7 +60,7 @@ export interface TvShowDetails {
|
|
|
46
60
|
last_air_date: string;
|
|
47
61
|
last_episode_to_air: LastEpisodeToAir;
|
|
48
62
|
name: string;
|
|
49
|
-
next_episode_to_air?:
|
|
63
|
+
next_episode_to_air?: NextEpisodeToAir;
|
|
50
64
|
networks: Network[];
|
|
51
65
|
number_of_episodes: number;
|
|
52
66
|
number_of_seasons: number;
|
|
@@ -108,9 +122,9 @@ export interface TvShowItem {
|
|
|
108
122
|
id: string;
|
|
109
123
|
action: string;
|
|
110
124
|
time: string;
|
|
111
|
-
value:
|
|
125
|
+
value: Array<number>;
|
|
112
126
|
iso_639_1: string;
|
|
113
|
-
original_value:
|
|
127
|
+
original_value: Array<number>;
|
|
114
128
|
}
|
|
115
129
|
export interface TvShowChange {
|
|
116
130
|
key: string;
|
|
@@ -169,8 +183,8 @@ export interface SimilarTvShows {
|
|
|
169
183
|
total_results: number;
|
|
170
184
|
}
|
|
171
185
|
export interface LatestTvShows {
|
|
172
|
-
backdrop_path?:
|
|
173
|
-
created_by:
|
|
186
|
+
backdrop_path?: string;
|
|
187
|
+
created_by: CreatedBy[];
|
|
174
188
|
episode_run_time: number[];
|
|
175
189
|
first_air_date: string;
|
|
176
190
|
genres: Genre[];
|
|
@@ -186,10 +200,10 @@ export interface LatestTvShows {
|
|
|
186
200
|
origin_country: string[];
|
|
187
201
|
original_language: string;
|
|
188
202
|
original_name: string;
|
|
189
|
-
overview?:
|
|
203
|
+
overview?: string;
|
|
190
204
|
popularity: number;
|
|
191
|
-
poster_path?:
|
|
192
|
-
production_companies:
|
|
205
|
+
poster_path?: string;
|
|
206
|
+
production_companies: ProductionCompany[];
|
|
193
207
|
seasons: Season[];
|
|
194
208
|
status: string;
|
|
195
209
|
type: string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"getImagePath.js","sourceRoot":"","sources":["../../src/utils/getImagePath.ts"],"names":[],"mappings":";;;AAAA;;;;;;;;;GASG;AACI,MAAM,gBAAgB,GAAG,
|
|
1
|
+
{"version":3,"file":"getImagePath.js","sourceRoot":"","sources":["../../src/utils/getImagePath.ts"],"names":[],"mappings":";;;AAAA;;;;;;;;;GASG;AACI,MAAM,gBAAgB,GAAG,CAC9B,OAAe,EACf,QAAgB,EAChB,SAAiB,EACjB,GAAG,GAAG,KAAK,EACH,EAAE;IACV,MAAM,YAAY,GAAG,SAAS,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC;IAC1C,MAAM,WAAW,GAAG,GAAG,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,YAAY,CAAC,CAAC,CAAC,CAAC;IAElD,OAAO,GAAG,OAAO,GAAG,QAAQ,GAAG,YAAY,CAAC,CAAC,CAAC,IAAI,WAAW,EAAE,CAAC;AAClE,CAAC,CAAC;AAVW,QAAA,gBAAgB,oBAU3B"}
|
|
@@ -2,9 +2,8 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.parseOptions = void 0;
|
|
4
4
|
function parseOptions(options) {
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
: '';
|
|
5
|
+
/* eslint-disable @typescript-eslint/no-explicit-any */
|
|
6
|
+
return options ? new URLSearchParams(Object.entries(options)).toString() : '';
|
|
8
7
|
}
|
|
9
8
|
exports.parseOptions = parseOptions;
|
|
10
9
|
//# sourceMappingURL=parseOptions.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"parseOptions.js","sourceRoot":"","sources":["../../src/utils/parseOptions.ts"],"names":[],"mappings":";;;AAAA,SAAgB,YAAY,
|
|
1
|
+
{"version":3,"file":"parseOptions.js","sourceRoot":"","sources":["../../src/utils/parseOptions.ts"],"names":[],"mappings":";;;AAAA,SAAgB,YAAY,CAAC,OAA6B;IAC1D,wDAAwD;IACtD,OAAO,OAAO,CAAC,CAAC,CAAC,IAAI,eAAe,CAAC,MAAM,CAAC,OAAO,CAAC,OAAO,CAAC,CAAC,CAAC,QAAQ,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC;AAChF,CAAC;AAHD,oCAGC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "tmdb-ts",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.2.0",
|
|
4
4
|
"description": "TMDB v3 library wrapper",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"types": "dist/index.d.ts",
|
|
@@ -8,7 +8,8 @@
|
|
|
8
8
|
"compile": "rm -rf dist && tsc -d && npm run copy-types",
|
|
9
9
|
"lint": "eslint --ext .ts src/",
|
|
10
10
|
"lint:fix": "eslint --ext .ts src/ --fix",
|
|
11
|
-
"
|
|
11
|
+
"format": "npx prettier --write src",
|
|
12
|
+
"pre-commit": "npm run lint",
|
|
12
13
|
"copy-types": "mkdir dist/types && cp src/types/*.d.ts dist/types"
|
|
13
14
|
},
|
|
14
15
|
"bugs": {
|
|
@@ -31,14 +32,17 @@
|
|
|
31
32
|
"devDependencies": {
|
|
32
33
|
"@types/node": "^15.3.0",
|
|
33
34
|
"@types/node-fetch": "^2.5.10",
|
|
34
|
-
"@typescript-eslint/eslint-plugin": "^
|
|
35
|
-
"@typescript-eslint/parser": "^
|
|
35
|
+
"@typescript-eslint/eslint-plugin": "^5.58.0",
|
|
36
|
+
"@typescript-eslint/parser": "^5.58.0",
|
|
36
37
|
"dotenv": "^9.0.2",
|
|
37
|
-
"eslint": "^
|
|
38
|
-
"eslint-config-airbnb-
|
|
39
|
-
"eslint-
|
|
38
|
+
"eslint": "^8.38.0",
|
|
39
|
+
"eslint-config-airbnb-typescript": "^17.0.0",
|
|
40
|
+
"eslint-config-prettier": "^8.8.0",
|
|
41
|
+
"eslint-plugin-prettier": "^4.2.1",
|
|
42
|
+
"husky": "^8.0.3",
|
|
43
|
+
"prettier": "^2.8.7",
|
|
40
44
|
"ts-node": "^9.1.1",
|
|
41
|
-
"typescript": "^4.
|
|
45
|
+
"typescript": "^4.9.5"
|
|
42
46
|
},
|
|
43
47
|
"dependencies": {
|
|
44
48
|
"cross-fetch": "^3.1.4"
|
|
@@ -48,6 +52,11 @@
|
|
|
48
52
|
"yarn": "1.19.2",
|
|
49
53
|
"npm": "7.12.1"
|
|
50
54
|
},
|
|
55
|
+
"husky": {
|
|
56
|
+
"hooks": {
|
|
57
|
+
"pre-commit": "npm run pre-commit"
|
|
58
|
+
}
|
|
59
|
+
},
|
|
51
60
|
"files": [
|
|
52
61
|
"dist"
|
|
53
62
|
]
|