Skip to main content
GET
/
users
/
{id}
JavaScript
import Whop from '@whop/sdk';

const client = new Whop({
  apiKey: process.env['WHOP_API_KEY'], // This is the default and can be omitted
});

const user = await client.users.retrieve('user_xxxxxxxxxxxxx');

console.log(user.id);
{
  "id": "user_xxxxxxxxxxxxx",
  "username": "johndoe42",
  "name": "John Doe",
  "created_at": "2023-12-01T05:00:00.401Z",
  "bio": "building cool things on the internet",
  "profile_picture": {
    "url": "https://media.whop.com/abc123/optimized.jpg"
  }
}

Authorizations

Authorization
string
header
required

A company API key, company scoped JWT, app API key, or user OAuth token. You must prepend your key/token with the word 'Bearer', which will look like Bearer ***************************

Path Parameters

id
string
required

The unique identifier or username of the user.

Example:

"user_xxxxxxxxxxxxx"

Response

A successful response

A user account on Whop. Contains profile information, identity details, and social connections.

id
string
required

The unique identifier for the user.

Example:

"user_xxxxxxxxxxxxx"

username
string
required

The user's unique username shown on their public profile.

Example:

"johndoe42"

name
string | null
required

The user's display name shown on their public profile.

Example:

"John Doe"

created_at
string<date-time>
required

The datetime the user was created.

Example:

"2023-12-01T05:00:00.401Z"

bio
string | null
required

A short biography written by the user, displayed on their public profile.

Example:

"building cool things on the internet"

profile_picture
object
required

The user's profile picture attachment with URL, content type, and file metadata. Null if using a legacy profile picture.