**Motivations:** - Align master with current codebase (token from projects/<id>/.secrets/<env>/ia_token) - Id resolution by mail To or by API token; no slug **Root causes:** - Token moved from conf.json to .secrets/<env>/ia_token; env from directory name **Correctifs:** - Server and scripts resolve project+env by scanning all projects and envs **Evolutions:** - tickets-fetch-inbox routes by To address; notary-ai agents and API doc updated **Pages affectées:** - ai_working_help/server.js, docs, project_config.py, lib/project_config.sh - projects/README.md, lecoffreio/docs/API.md, gitea-issues/tickets-fetch-inbox.py
ia_dev shared lib
project_config.sh
Sourced by deploy scripts and gitea-issues to resolve the current project id and the path to its JSON config.
Before sourcing: set PROJECT_ROOT (git repo root, where ai_project_id or .ia_project lives) and IA_DEV_ROOT (path to the ia_dev directory).
After sourcing: PROJECT_SLUG and PROJECT_CONFIG_PATH are set (and exported). Config path is projects/<id>/conf.json.
Project id resolution order: IA_PROJECT env → .ia_project at PROJECT_ROOT → ai_project_id at PROJECT_ROOT.
See projects/README.md for the config schema.