Create comprehensive OpenAPI 3.1 specifications for REST APIs using design-first, code-first, or hybrid approaches. Includes templates, validation patterns, and SDK generation guidance.
تنزيل ZIP المهارة
رفع في Claude
اذهب إلى Settings → Capabilities → Skills → Upload skill
فعّل وابدأ الاستخدام
اختبرها
استخدام "openapi-spec-generation". Create an OpenAPI 3.1 spec for a users API
النتيجة المتوقعة:
A complete OpenAPI specification with /users endpoint (GET, POST), /users/{id} endpoint (GET, PATCH, DELETE), User schema with uuid, email, name, status, role fields, Bearer authentication, pagination parameters, and standard error responses.
استخدام "openapi-spec-generation". Add rate limiting headers to responses
النتيجة المتوقعة:
Updated spec with RateLimited response including Retry-After, X-RateLimit-Limit, and X-RateLimit-Remaining headers with integer schemas.
استخدام "openapi-spec-generation". Generate TypeScript client from spec
النتيجة المتوقعة:
TypeScript fetch client with typed methods for each endpoint, proper authentication headers, and TypeScript interfaces matching the schema.
التدقيق الأمني
آمنThis skill provides instructional documentation for OpenAPI specification generation. All static findings are false positives: shell command examples are documentation samples, hardcoded URLs are example domains (example.com, localhost), JWT references are standard API authentication definitions, and there is no malicious code execution. The skill is safe for marketplace publication.
مشكلات متوسطة المخاطر (1)
مشكلات منخفضة المخاطر (2)
درجة الجودة
ماذا يمكنك بناءه
New API Design
Create OpenAPI specs for new APIs using design-first approach with comprehensive examples for authentication, pagination, and error handling.
Existing API Documentation
Generate documentation from existing codebases using FastAPI or Express with tsoa annotations.
SDK Generation Workflow
Generate client SDKs in multiple languages from OpenAPI specs for frontend and external consumers.
جرّب هذه الموجهات
Create an OpenAPI 3.1 specification for a [RESOURCE] API with CRUD operations. Include authentication via Bearer token, pagination support, and standard error responses.
Add JWT Bearer authentication and API key security schemes to an existing OpenAPI spec. Include 401 and 403 error responses.
Generate a Python client SDK from this OpenAPI specification. Include authentication handling and proper error types.
Create Spectral linting rules for this OpenAPI spec that enforce operation IDs, require descriptions, and validate security definitions.
أفضل الممارسات
- Use $ref to reuse schemas, parameters, and responses across the spec
- Include real-world examples in the spec to help API consumers
- Define all possible error codes and include descriptive messages
- Version your API in the URL path and use semantic versioning for spec changes
تجنب
- Avoid generic descriptions like 'Gets a resource' - be specific about what is returned
- Do not skip security definitions - every endpoint should have authentication documented
- Do not mix naming conventions - stay consistent with camelCase or snake_case throughout
الأسئلة المتكررة
What is the difference between design-first and code-first?
Which languages are supported for code-first generation?
How do I validate my OpenAPI spec?
Can this skill generate server code?
What authentication schemes are supported?
How do I version my API spec?
تفاصيل المطور
المؤلف
sickn33الترخيص
MIT
المستودع
https://github.com/sickn33/antigravity-awesome-skills/tree/main/skills/openapi-spec-generationمرجع
main
بنية الملفات