Hello,
Il s’agit de quelque chose qui ressemblerait à ça en terme de données?
Avec comme résultats, au format JSON:
let testPost = new Post('mall_post_2178334082281758:6:0')
let allComments = testPost.getComments()
JSON.stringify(allComments,null,2)
"[
{
"author": {
"link": "https://www.facebook.com/nicolas.vrc",
"name": "Nicolas Vriak"
},
"text": "C’est top ! Vas-y sans hésiter",
"reactions": [
"2 J’aime"
],
"publicationDate": "Lundi 28 janvier 2019, 19:47",
"timestamp": "1548701248",
"link": "/groups/ghfrance/permalink/2178334082281758/?comment_id=2181640398617793&comment_tracking=%7B%22tn%22%3A%22R%2312%22%7D",
"replies": []
},
{
"author": {
"link": "https://www.facebook.com/pierreandre.fortin",
"name": "Pierre-André Fortin"
},
"text": "Super outil - je plussoie !!!",
"reactions": [
"2 J’aime"
],
"publicationDate": "Lundi 28 janvier 2019, 20:09",
"timestamp": "1548702549",
"link": "/groups/ghfrance/permalink/2178334082281758/?comment_id=2181660975282402&comment_tracking=%7B%22tn%22%3A%22R%2311%22%7D",
"replies": []
},
{
"author": {
"link": "https://www.facebook.com/hamadi.lanouar",
"name": "Hamadi Lanouar"
},
"text": "C’est les meilleurs. Leurs API sont super stables et très concurrentiels au niveau prix. Leur service client est top également.",
"reactions": [
"2 J’aime"
],
"publicationDate": "Lundi 28 janvier 2019, 20:10",
"timestamp": "1548702607",
"link": "/groups/ghfrance/permalink/2178334082281758/?comment_id=2181662011948965&comment_tracking=%7B%22tn%22%3A%22R%2310%22%7D",
"replies": []
},
{
"author": {
"link": "https://www.facebook.com/astrid.elle",
"name": "Astrid Elle"
},
"text": "Yes ! Go go :)",
"reactions": [
"2 J’aime"
],
"publicationDate": "Lundi 28 janvier 2019, 20:35",
"timestamp": "1548704119",
"link": "/groups/ghfrance/permalink/2178334082281758/?comment_id=2181686008613232&comment_tracking=%7B%22tn%22%3A%22R9%22%7D",
"replies": []
},
{
"author": {
"link": "https://www.facebook.com/emilevardanian2",
"name": "Mark Ravanello"
},
"text": "Ca semble bien sympa ... tutos ?",
"reactions": [
"1 J’aime"
],
"publicationDate": "Lundi 28 janvier 2019, 21:05",
"timestamp": "1548705926",
"link": "/groups/ghfrance/permalink/2178334082281758/?comment_id=2181712701943896&comment_tracking=%7B%22tn%22%3A%22R8%22%7D",
"replies": [
{
"author": {
"link": "https://www.facebook.com/guillaume.boiret",
"name": "Guillaume Boiret"
},
"text": "Hello, nous avons des tuto ici et là :) http://blog.phantombuster.com | https://www.youtube.com/channel/UCLBxOUbr2b_fNcem5YwSXxw",
"reactions": [
"7 J’aime"
],
"publicationDate": "Lundi 28 janvier 2019, 22:00",
"timestamp": "1548709207",
"link": "/groups/ghfrance/permalink/2178334082281758/?comment_id=2181712701943896&reply_comment_id=2181770141938152&comment_tracking=%7B%22tn%22%3A%22R%2312%22%7D",
"replies": []
},
{
"author": {
"link": "https://www.facebook.com/profile.php?id=100008497396314",
"name": "Jihane Hrz"
},
"text": "J'adore le CEO qui surveille dans un coin 😂 bravo 😉",
"reactions": [
"1 J’aime"
],
"publicationDate": "Lundi 28 janvier 2019, 22:38",
"timestamp": "1548711501",
"link": "/groups/ghfrance/permalink/2178334082281758/?comment_id=2181712701943896&reply_comment_id=2181804648601368&comment_tracking=%7B%22tn%22%3A%22R%2311%22%7D",
"replies": []
},
{
"author": {
"link": "https://www.facebook.com/zozo.youns",
"name": "Zozo Youn's"
},
"text": "Jihane Hrz j’allais dire la même ! Trop vif Phantombuster - API-fy the Web",
"reactions": [
"1 Haha"
],
"publicationDate": "Lundi 28 janvier 2019, 23:28",
"timestamp": "1548714486",
"link": "/groups/ghfrance/permalink/2178334082281758/?comment_id=2181712701943896&reply_comment_id=2181847638597069&comment_tracking=%7B%22tn%22%3A%22R%2310%22%7D",
"replies": []
},
{
"author": {
"link": "https://www.facebook.com/romain.mrct",
"name": "Romain Marcet"
},
"text": "Guillaume Boiret Bonjour, il y a eu récemment beaucoup d'articles sur le fait qu'Instagram pénalise désormais l'utilisation de bots ou API tierce. Comment Phantombuster passe entre les maille du filet ? Etait-ce juste un effet d'annonce de la part d'instagram ?",
"reactions": [],
"publicationDate": "Jeudi 31 janvier 2019, 09:20",
"timestamp": "1548922850",
"link": "/groups/ghfrance/permalink/2178334082281758/?comment_id=2181712701943896&reply_comment_id=2185559804892519&comment_tracking=%7B%22tn%22%3A%22R9%22%7D",
"replies": []
}
]
},
{
"author": {
"link": "https://www.facebook.com/teixeirayohan",
"name": "Yohan Teixeira"
},
"text": "Guillaume Boiret 🙌",
"reactions": [
"2 J’aime"
],
"publicationDate": "Lundi 28 janvier 2019, 21:45",
"timestamp": "1548708357",
"link": "/groups/ghfrance/permalink/2178334082281758/?comment_id=2181756731939493&comment_tracking=%7B%22tn%22%3A%22R7%22%7D",
"replies": []
},
{
"author": {
"link": "https://www.facebook.com/mhdtfr",
"name": "Mehdi Tfr"
},
"text": "Très puissant mais nécessite quand même un minimum de skills technique, après tu peux aller très loin avec :)",
"reactions": [
"1 J’aime"
],
"publicationDate": "Lundi 28 janvier 2019, 22:26",
"timestamp": "1548710763",
"link": "/groups/ghfrance/permalink/2178334082281758/?comment_id=2181794001935766&comment_tracking=%7B%22tn%22%3A%22R6%22%7D",
"replies": []
},
{
"author": {
"link": "https://www.facebook.com/profile.php?id=100008497396314",
"name": "Jihane Hrz"
},
"text": "Chaïb Martinez",
"reactions": [
"1 J’aime"
],
"publicationDate": "Lundi 28 janvier 2019, 22:35",
"timestamp": "1548711342",
"link": "/groups/ghfrance/permalink/2178334082281758/?comment_id=2181802238601609&comment_tracking=%7B%22tn%22%3A%22R5%22%7D",
"replies": [
{
"author": {
"link": "https://www.facebook.com/chaib.martinez",
"name": "Chaïb Martinez"
},
"text": "C'est dans mes favoris déjà. C'est top comme outil. Merci pour le partage",
"reactions": [
"1 J’adore"
],
"publicationDate": "Mardi 29 janvier 2019, 13:40",
"timestamp": "1548765602",
"link": "/groups/ghfrance/permalink/2178334082281758/?comment_id=2181802238601609&reply_comment_id=2182720675176432&comment_tracking=%7B%22tn%22%3A%22R%2312%22%7D",
"replies": []
}
]
},
{
"author": {
"link": "https://www.facebook.com/thibault.marty",
"name": "Thibault Marty"
},
"text": "En général c'est du bon, sauf pour le facebook message auto... Vu qu'ils utilisent les cookies de ton compte, Facebook se méfie des téléportations...",
"reactions": [
"1 J’aime"
],
"publicationDate": "Lundi 28 janvier 2019, 22:58",
"timestamp": "1548712719",
"link": "/groups/ghfrance/permalink/2178334082281758/?comment_id=2181824025266097&comment_tracking=%7B%22tn%22%3A%22R4%22%7D",
"replies": []
},
{
"author": {
"link": "https://www.facebook.com/chlo.bct",
"name": "Chloé Beauchet"
},
"text": "Francis en a parlé lors de notre workshop sur le growth hacking au Le Wagon. Je ne l'ai pas sur Facebook mais je peux vous slacker ensemble si tu veux un pro de growth. :)",
"reactions": [],
"publicationDate": "Lundi 28 janvier 2019, 23:13",
"timestamp": "1548713595",
"link": "/groups/ghfrance/permalink/2178334082281758/?comment_id=2181836001931566&comment_tracking=%7B%22tn%22%3A%22R3%22%7D",
"replies": []
},
{
"author": {
"link": "https://www.facebook.com/emmanuel.darmon",
"name": "Emmanuel Darmon"
},
"text": "C’est top, je recommande +++",
"reactions": [
"1 J’aime"
],
"publicationDate": "Lundi 28 janvier 2019, 23:22",
"timestamp": "1548714156",
"link": "/groups/ghfrance/permalink/2178334082281758/?comment_id=2181843225264177&comment_tracking=%7B%22tn%22%3A%22R2%22%7D",
"replies": []
},
{
"author": {
"link": "https://www.facebook.com/quentin.durantay",
"name": "Quentin Durantay"
},
"text": "www.apify.com bien plus puissant",
"reactions": [
"1 J’aime",
"1 J’adore"
],
"publicationDate": "Mardi 29 janvier 2019, 00:27",
"timestamp": "1548718068",
"link": "/groups/ghfrance/permalink/2178334082281758/?comment_id=2181905451924621&comment_tracking=%7B%22tn%22%3A%22R1%22%7D",
"replies": []
},
{
"author": {
"link": "https://www.facebook.com/pabloguiraoperso",
"name": "Pablo Guirao"
},
"text": "On en parle de Zenno ?",
"reactions": [
"2 J’aime"
],
"publicationDate": "Mardi 29 janvier 2019, 09:22",
"timestamp": "1548750122",
"link": "/groups/ghfrance/permalink/2178334082281758/?comment_id=2182436775204822&comment_tracking=%7B%22tn%22%3A%22R0%22%7D",
"replies": []
},
{
"author": {
"link": "https://www.facebook.com/gauthier.buttez",
"name": "Gauthier Buttez"
},
"text": "C’est de la balle🔫 et c’est Français🇫🇷. Les tutos sont a l’interieur de chaque API.",
"reactions": [],
"publicationDate": "Vendredi 1 février 2019, 19:52",
"timestamp": "1549047172",
"link": "/groups/ghfrance/permalink/2178334082281758/?comment_id=2187893451325821&comment_tracking=%7B%22tn%22%3A%22R%22%7D",
"replies": []
}
]"
Voir discussion à ce sujet:
Bonjour, le probleme ds ce type de script ce sont les tests, il convient d’envisager tous les cas. Une solution de type python + beautifulsoup + selenium(pr les clics) est envisageable. Selenium imite le comportement d’un humain cependant je ne sais pas si fb arrive à detecter que c est un bot qui parcourt le site, en particulier en collectant les coordonnées du deplacement de la souris (comme pr un capcha). Si la solution est oui alors y a moyen de se faire reperer et blacklister son compte f…