API Documentation राइटर
PROCode या specifications से comprehensive API documentation generate करो। OpenAPI, REST, GraphQL - examples और error handling के साथ!
इस स्किल का उपयोग कैसे करें
स्किल कॉपी करें ऊपर के बटन का उपयोग करें
अपने AI असिस्टेंट में पेस्ट करें (Claude, ChatGPT, आदि)
नीचे अपनी जानकारी भरें (वैकल्पिक) और अपने प्रॉम्प्ट में शामिल करने के लिए कॉपी करें
भेजें और चैट शुरू करें अपने AI के साथ
सुझाया गया कस्टमाइज़ेशन
| विवरण | डिफ़ॉल्ट | आपका मान |
|---|---|---|
| Type of API | rest | |
| Output format | markdown | |
| Programming language I'm using | Python |
Authentication
[Auth Method]
Include your API key in the request header:
curl -H "Authorization: Bearer YOUR_API_KEY" \
https://api.example.com/v1/resource
Endpoints
[Resource Name]
List [Resources]
GET /resources
Description: [What this endpoint does]
Query Parameters:
| Parameter | Type | Required | Description |
|---|---|---|---|
limit | integer | No | Max results (default: 20, max: 100) |
offset | integer | No | Pagination offset |
sort | string | No | Sort field (e.g., created_at) |
Request Example:
curl -X GET "https://api.example.com/v1/resources?limit=10" \
-H "Authorization: Bearer YOUR_API_KEY"
Response (200 OK):
{
"data": [
{
"id": "res_123",
"name": "Example Resource",
"created_at": "2024-01-15T10:30:00Z"
}
],
"meta": {
"total": 100,
"limit": 10,
"offset": 0
}
}
Create [Resource]
POST /resources
Description: [What this endpoint does]
Request Body:
| Field | Type | Required | Description |
|---|---|---|---|
name | string | Yes | Resource name |
config | object | No | Configuration options |
Request Example:
curl -X POST "https://api.example.com/v1/resources" \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"name": "New Resource",
"config": {
"enabled": true
}
}'
Response (201 Created):
{
"data": {
"id": "res_456",
"name": "New Resource",
"config": {
"enabled": true
},
"created_at": "2024-01-15T10:35:00Z"
}
}
Error Handling
Error Response Format
{
"error": {
"code": "VALIDATION_ERROR",
"message": "The 'name' field is required",
"details": [
{
"field": "name",
"issue": "required"
}
]
}
}
Error Codes
| HTTP Code | Error Code | Description |
|---|---|---|
| 400 | VALIDATION_ERROR | Invalid request data |
| 401 | UNAUTHORIZED | Missing or invalid API key |
| 403 | FORBIDDEN | Insufficient permissions |
| 404 | NOT_FOUND | Resource not found |
| 429 | RATE_LIMITED | Too many requests |
| 500 | SERVER_ERROR | Internal server error |
Rate Limiting
| Plan | Requests/min | Burst |
|---|---|---|
| Free | 60 | 10 |
| Pro | 600 | 100 |
| Enterprise | Custom | Custom |
Rate limit headers:
X-RateLimit-Limit: Max requestsX-RateLimit-Remaining: Remaining requestsX-RateLimit-Reset: Reset timestamp
SDKs & Examples
JavaScript/Node.js
import { Client } from '@example/sdk';
const client = new Client('YOUR_API_KEY');
// List resources
const resources = await client.resources.list({ limit: 10 });
// Create resource
const newResource = await client.resources.create({
name: 'New Resource'
});
Python
from example import Client
client = Client(api_key="YOUR_API_KEY")
# List resources
resources = client.resources.list(limit=10)
# Create resource
new_resource = client.resources.create(name="New Resource")
Webhooks
Event Types
resource.createdresource.updatedresource.deleted
Payload Format
{
"event": "resource.created",
"timestamp": "2024-01-15T10:35:00Z",
"data": {
"id": "res_456",
"name": "New Resource"
}
}
Changelog
| Version | Date | Changes |
|---|---|---|
| v1.2.0 | 2024-01-15 | Added webhooks support |
| v1.1.0 | 2024-01-01 | New rate limits |
| v1.0.0 | 2023-12-01 | Initial release |
## What I Need
1. **API type**: REST, GraphQL, WebSocket?
2. **Endpoints/Operations**: What can users do?
3. **Authentication**: How do users authenticate?
4. **Data models**: Key objects and their fields?
5. **Code/Spec**: Existing code or OpenAPI spec?
6. **Audience**: Beginner or experienced developers?
Let's document your API!
---
## How to Use
1. Copy the skill above
2. Paste into your AI assistant
3. Share your API details or code
4. Get comprehensive documentation
## आपको क्या मिलेगा
- Complete API reference
- Request/response examples
- Error handling guide
- Authentication details
- SDK code examples