API Documentation Writer

PRO
Intermediate 10 min Verified 4.8/5

Generate comprehensive API documentation from code or specifications. OpenAPI, REST, GraphQL with examples and error handling.

Write API documentation that developers love. Clear endpoints, examples, error handling—everything needed to integrate quickly.

Example Usage

Review my Python function that processes user data and suggest improvements for better error handling and performance.
Skill Prompt

Pro Skill

Unlock this skill and 944+ more with Pro

This skill works best when copied from findskill.ai — it includes variables and formatting that may not transfer correctly elsewhere.

How to Use This Skill

1

Copy the skill using the button above

2

Paste into your AI assistant (Claude, ChatGPT, etc.)

3

Fill in your inputs below (optional) and copy to include with your prompt

4

Send and start chatting with your AI

Suggested Customization

DescriptionDefaultYour Value
Type of APIrest
Output formatmarkdown
Programming language I'm usingPython

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:

ParameterTypeRequiredDescription
limitintegerNoMax results (default: 20, max: 100)
offsetintegerNoPagination offset
sortstringNoSort 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:

FieldTypeRequiredDescription
namestringYesResource name
configobjectNoConfiguration 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 CodeError CodeDescription
400VALIDATION_ERRORInvalid request data
401UNAUTHORIZEDMissing or invalid API key
403FORBIDDENInsufficient permissions
404NOT_FOUNDResource not found
429RATE_LIMITEDToo many requests
500SERVER_ERRORInternal server error

Rate Limiting

PlanRequests/minBurst
Free6010
Pro600100
EnterpriseCustomCustom

Rate limit headers:

  • X-RateLimit-Limit: Max requests
  • X-RateLimit-Remaining: Remaining requests
  • X-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.created
  • resource.updated
  • resource.deleted

Payload Format

{
  "event": "resource.created",
  "timestamp": "2024-01-15T10:35:00Z",
  "data": {
    "id": "res_456",
    "name": "New Resource"
  }
}

Changelog

VersionDateChanges
v1.2.02024-01-15Added webhooks support
v1.1.02024-01-01New rate limits
v1.0.02023-12-01Initial 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

## What You'll Get

- Complete API reference
- Request/response examples
- Error handling guide
- Authentication details
- SDK code examples