Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

how to use Disqus JS api?

I get the post id like "342956146212" by the api of "https://disqus.com/api/3.0/posts/list.json".

It's successful.

I try to update the post as follows.

var forum = "portoxxxx";
var APIKEY = "r1GglbTmZuZLWl6xxxxxxyIBRtJNZf7SL";
jQuery.post('https://disqus.com/api/3.0/posts/update.json',{
        forum:forum,
        post:342956146212,
        message:"This comment has been overwritten",
        api_key:APIKEY})    });

but it's wrong. enter image description here

please tell me how to finish it, thanks!

like image 814
Tornado Avatar asked Jan 26 '26 10:01

Tornado


1 Answers

The problem has been solved.

    jQuery.post('https://disqus.com/api/3.0/posts/update.json',{
        post:"2957858030",
        access_token:ACCESS_TOKEN,
        message:"This comment has been overwritten",
        api_key:APIKEY})

the previous argument of forum is invalid.

And I add the new argument of access_token to solve the authorized problem

like image 186
Tornado Avatar answered Jan 27 '26 22:01

Tornado



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!