The Department object represents organizational departments used for access management and team organization. Departments provide an additional layer of structure within organizations.
id string required
Unique department identifier. Format: dep_ followed by 12 alphanumeric characters.
name string required
Department name (e.g., Engineering, Sales, Marketing).
description string | null optional
Detailed description of the department's purpose and responsibilities.
organization_id string required
Reference to the Organization this department belongs to.
created_by string | null optional
Reference to the User who created this department.
is_active boolean required
Whether the department is active and can be assigned to users. Default: true.
is_default boolean required
Whether this is a default department. Default departments are created automatically for new organizations. Default: false.
color string | null optional
Hex color code for UI display (e.g., #2196F3). Used for visual identification in dashboards and reports.
created_at string required
Timestamp when the department was created. Format: ISO 8601 datetime string.
updated_at string required
Timestamp when the department was last updated. Format: ISO 8601 datetime string.
is_deleted boolean required
Whether the department has been soft deleted. Soft deleted departments are not returned in API responses unless explicitly requested. Default: false.
New organizations are automatically created with five default departments:
- Engineering - Software development and technical teams
- Sales - Sales and business development teams
- Marketing - Marketing and communications teams
- Support - Customer support and success teams
- Operations - Operations and administrative teams
Departments enable:
- Team organization: Group users by function or team
- Access control: Restrict resources to specific departments
- Reporting: Generate department-specific reports and analytics
- Resource allocation: Assign budgets and resources per department
Users can belong to multiple departments via UserDepartment relationships.