docs: update README and configuration documentation for clarity
All checks were successful
CI / lint-and-test (push) Successful in 19s

- Revised the README to improve clarity in instructions for accessing the calendar miniapp, including changes to the phrasing for consistency.
- Updated the configuration documentation to enhance the description of the `EXTERNAL_CALENDAR_ICS_URL` setting, ensuring users understand its purpose and usage.
- Improved the import format documentation by translating terms to English for better accessibility to a wider audience.
- Enhanced the runbook with clearer instructions regarding access issues when using direct links, emphasizing the importance of using the bot's menu button.
This commit is contained in:
2026-02-20 16:26:47 +03:00
parent 0ecbda67f9
commit 9486f7004d
4 changed files with 20 additions and 20 deletions

View File

@@ -15,7 +15,7 @@ All configuration is read from the environment (e.g. `.env` via python-dotenv).
| **MINI_APP_SKIP_AUTH** | `1`, `true`, or `yes` | *(unset)* | If set, `/api/duties` is allowed without Telegram initData (dev only; insecure). |
| **INIT_DATA_MAX_AGE_SECONDS** | integer | `0` | Reject Telegram initData older than this many seconds. `0` = disabled. Example: `86400` for 24 hours. |
| **CORS_ORIGINS** | comma-separated list | `*` | Allowed origins for CORS. Leave unset or set to `*` for allow-all. Example: `https://your-domain.com`. |
| **EXTERNAL_CALENDAR_ICS_URL** | string (URL) | *(empty)* | URL of a public ICS calendar (e.g. holidays). If set, those days are highlighted on the duty grid; users can tap «i» on a cell to see the event summary. Empty = no external calendar. |
| **EXTERNAL_CALENDAR_ICS_URL** | string (URL) | *(empty)* | URL of a public ICS calendar (e.g. holidays). If set, those days are highlighted on the duty grid; users can tap "i" on a cell to see the event summary. Empty = no external calendar. |
| **DUTY_DISPLAY_TZ** | string (timezone name) | `Europe/Moscow` | Timezone for the pinned duty message in groups. Example: `Europe/Moscow`, `UTC`. |
| **DEFAULT_LANGUAGE** | `en` or `ru` (normalized) | `en` | Default UI language when the user's Telegram language is unknown. Values starting with `ru` are normalized to `ru`, otherwise `en`. |

View File

@@ -21,9 +21,9 @@ The **duty-schedule** format is used by the `/import_duty_schedule` command. Onl
| Value | Meaning | Notes |
|-------|----------------|--------------------------|
| **в**, **В**, **б**, **Б** | Duty (дежурство) | Any of these four |
| **Н** | Unavailable (недоступен) | Exactly `Н` |
| **О** | Vacation (отпуск) | Exactly `О` |
| **в**, **В**, **б**, **Б** | Duty | Any of these four |
| **Н** | Unavailable | Exactly `Н` |
| **О** | Vacation | Exactly `О` |
| (empty/space/other) | No event | Ignored for import |
The number of days in the schedule is the maximum length of any `duty` string when split by `;`. If `duty` is empty or missing, it is treated as an empty list of cells.
@@ -38,7 +38,7 @@ The number of days in the schedule is the maximum length of any `duty` string wh
},
"schedule": [
{
"name": "Иванов Иван",
"name": "Ivanov Ivan",
"duty": ";;В;;;Н;;О;;В;;"
},
{

View File

@@ -49,7 +49,7 @@ On container start, `entrypoint.sh` runs Alembic migrations then starts the app
### Miniapp "Open in browser" or direct link — access denied
- **Cause:** When users open the calendar via “Open in browser” or a direct URL, Telegram may not send `tgWebAppData` (initData). The API requires initData (or `MINI_APP_SKIP_AUTH` / private IP in dev).
- **Action:** Users should open the calendar **via the bots menu button** (e.g. ⋮ → «Календарь») or a **Web App inline button** so Telegram sends user data.
- **Action:** Users should open the calendar **via the bots menu button** (e.g. ⋮ → "Calendar") or a **Web App inline button** so Telegram sends user data.
### 403 "Open from Telegram" / no initData