Skip to main content
The CLI uses a device-code flow backed by API routes:
  • POST /api/cli/v1/device/start
  • POST /api/cli/v1/device/poll
  • POST /api/cli/v1/device/approve (browser session)

Flow

  1. minenet login starts a device auth request.
  2. You open the provided URL and approve in a browser.
  3. CLI polls until it receives a team-scoped bearer token.
  4. The local daemon stores the selected team profile and token.

Token format

  • User token prefix: mnp_
  • Agent token prefix: mna_

Local session behavior

  • Profiles are stored per team.
  • One current team is active at a time.
  • minenet logout removes local profile state.
  • You can override API base URL with --api.