Skip to content
Back to skills

601 Model Information Api 46c2efb8

ASecurity

```python def get_model_info(model_id): response = requests.get( "https://openrouter.ai/api/v1/models", headers={"Authorization": f"Bearer {api_key}"} ) models = response.json()["data"] return next((m for m in models if m["id"] == model_id), None)

  • 9 stars
  • 0 votes
  • 0 copies
  • 0 views
  • Added October 11, 2026
ai-agentspythonapi

Works with

  • api

Security analysis

A100/100

Pro scans all 2 files and shows the line behind each finding

Scanned October 11, 2026

npx -y skills add tools-only/X-Skills --skill 601-model-information-api_46c2efb8 --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of 601 Model Information Api 46c2efb8?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for 601 Model Information Api 46c2efb8
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/tools-only-601-model-information-api-46c2efb8/badge)](https://www.skillsdirectory.com/skills/tools-only-601-model-information-api-46c2efb8)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
# Model Information Api

## Model Information API

### Get Model Details
```python
def get_model_info(model_id):
    response = requests.get(
        "https://openrouter.ai/api/v1/models",
        headers={"Authorization": f"Bearer {api_key}"}
    )
    models = response.json()["data"]
    return next((m for m in models if m["id"] == model_id), None)

model = get_model_info("anthropic/claude-3.5-sonnet")
print(f"Context: {model['context_length']}")
print(f"Prompt cost: ${model['pricing']['prompt']}/token")
print(f"Completion cost: ${model['pricing']['completion']}/token")
```

### Model Schema
```json
{
  "id": "anthropic/claude-3.5-sonnet",
  "name": "Claude 3.5 Sonnet",
  "description": "...",
  "context_length": 200000,
  "pricing": {
    "prompt": "0.000003",
    "completion": "0.000015"
  },
  "top_provider": {
    "context_length": 200000,
    "max_completion_tokens": 8192
  },
  "per_request_limits": null
}
```

Files in this skill

  • README.md1.3 KB
  • skill.md931 B

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.