# Sign-in & account sessions

Sign in with assigned account details and keep platform support access separate from school accounts.

Category: Administration
Guide: https://avkul.in/docs/guides/module-auth/
Guided sample demo: https://avkul.in/docs/demo/module-auth/
Snapshot: 11 October 2026

## Features

- Account login
- Current profile
- Token refresh
- Logout
- Platform impersonation

## Access and setup

Intended access: Platform administrator
- An assigned school account with the required permissions.
- The academic, student or staff setup used by this workflow.


## Workflow

1. Open the ERP sign-in page.
2. Enter the assigned identifier and school code when required.
3. Use the workspace available to the signed-in role.
4. Log out when the session is finished.

## Fields and controls

- identifier (string, declared required)
- password (string, declared required)
- schoolCode (string, optional)
- tenantSlug (string, optional)
- deviceName (string, optional)
- refreshToken (string, optional)
- userId (string, declared required)
- reason (string, declared required)
- minutes (number, optional)
- sessionId (string, optional)

## Current limits

- Public guided demos do not issue ERP credentials. Impersonation is restricted to platform administrators and is audited.

## Actual application access

- https://avkul.in/en/saas/impersonation
- https://avkul.in/en/login
- https://avkul.in/en

## API reference

- POST /api/v1/auth/login — Login by email / phone / employee code / admission no; Public/capability access
- POST /api/v1/auth/refresh — Rotate a refresh token for a new token pair; Public/capability access
- POST /api/v1/auth/logout — Revoke the current session (or all sessions); Authenticated scope
- GET /api/v1/auth/me — Current user profile, roles and permissions; Authenticated scope
- POST /api/v1/auth/impersonate — Start acting as another user (platform admins only); Authenticated scope
- POST /api/v1/auth/impersonate/stop — End an impersonation session; Authenticated scope
- GET /api/v1/auth/impersonate/active — Open impersonation sessions (platform admins only); Authenticated scope
- POST /api/v1/auth/impersonate/close-lapsed — Close expired impersonation sessions (platform admins only); Authenticated scope
- GET /api/v1/auth/impersonate/history — Impersonation audit history (platform admins only); Authenticated scope

## Demo access

No login is required for the guided sample demo. Its fictional records and actions stay in this browser tab; they do not modify ERP records or send messages/payments. An assigned account is required for the actual ERP links.

Source inventory checked on 11 October 2026. This source inventory is not a certification of every external provider or device flow.
