SyntaxStudy
Sign Up
REST API API Changelog and SDK Generation
REST API Beginner 1 min read

API Changelog and SDK Generation

An API changelog documents every change between versions in a structured format. Keep it in a CHANGELOG.md file following the Keep a Changelog convention, or expose it as a machine-readable /changelog endpoint. Clear changelogs reduce support burden by letting integrators quickly identify what broke their integration after a version upgrade. OpenAPI documents are the source of truth for SDK generation. Tools like openapi-generator and Fern read the spec and emit type-safe client libraries in dozens of languages. Generated SDKs eliminate hand-written HTTP plumbing and ensure the client always matches the server contract.
Example
# CHANGELOG.md (Keep a Changelog format)
# Unreleased
# Added
# - GET /products/{id}/reviews endpoint
# - `tags` field on Product response

# [2.1.0] - 2025-04-01
# Added
# - Cursor-based pagination: `cursor` and `limit` query params on all collections
# - `X-RateLimit-*` headers on all responses
# Changed
# - `perPage` max increased from 50 to 100

# [2.0.0] - 2025-01-15
# Breaking
# - Renamed `user_id` -> `userId` in all responses (camelCase migration)
# - POST /users now returns 201 instead of 200
# - Removed deprecated `GET /users/{id}/profile` (use `GET /users/{id}`)

# SDK generation with openapi-generator-cli
# npm install @openapitools/openapi-generator-cli -g
# openapi-generator-cli generate \
#   -i openapi.yaml \
#   -g typescript-axios \
#   -o ./sdk/typescript \
#   --additional-properties=npmName=@myco/api-sdk,npmVersion=2.1.0

# Generated TypeScript SDK usage:
# import { ProductsApi, Configuration } from '@myco/api-sdk';
# const api = new ProductsApi(new Configuration({
#   basePath: 'https://api.example.com/v1',
#   accessToken: token,
# }));
# const { data } = await api.listProducts({ status: 'active', perPage: 20 });