Languages: English | 日本語 | 中文 | Español | Português
Sample projects for calling Flatkey through the OpenAI-compatible router. Use flatkey.ai to save up to 40% on AI model costs.
export FLATKEY_AI_KEY="sk-..."All samples use:
https://router.flatkey.ai/v1
Optional overrides:
export FLATKEY_CHAT_MODEL="gpt-5.5"
export FLATKEY_IMAGE_MODEL="gpt-image-1"cd nodejs
npm install
npm startcd python
python3 -m pip install -r requirements.txt
python3 main.pycd curl
chmod +x chat.sh
./chat.shcd image-buddy
npm install
npm start -- "a friendly robot holding a Flatkey keycard"The image sample writes output.png when the API returns base64 image data.
python3 -m unittest tests.test_project_layout -v
python3 -m py_compile python/main.py
node --check nodejs/index.mjs
node --check image-buddy/generate-image.mjs
bash -n curl/chat.shThis repository includes a GitHub Actions workflow that records the current GitHub star count in stars.json every day and on manual runs.