Managing Service Documentation

1. Documenting REST APIs

ElementDetail
OpenAPI 3.1Machine-readable spec
ExamplesPer operation; req + resp
ErrorsRFC 9457 schema
UISwagger UI / Redoc / Stoplight

2. Documenting GraphQL APIs

ElementDetail
SDL commentsSchema as docs
IntrospectionPowers explorers
ToolsGraphiQL, Apollo Studio, GraphQL Voyager

3. Documenting gRPC APIs

ElementDetail
.proto commentsSource of truth
Generatorsprotoc-gen-doc, Buf
Buf Schema RegistryVersioned schemas

4. Creating Architecture Diagrams

NotationDetail
C4Context → Container → Component → Code
Diagrams-as-codeMermaid, PlantUML, Structurizr, D2
LiveAuto-render from traces / mesh

5. Documenting Service Contracts

TypeDetail
API contractOpenAPI / proto
Event contractAsyncAPI / Avro / proto
SLALatency, availability targets

6. Maintaining API Changelog

SectionDetail
AddedNew endpoints/fields
ChangedBehavior changes
DeprecatedSunset date
RemovedBreaking
FixedBug fixes

7. Documenting Configuration

ElementDetail
Each varName, default, range, owner
Per envdev / stage / prod
SecretsReference, not value

8. Creating Runbooks

SectionDetail
SymptomsWhat you see
DiagnosisQueries, dashboards
MitigationStep-by-step
EscalationWho to page
Link from alertDirect URL in payload

9. Documenting Error Codes

FieldExample
CodeORDER_OUT_OF_STOCK
HTTP409
CauseInventory below requested qty
RemedyReduce qty or wait restock

10. Maintaining Developer Guides

DocDetail
Quickstart5-min hello world
How-toTask-oriented
ReferenceGenerated from spec
ConceptsMental model
FrameworkDiátaxis

11. Using API Documentation Tools

ToolUse
Swagger UI / RedocOpenAPI
StoplightDesign + docs
Mintlify / Bump.sh / ReadMeHosted
Backstage TechDocsMarkdown next to code

12. Implementing Interactive Documentation

FeatureDetail
Try-it consoleReal calls from docs
Code samplesAuto-generated per language
Auth widgetBearer token in browser
SDK downloadGenerated from spec