Skip to main content

Internal team object with administrative details

_id
string
required

Unique identifier for the team (MongoDB ObjectId)

Example:

"65c1f68ea735b522d370ea27"

organizationId
string
required

Organization identifier that owns this team

Example:

"65c1f4eeca7c4816d94587b2"

name
string
required

Team name

Example:

"Jakarta Operations Team"

isActive
boolean
required

Whether team is currently active

Example:

true

description
string
hubId
string

Associated hub ID

Example:

"65c1f68ea735b522d370ea25"

members
object[]

Team members

leaderId
string

Team leader user ID

Example:

"65c1f68ea735b522d370ea28"

createdBy
string

Email of admin who created this team

Example:

"admin@mile.app"

createdTime
string<date-time>

ISO 8601 timestamp when team was created

Example:

"2024-01-20T09:00:00.000000Z"

updatedTime
string<date-time>

ISO 8601 timestamp when team was last updated

Example:

"2024-02-06T16:00:00.000000Z"

failedCode
enum<string>

Team Module business failedCode that indicate specific failure conditions or business rule violations during team module operations. These codes help identify the failed operation of team-related and provide standardized failure identification across the system.

Possible values:

  • team-032: Invalid state/condition - Team state invalid
  • team-033: Team not found - Team record does not exist
  • team-034: Team name already exists - Team name already used
  • team-035: Access forbidden - User lacks team permission
  • team-036: Cannot delete team that has users - Team has assigned members
  • team-045: Server failure - Internal server failure
Available options:
team-032,
team-033,
team-034,
team-035,
team-036,
team-045