SuperAI Flow Platform

Sections

Theme switcher

Get user by ID

Retrieve detailed information for a specific user by their unique identifier.

This endpoint fetches complete user details including profile information, organization membership, role, and status. Use this to verify user existence, check user details before operations, or display user profiles.

Context: - Returns user from any organization (admin has global access) - Includes organization_id but NOT organization_name (use with-org endpoint for that) - User ID must be a valid UUID - Returns user regardless of active/inactive status - Response includes audit timestamps

Behavior: 1. Validates user_id is valid UUID format 2. Queries database for user by ID 3. Returns user if found 4. Raises 404 error if user does not exist Use Cases: - Verify user exists before performing operations - Display user profile in admin interface - Validate user ID from external systems - Check user status and role before permission changes - Retrieve user details for audit logs

Related Endpoints: - GET /admin/users/by-name/{name} - Search user by name instead of ID - GET /admin/users - List all users - GET /admin/organizations/{id}/users - List users in specific organization - DELETE /admin/users/{user_id} - Delete user

Header Parameters

Authorizationstring

Path Parameters

user_idstring Required

Unique identifier of the user to retrieve. Must be a valid UUID format.

Response

200
Object
User details retrieved successfully

Response Attributes

created_atstring Required

Timestamp when user was created. Format: ISO 8601 UTC (e.g., '2025-01-23T15:30:00Z').

emailstring Required

User's email address. Must be unique within organization. Used for login, authentication, and notifications. Synchronized with authentication system. Can be updated after user creation.

first_namestring Required

User's first name. Used in UI displays, emails, and user identification. Can be updated after user creation.

idstring Required

Unique identifier for the user. Format: UUID v4. Synchronized with authentication system user ID.

last_namestring Required

User's last name. Used in UI displays, emails, and user identification. Can be updated after user creation.

modified_bystring Required

Identifier of the user or system that last modified this user. Can be user UUID or system identifier (e.g., 'system', 'admin'). Used for audit trail and change attribution.

organization_idstring Required

UUID of the organization this user belongs to. Users are scoped to a single organization (no cross-org access). Organization must exist and determines user's data access scope.

rolestring Required

User's role within the organization. Determines permission level. Valid values: 'org_admin', 'backoffice', 'app_user', 'integration'.

Role permissions:

  • 'org_admin': Full organization access and user management
  • 'backoffice': Super admin with platform-level access
  • 'app_user': Regular user who can create and manage own flows and executions
  • 'integration': Service account for integrations and automated workflows
statusstring Required

User's current account status. Valid values: 'active', 'inactive'.

'active': User can log in and access the system. 'inactive': User cannot log in; account is disabled. Note: Even active users must accept email invitation to log in initially.

updated_atstring Required

Timestamp when user was last modified. Updated automatically on any field change. Format: ISO 8601 UTC (e.g., '2025-01-24T10:45:00Z'). Used for change tracking and audit logs.

400
Object
Invalid UUID format

Response Attributes

errorobject Required

Standard error detail structure.

This model matches the error format returned by the centralized exception handlers in app/api/errors/handlers.py.

Show child attributes

request_idnull
403
Object
Forbidden - Insufficient permissions to access this resource

Response Attributes

errorobject Required

Standard error detail structure.

This model matches the error format returned by the centralized exception handlers in app/api/errors/handlers.py.

Show child attributes

request_idnull
404
Object
User not found

Response Attributes

errorobject Required

Standard error detail structure.

This model matches the error format returned by the centralized exception handlers in app/api/errors/handlers.py.

Show child attributes

request_idnull
422
Object
Validation Error

Response Attributes

detailarray

Show child attributes

500
Object
Internal Server Error - An unexpected error occurred

Response Attributes

errorobject Required

Standard error detail structure.

This model matches the error format returned by the centralized exception handlers in app/api/errors/handlers.py.

Show child attributes

request_idnull
Was this section helpful?

What made this section unhelpful for you?

GET

/

Select
1

Response

Was this section helpful?

What made this section unhelpful for you?

View as Markdown

Ask an AI

Open in ChatGPTOpen in ClaudeOpen in Perplexity

Code with AI

Open in Copilot