スキル一覧に戻る
matdac12

openai-api

by matdac12

Complete OpenAI skill from official documentation

1🍴 0📅 2025年10月18日
GitHubで見るManusで実行

SKILL.md


name: openai-api description: The OpenAI REST API. Please see https://platform.openai.com/docs/api-reference for more details.

Openai Api Skill

Comprehensive assistance with the OpenAI API, generated from the official OpenAPI specification.

When to Use This Skill

This skill should be triggered when:

  • Working with OpenAI API endpoints
  • Implementing OpenAI API integrations
  • Debugging OpenAI API calls
  • Understanding OpenAI API authentication and permissions
  • Building applications that use OpenAI services
  • Managing OpenAI resources like assistants, threads, files, etc.

Quick Reference

Authentication

All OpenAI API requests require authentication using an API key in the Authorization header.

Authorization: Bearer $OPENAI_API_KEY

Base URL

https://api.openai.com/v1

Common Headers

Content-Type: application/json
Authorization: Bearer YOUR_API_KEY
OpenAI-Beta: assistants=v2  # For beta endpoints

Example: List Models

curl https://api.openai.com/v1/models \
  -H "Authorization: Bearer $OPENAI_API_KEY"

Example: Create Chat Completion

from openai import OpenAI

client = OpenAI(api_key="your-api-key")
response = client.chat.completions.create(
    model="gpt-4",
    messages=[{"role": "user", "content": "Hello!"}]
)

Reference Files

This skill includes comprehensive API documentation organized by functionality:

  • assistants.md - Assistants
  • audio.md - Audio
  • audit_logs.md - Audit Logs
  • batch.md - Batch
  • certificates.md - Certificates
  • chat.md - Chat
  • completions.md - Completions
  • conversations.md - Conversations
  • embeddings.md - Embeddings
  • evals.md - Evals
  • files.md - Files
  • fine_tuning.md - Fine-tuning
  • general.md - General
  • images.md - Images
  • invites.md - Invites
  • models.md - Models
  • moderations.md - Moderations
  • projects.md - Projects
  • realtime.md - Realtime
  • responses.md - Responses
  • uploads.md - Uploads
  • usage.md - Usage
  • users.md - Users
  • vector_stores.md - Vector stores
  • videos.md - Videos

Use view to read specific reference files when detailed information is needed.

Working with This Skill

For Beginners

Start with basic endpoints like listing models or creating simple chat completions. Review authentication requirements first.

For Specific Features

Use the appropriate category reference file (Chat, Assistants, Audio, etc.) for detailed endpoint information.

For Integration Development

Reference files contain complete endpoint details including:

  • Request/response formats
  • Required permissions
  • Query parameters
  • Code examples in Python, curl, and Node.js

API Best Practices

  1. Rate Limiting: OpenAI enforces rate limits. Implement exponential backoff for retries.
  2. Error Handling: Handle 400, 401, 429, and 500 status codes appropriately.
  3. API Versions: Use the latest stable API version when possible.
  4. Security: Never expose API keys in client-side code or public repositories.
  5. Cost Management: Monitor token usage and set appropriate limits.

Resources

references/

Organized API documentation by functional area. Each file contains:

  • Complete endpoint specifications
  • Request/response examples
  • Authentication requirements
  • Parameter documentation
  • Code examples

scripts/

Add helper scripts here for common automation tasks.

assets/

Add templates, example requests, or integration boilerplates here.

Notes

  • This skill was generated from the official OpenAI API OpenAPI specification
  • Examples include Python, curl, and Node.js implementations
  • API keys should be stored securely, never committed to code

スコア

総合スコア

40/100

リポジトリの品質指標に基づく評価

SKILL.md

SKILL.mdファイルが含まれている

+20
LICENSE

ライセンスが設定されている

0/10
説明文

100文字以上の説明がある

0/10
人気

GitHub Stars 100以上

0/15
最近の活動

3ヶ月以内に更新がある

0/10
フォーク

10回以上フォークされている

0/5
Issue管理

オープンIssueが50未満

+5
言語

プログラミング言語が設定されている

0/5
タグ

1つ以上のタグが設定されている

0/5

レビュー

💬

レビュー機能は近日公開予定です