Noco/API/partners

De Nolife-Wiki
Aller à la navigation Aller à la recherche

partners.json est une bibliothèque de l'API noco permettant de récupérer des informations sur les catalogues

partners : Liste des catalogues[modifier]

Requête : https://api.noco.tv:443/1.1/partners

Méthode GET : récupérer les informations

Réponse :

[
 {
   "id_partner": 1,                         //Numéro du catalogue
   "partner_name": "Nolife",                //Nom
   "partner_shortname": "Nolife",           //Nom court
   "partner_key": "NOL",                    //Clé (3 caractères)
   "geoloc": "*",                           //Restriction Géo par défaut
   "nb_shows": 15303,                       //Nombre de vidéos disponibles
   "partner_resume": null,
   "partner_subtitle": null,
   "banner_partner": "https://media.noco.tv/partner/slider/nol.jpg",
   "icon_128x72": "https://media.noco.tv/partner/icon/128x72/nol.jpg",
   "icon_256x144": "https://media.noco.tv/partner/icon/256x144/nol.jpg",
   "icon_512x288": "https://media.noco.tv/partner/icon/512x288/nol.jpg",
   "icon_960x540": "https://media.noco.tv/partner/icon/960x540/nol.jpg",
   "icon_1024x576": "https://media.noco.tv/partner/icon/1024x576/nol.jpg"
 },
 ·
 ·
 ·
 {
   "id_partner": 9,
   "partner_name": "Toki Media",
   "partner_shortname": "Toki Media",
   "partner_key": "TOK",
   "geoloc": "fr,re,gf,gp,mq,yt,pm,bl,mf,wf,pf,nc,tf",
   "nb_shows": 68,
   "partner_resume": null,
   "partner_subtitle": null,
   "banner_partner": "https://media.noco.tv/partner/slider/tok.jpg",
   "icon_128x72": "https://media.noco.tv/partner/icon/128x72/tok.jpg",
   "icon_256x144": "https://media.noco.tv/partner/icon/256x144/tok.jpg",
   "icon_512x288": "https://media.noco.tv/partner/icon/512x288/tok.jpg",
   "icon_960x540": "https://media.noco.tv/partner/icon/960x540/tok.jpg",
   "icon_1024x576": "https://media.noco.tv/partner/icon/1024x576/tok.jpg"
 }
]

partners/by_id/{id_partner} : Description d’un catalogue[modifier]

Requête : https://api.noco.tv:443/1.1/partners/by_id/1

Méthode GET : récupérer les informations (l'argument id_partner est obligatoire)

Réponse :

[
 {
   "id_partner": 1,
   "partner_name": "Nolife",
   "partner_shortname": "Nolife",
   "partner_key": "NOL",
   "geoloc": "*",
   "nb_shows": 15303,
   "partner_resume": null,
   "partner_subtitle": null,
   "banner_partner": "https://media.noco.tv/partner/slider/nol.jpg",
   "icon_128x72": "https://media.noco.tv/partner/icon/128x72/nol.jpg",
   "icon_256x144": "https://media.noco.tv/partner/icon/256x144/nol.jpg",
   "icon_512x288": "https://media.noco.tv/partner/icon/512x288/nol.jpg",
   "icon_960x540": "https://media.noco.tv/partner/icon/960x540/nol.jpg",
   "icon_1024x576": "https://media.noco.tv/partner/icon/1024x576/nol.jpg"
 }
]

partners/by_key/{partner_key} : Description d’un catalogue[modifier]

Requête : https://api.noco.tv:443/1.1/partners/by_key/OLY

Méthode GET : récupérer les informations (l'argument partner_key est obligatoire)

Réponse :

[
 {
   "id_partner": 4,
   "partner_name": "Olydri Studio",
   "partner_shortname": "Olydri",
   "partner_key": "OLY",
   "geoloc": "*",
   "nb_shows": 134,
   "partner_resume": null,
   "partner_subtitle": null,
   "banner_partner": "https://media.noco.tv/partner/slider/oly.jpg",
   "icon_128x72": "https://media.noco.tv/partner/icon/128x72/oly.jpg",
   "icon_256x144": "https://media.noco.tv/partner/icon/256x144/oly.jpg",
   "icon_512x288": "https://media.noco.tv/partner/icon/512x288/oly.jpg",
   "icon_960x540": "https://media.noco.tv/partner/icon/960x540/oly.jpg",
   "icon_1024x576": "https://media.noco.tv/partner/icon/1024x576/oly.jpg"
 }
]

partners/by_module/{id_module} : Liste des catalogues pour un module[modifier]

Requête : https://api.noco.tv:443/1.1/partners/by_module/1

Méthode GET : récupérer les informations (l'argument id_module est obligatoire)

Méthode non exploitable, renvoie pour chaque module existant l'ensemble des catalogues

partners/subscribed : Liste des abonnements en cours[modifier]

Requête : https://api.noco.tv:443/1.1/partners/subscribed

Méthode GET : récupérer les informations

[
 {
   "id_partner": 18,
   "partner_name": "Guardians",
   "partner_shortname": "Guardians",
   "partner_key": "GUA",
   "geoloc": "*",
   "nb_shows": 92,
   "partner_resume": "",
   "partner_subtitle": null,
   "banner_partner": "https://media.noco.tv/partner/slider/gua.jpg",
   "icon_128x72": "https://media.noco.tv/partner/icon/128x72/gua.jpg",
   "icon_256x144": "https://media.noco.tv/partner/icon/256x144/gua.jpg",
   "icon_512x288": "https://media.noco.tv/partner/icon/512x288/gua.jpg",
   "icon_960x540": "https://media.noco.tv/partner/icon/960x540/gua.jpg",
   "icon_1024x576": "https://media.noco.tv/partner/icon/1024x576/gua.jpg"
 },
 ·
 ·
 ·
 {
   "id_partner": 1,
   "partner_name": "Nolife",
   "partner_shortname": "Nolife",
   "partner_key": "NOL",
   "geoloc": "*",
   "nb_shows": 15303,
   "partner_resume": null,
   "partner_subtitle": null,
   "banner_partner": "https://media.noco.tv/partner/slider/nol.jpg",
   "icon_128x72": "https://media.noco.tv/partner/icon/128x72/nol.jpg",
   "icon_256x144": "https://media.noco.tv/partner/icon/256x144/nol.jpg",
   "icon_512x288": "https://media.noco.tv/partner/icon/512x288/nol.jpg",
   "icon_960x540": "https://media.noco.tv/partner/icon/960x540/nol.jpg",
   "icon_1024x576": "https://media.noco.tv/partner/icon/1024x576/nol.jpg"
 }
]