File size: 2,275 Bytes
523f8c1
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
3b4e9a4
523f8c1
 
 
 
 
 
 
3b4e9a4
523f8c1
 
 
 
 
 
 
 
 
3b4e9a4
523f8c1
 
 
 
3b4e9a4
 
 
523f8c1
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
---
license: mit
task_categories:
  - other
tags:
  - openai
  - api
  - gateway
  - modelflare
  - curl
  - examples
pretty_name: Modelflare API Examples
size_categories:
  - n<1K
---

# Modelflare API Examples

Small, documentation-oriented request sketches for the [Modelflare](https://modelflare.dev/?utm_source=huggingface&utm_medium=dataset&utm_campaign=api_examples) AI API gateway.


## Files

| File | Description |
| --- | --- |
| `data/chat_completions_examples.jsonl` | Chat, models, Responses, image, and video request JSON lines (placeholder key only) |
| `data/endpoint_map.json` | API family → path map from [endpoints guide](https://docs.modelflare.dev/guides/endpoints/) |

## Base URL

- OpenAI-compatible: `https://modelflare.dev/v1`
- Anthropic / Claude Code: `ANTHROPIC_BASE_URL=https://modelflare.dev` (**not** `/v1`)
- Gemini CLI: `GOOGLE_GEMINI_BASE_URL=https://modelflare.dev`
- Gemini native image: `POST /v1/models/{model}:generateContent` (Gemini CLI builds the same path under `/v1beta`, served only on `modelflare.dev`)

Auth: `Authorization: Bearer YOUR_MODELFLARE_API_KEY` (omit or placeholder in this dataset — **never** commit real keys).

## Related Hub content

- [Modelflare/start](https://huggingface.co/spaces/Modelflare/start)
- [Modelflare/api-recipes](https://huggingface.co/spaces/Modelflare/api-recipes)
- [Modelflare/coding-agents](https://huggingface.co/spaces/Modelflare/coding-agents)
- [Modelflare/openai-sdk](https://huggingface.co/spaces/Modelflare/openai-sdk)
- Blog: [Modelflare/blog](https://huggingface.co/spaces/Modelflare/blog)
- Collection: [modelflare-getting-started](https://huggingface.co/collections/Modelflare/modelflare-getting-started)

## Notes

- Example chat model ID in snippets: `gpt-5.6-sol`, the model used in the Modelflare Quickstart (it must be enabled on your group).
- Image and video fields vary by model; see the model pages. Use a Smart API Key or a `media` group key for media.
- The streaming line follows the OpenAI SDK `stream=True` pattern; the docs do not include a separate streaming example. Anthropic Messages are documented through Claude Code settings only, so no raw Anthropic request is included.
- No prices or benchmarks in this dataset; check the console for live pricing.