Overview
Returns the authenticated user’s profile, their associated business (workspace), whether onboarding is complete, and their role within the business. Use this endpoint to bootstrap your application after login.
Request
Method : GET
URL : /api/v1/auth/me
Header Value Authorization Bearer
No request body is required.
Response
The authenticated user’s profile. Unique identifier for the user.
The user’s email address.
Whether the user’s email has been verified.
Whether this account was created via Google OAuth.
URL of the user’s avatar image, or null if not set.
The business (workspace) associated with this user. null if onboarding is not complete. Unique identifier for the business.
The business website URL.
The business’s support goal.
The team size descriptor (e.g. "1-10").
Timestamp when the business was created.
true if the user has completed onboarding (i.e. a business record exists).
The user’s role within the business. One of "owner", "admin", "agent", or null if no business is associated.
Example
curl https://api.pingback.live/api/v1/auth/me \
-H "Authorization: Bearer YOUR_TOKEN"
const response = await fetch ( 'https://api.pingback.live/api/v1/auth/me' , {
headers: {
'Authorization' : `Bearer ${ token } ` ,
},
});
const data = await response . json ();
Response example
{
"user" : {
"id" : "a1b2c3d4-e5f6-7890-abcd-ef1234567890" ,
"email" : "jane@example.com" ,
"full_name" : "Jane Smith" ,
"is_verified" : true ,
"is_google_account" : false ,
"avatar_url" : null
},
"business" : {
"id" : "b2c3d4e5-f6a7-8901-bcde-f12345678901" ,
"name" : "Acme Support" ,
"website" : "https://acme.com" ,
"goal" : "Reduce response time" ,
"industry" : "SaaS" ,
"team_size" : "1-10" ,
"created_at" : "2024-01-15T10:30:00Z"
},
"onboarding_complete" : true ,
"team_role" : "owner"
}
Errors
Status Meaning 401 Unauthorized — missing or invalid Bearer token