Site name & login

Dashboard is public. Check "Require username + password" below, set an admin username and password (min 8 characters), and click Save login settings. After that, index.php and Stats will ask for sign-in, and you will see Log out in the top bar.

Customise the title in the top bar and browser tab. You can require an admin username and password for the dashboard, Stats, and this Settings page only — Order import settings are unchanged.

Leave empty to save the default name "Picker Performance".

Admin login (whole dashboard)

Uses login.php. First time: check the box, set admin username and password (min 8 characters). Leave password fields empty to keep the current password when you only change the username. Uncheck and save to turn login off (unless the server sets require_dashboard_login — then login stays mandatory).

If you leave this blank when saving with login on, the stored username is unchanged. If you enable login for the first time with only a password, the username defaults to admin.

Forgot password or locked out? In phpMyAdmin → table settings: delete rows for dashboard_password_hash, dashboard_login_enabled, and optionally dashboard_admin_username. Then open Settings again and set a new admin username and password.

Dashboard timezone

“Today”, date filters, stats ranges, and order clocks all use this zone. PHP and the stats API use it automatically. Default: Lebanon (Asia/Beirut).

Now in Asia/Beirut: 2026-04-19 22:34:31 EEST

Tip: use a value from the IANA list if you need a city not listed (save via database or add it here).

Daily order reset

After 1:00 AM each day in Asia/Beirut (your dashboard timezone), all rows in orders are deleted once. Pickers and Telegram settings are not touched. The dashboard and stats then show no orders until new ones arrive.

Turning on auto-reset or scheduling the cron URL will clear all orders the first time the condition is met after 1:00 AM. For 24/7 sites, use the cron URL every 10–15 minutes (Hostinger Advanced → Cron Jobs or cron-job.org); the script exits quickly when nothing is due.

When checked, the first request to the dashboard or stats API after 1:00 AM (dashboard timezone) deletes all orders. Use with or without the cron URL below.

Full URL = this value + your secret (no spaces). Example: curl -s "…cron_reset_dashboard.php?key=YOUR_SECRET"

Today’s dashboard (saved orders)

The dashboard reads the orders database table. New rows are added when your Telethon worker (or any client) POSTs valid order text to order_import.php. Use Fetch today’s snapshot to see how many orders are stored for today in your dashboard timezone, then Open dashboard to view charts.

Open dashboard (today)

Logo Settings

Current Logo

Favicon

Shown in the browser tab on Dashboard, Stats, Orders, Settings, and the login page. Use a square image or .ico for best results.

Orders (HTTP import)

Orders are stored when your Telethon worker (or any script) POSTs to order_import.php with the secret below. There is no Telegram Bot API webhook on this server.

Same order # in multiple groups: run database/migration_orders_telegram_chat_id.sql if needed. For legacy vs supergroup chat ids use database/migration_telegram_chat_ensure_and_normalize.sql.

Must match ORDER_IMPORT_API_KEY in tools/telethon_worker/.env. Leave empty to disable imports.

POST https://nkjnah.arvixi.net/public/api/order_import.php

Header: X-Api-Key or Authorization: Bearer. JSON body: {"message":"…order text…","telegram_chat_id":"-100…"}telegram_chat_id required if allowlist is ON.

Yes — this is the allowlist. It is not the “Preview — chat” dropdown below (that only filters the preview list).

  1. Click Add chat ID, type the numeric id (e.g. -1001234567890 — digits and a leading minus only).
  2. Click the purple button Save order import settings. You should see a green bar at the top of the page.
  3. Leave all rows empty and save to allow imports from any chat. If the worker gets HTTP 403, add the id it shows as post_as=….

MTProto (user account — optional)

For Telegram Client API (MTProto) with a user session you see the same chats as in the app — including messages from other bots in groups, which the Bot API often cannot forward to your bot. Create api_id / api_hash at my.telegram.org. This page only stores credentials in the database; receiving updates still requires a separate long-running process (e.g. PHP MadelineProto, Python Telethon/Pyrogram) that reads these settings and keeps a session file outside the web root.

Security: Treat api_hash like a password. Restrict database and backups access. The API hash field below is never shown after save — leave it blank to keep the stored value.

Optional in the database; your worker may prompt for the login code interactively once.

Worker heartbeat (Telethon on your PC/VPS)

The dashboard cannot open an MTProto connection by itself. Your Telethon worker sends order text to Order import API (ORDER_IMPORT_URL in tools/telethon_worker/.env) — same key as in the green box above. If allowlist is ON, use ORDER_IMPORT_TELEGRAM_CHAT_ID in the worker .env matching an allowed id. Separately, POST the ping URL below with the ping token so this page can show the worker is online.

Ping URL

Ping token (secret)

Not generated yet — click Save MTProto settings above.

Picker Management

Each user is a picker: a shortcut (code on orders), display name, and shift (AM / PM / both) for the dashboard filter.

Order lines use shortcuts like MH, RY on PROCESSING / CONFIRMED. Add every shortcut that appears in Telegram here — otherwise those orders may not appear in picker stats (you will still see a "Shortcuts not in Pickers list" row on the dashboard).

Add user

Edit user

Change shortcut, name, or shift. Pick someone below or click Edit in the table.

Shortcut User name Shift Actions