Skip to content

Position Creation

Authenticated user defines a job position used when scheduling interviews.

Sequence

sequenceDiagram
  autonumber
  participant Web as Web client
  participant API as Hono API
  participant Auth as requireAuth
  participant Svc as position.service
  participant Repo as position.repo
  participant Mongo as MongoDB

  Web->>API: POST /v1/positions + Bearer
  API->>Auth: validate Firebase + org scope
  API->>Svc: createPosition(orgId, userId, input)
  Svc->>Svc: validate skills vs duration
  Svc->>Repo: createPosition
  Repo->>Mongo: insert Position
  Svc-->>Web: 201 position + interviewCount 0

Steps

  1. Authenticated user submits position details (title, skills, duration, etc.).
  2. Service validates skill count against interview duration limits.
  3. Position is stored scoped to the organization with creator reference.
  4. Active positions can be used when scheduling interviews.

Sophia AI Interview Platform — Internal Documentation