Codync
免费开源的 1:1 Grok Bot 与 Muse 替代方案。可在 iPhone、Mac 或 Linux 桌面上将 Claude 代码、Codex、Cursor 以及 40 多个编码代理作为持久机器人使用。支持群组聊天、线程、应用。
AI 翻译
尚未收集仓库信息。
尚未检测到更新。GitHub 发布版本后会显示在这里。
The world's only 4:20 API — free, no key: where it's 4:20 right now, plus marijuana law status for 197 countries
翻译准备中
取自仓库 README
正在加载完整 README。
查看完整 README ↗The world's only 4:20 API. A free, read-only JSON API that tells you where in the world it's 4:20 right now — AM or PM — plus marijuana law status for 197 countries, each with a source.
No key, no signup, CORS open. The hosted API is rate-limited to 10 requests a second per IP.
curl https://api.420.menow.us/v1/now
fetch('https://api.420.menow.us/v1/now').then(r => r.json()).then(console.log)
import requests
now = requests.get('https://api.420.menow.us/v1/now').json()
print(now['next']['place'], 'in', now['next']['minutes_until_next_420'], 'minutes')
| Endpoint | What you get |
|---|---|
GET /v1/now | Zones at 4:20 right now, the closest, the next, seconds left in the minute |
GET /v1/zones | Every zone ranked by distance from 4:20 |
GET /v1/zones/{tzid} | One zone: its local time and distance from 4:20 |
GET /v1/zones/{tzid}/law | The local law card for one zone (e.g. America/Los_Angeles) |
GET /v1/zones/{tzid}/places | Places in that zone with their own law cards |
GET /v1/laws | Law status for every country |
GET /v1/laws/{ISO2} | One country (e.g. NL, TH, US) |
GET /v1/time | Server time, checked against the US Naval Observatory |
GET /v1/meta | Data date, tz database version, SQLite size and SHA-256 |
GET /v1/laws.sqlite | The whole law database as one SQLite file, for offline apps |
Status symbols: ✓ legal · ◐ decriminalized · ⚕ medical only · ⊘ illegal · ☠️ death sentences given.
Information and education only — not legal advice. Laws change; check official sources before you travel.
docker compose up --build
# → http://localhost:8000/
Or without Docker:
python3 -m venv .venv && . .venv/bin/activate
pip install -r requirements.txt
PYTHONTZPATH= DATA_DIR=data uvicorn main:app --app-dir app --port 8000
Time is computed from the pinned tzdata package (PYTHONTZPATH= in the Dockerfile), so results never depend on the host's zoneinfo. Half-hour and 45-minute offsets (Kathmandu is UTC+5:45) are handled.
app/main.py FastAPI app (all endpoints)
app/static/index.html the beginner tutorial served at /
data/ law + zone data the API reads (CC BY 4.0)
tools/cannabis-laws-export.py regenerates data/ from the MariaDB source database
The source of truth is a MariaDB database (countries, zones, places, sources, history). tools/cannabis-laws-export.py turns it into the JSON and SQLite files in data/. Set LAWS_DB_CMD to whatever command reaches your database.
Built by LIBCSystems LLC, Long Island, NY.