Type badge

Discussion

This type represents a badge on a Stack Exchange site.

Some badges, like Autobiographer, are held in common across all Stack Exchange sites. Others, like most tag badges, vary on a site by site basis.

Remember that ids are never guaranteed to be the same between sites, even if a badge exists on both sites.

Fields

award_count
integer

badge_id
integer, refers to a badge

badge_type
one of named, or tag_based

description
string
unchanged in unsafe filters

link
string
unchanged in unsafe filters

name
string

rank
one of gold, silver, or bronze

Fields marked with are included in the default filter, those marked with are excluded in the default filter.

Examples

Named Badge

{"badge_type":"named","award_count":2000,"rank":"silver","badge_id":94,"link":"http://example.stackexchange.com/badges/94/pundit","description":"Left 10 comments with a score of 5 or more","name":"Pundit"}

Tag Badge

{"badge_type":"tag_based","award_count":20,"rank":"bronze","badge_id":450,"link":"http://example.stackexchange.com/badges/450/xna","description":"Earned 100 upvotes for at least 20 answers in the xna tag","name":"xna"}

Awarded Badge

{"user":{"reputation":9001,"user_id":1,"user_type":"registered","accept_rate":100,"profile_image":"https://www.gravatar.com/avatar/a007be5a61f6aa8f3e85ae2fc18dd66e?d=identicon&r=PG","display_name":"Example User","link":"http://example.stackexchange.com/users/1/example-user"},"badge_type":"named","award_count":2000,"rank":"silver","badge_id":94,"link":"http://example.stackexchange.com/badges/94/pundit","description":"Left 10 comments with a score of 5 or more","name":"Pundit"}

Methods That Return This Type