import Whop from '@whop/sdk';
const client = new Whop({
apiKey: process.env['WHOP_API_KEY'], // This is the default and can be omitted
});
const authorizedUser = await client.authorizedUsers.retrieve('ausr_xxxxxxxxxxxxx');
console.log(authorizedUser.id);{
"id": "ausr_xxxxxxxxxxxxx",
"role": "owner",
"user": {
"id": "user_xxxxxxxxxxxxx",
"name": "John Doe",
"username": "johndoe42",
"email": "john.doe@example.com"
},
"company": {
"id": "biz_xxxxxxxxxxxxxx",
"title": "Pickaxe"
}
}Retrieves the details of an existing authorized user.
Required permissions:
company:authorized_user:readmember:email:readimport Whop from '@whop/sdk';
const client = new Whop({
apiKey: process.env['WHOP_API_KEY'], // This is the default and can be omitted
});
const authorizedUser = await client.authorizedUsers.retrieve('ausr_xxxxxxxxxxxxx');
console.log(authorizedUser.id);{
"id": "ausr_xxxxxxxxxxxxx",
"role": "owner",
"user": {
"id": "user_xxxxxxxxxxxxx",
"name": "John Doe",
"username": "johndoe42",
"email": "john.doe@example.com"
},
"company": {
"id": "biz_xxxxxxxxxxxxxx",
"title": "Pickaxe"
}
}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 ***************************
The unique identifier of the authorized user to retrieve.
"ausr_xxxxxxxxxxxxx"
A successful response
A user who has been granted administrative access to manage a company's dashboard and settings.
The unique identifier for the authorized user.
"ausr_xxxxxxxxxxxxx"
The permission role assigned to this authorized user within the company.
owner, admin, sales_manager, moderator, app_manager, support, manager, custom The user account linked to this authorized user record.
Show child attributes
The company this authorized user has access to.
Show child attributes
Was this page helpful?