Seth-77
Seth-77

Reputation: 254

Tumblr API followers total

I'm trying to get the number of followers on my blog to display on the blogs index page. I currently have the total posts by using this with some JS code:

var posts = tumblr_api_read['posts-total'] // total posts

But I've tried tweeking it to total_users as suggedted in the Tumblr API manual but nothing happens, it says undefined.

Can anyone help.

Upvotes: 2

Views: 1463

Answers (1)

octagonal
octagonal

Reputation: 91

You can see your total amount of followers by issuing

GET
on
api.tumblr.com/v2/blog/{base-hostname}/followers
where base-hostname is your blog's name. The behavior is documented here in the Tumblr API docs. Keep in mind you need to be authenticated with OAuth for the request to go through.

The total_users request you read about is actually a response that you get when you issue the followers request. May I ask which API you're using?

Upvotes: 2

Related Questions