Stack Overflow

Get several Stack Overflow users

Get up to 100 Stack Overflow users in one call, by id.

GET/v1/stack-overflow/users/batch
x-api-keystringheader

API key (`sfk_...`)

Parameters
2
idsarrayrequiredquery

User ids, comma-separated, 1 to 100, e.g. `22656,1144035`. Duplicates are dropped. `-1` is the Community user.

sitestringoptionalquery

Stack Exchange site, by its API name (`askubuntu`, `serverfault`, `math`, `ru.stackoverflow`). Default: `stackoverflow`. The sites endpoint lists them all.

Response fields
49

Endpoint-specific response payload.

datasite
string

The Stack Exchange site the users belong to.

One entry per distinct requested id, in the order first asked. Duplicates are dropped.

datausers[]id
integer

The user id that was asked for.

datausers[]lookupStatus
string

Whether the item was found.

one of: found, not_found

The user when found; otherwise null.

datausers[]userid
integer

User id on this site.

datausers[]useraccountId
integernullable

Network-wide account id.

datausers[]username
stringnullable

Display name.

datausers[]userurl
stringnullable

Profile URL.

datausers[]userimageUrl
stringnullable

Avatar URL.

datausers[]usertype
stringnullable

Kind of account.

one of: registered, moderator, unregistered, does_not_exist, team_admin, null

datausers[]userreputation
integernullable

Reputation on this site.

Reputation gained over recent periods.

datausers[]userreputationChangeday
integernullable

Change today.

datausers[]userreputationChangeweek
integernullable

Change this week.

datausers[]userreputationChangemonth
integernullable

Change this month.

datausers[]userreputationChangequarter
integernullable

Change this quarter.

datausers[]userreputationChangeyear
integernullable

Change this year.

Badge counts.

datausers[]userbadgesgold
integernullable

Gold badges.

datausers[]userbadgessilver
integernullable

Silver badges.

datausers[]userbadgesbronze
integernullable

Bronze badges.

datausers[]useracceptRate
integernullable

Accept rate in percent; null when not shown.

datausers[]userlocation
stringnullable

The location the user chose to show; null when empty.

datausers[]userwebsiteUrl
stringnullable

The website the user chose to show; null when empty.

datausers[]useraboutHtml
stringnullable

The profile text the user wrote, as HTML; null when empty or not asked for.

datausers[]userjoinedAt
stringnullable

When the account joined this site, ISO 8601 UTC.

datausers[]userlastSeenAt
stringnullable

Last visit, ISO 8601 UTC.

datausers[]userlastModifiedAt
stringnullable

Last change to the profile, ISO 8601 UTC; null when not shown.

datausers[]userquestionCount
integernullable

Questions asked.

datausers[]useranswerCount
integernullable

Answers given.

datausers[]userprofileViews
integernullable

Profile views.

Votes the user has cast.

datausers[]uservotesCastup
integernullable

Upvotes cast.

datausers[]uservotesCastdown
integernullable

Downvotes cast.

datausers[]userisEmployee
booleannullable

Whether the user works for Stack Exchange.

Collectives the user belongs to.

datausers[]usercollectives[]slug
stringnullable

Collective slug.

datausers[]usercollectives[]name
stringnullable

Collective name.

datausers[]usercollectives[]url
stringnullable

Collective page.

datausers[]usercollectives[]description
stringnullable

What the collective is.

Tags the collective covers.

datausers[]usercollectives[]tags[]
stringoptional
datausers[]usercollectives[]role
stringnullable

The user's role in it, e.g. `member`.

Metadata describing the request and billing outcome.

metarequestId
string

Unique request identifier for tracing this API call.

min 1 chars

metacreditsCharged
integer

Credits charged for this request.

≥ 0

metaversion
string

Public API version that served the response.

one of: v1

Code example

curl "https://api.socialfetch.dev/v1/stack-overflow/users/batch?ids=22656,6309" \
  -H "x-api-key: YOUR_API_KEY"

Responses

User batch.