TE
TechEcho
Home24h TopNewestBestAskShowJobs
GitHubTwitter
Home

TechEcho

A tech news platform built with Next.js, providing global tech news and discussions.

GitHubTwitter

Home

HomeNewestBestAskShowJobs

Resources

HackerNews APIOriginal HackerNewsNext.js

© 2025 TechEcho. All rights reserved.

Building API Docs

86 pointsby polyrandover 3 years ago

7 comments

ogazittover 3 years ago
Automating the generation of API docs from schema (swagger / openapi) seems as important as any GitOps practice in 2022. At Aserto, we use the readme.com github actions to automatically update our API docs (aserto.readme.io) any time a new OpenAPI spec is committed.
评论 #30254174 未加载
cplliover 3 years ago
I write the OpenAPI spec by hand as I haven’t found any tool to match my needs (nor is the API changing too often). And for the frontend to display the docs I couldn’t be any happier with <a href="https:&#x2F;&#x2F;stoplight.io&#x2F;" rel="nofollow">https:&#x2F;&#x2F;stoplight.io&#x2F;</a> (using their WebComponent for simplicity). I think I discovered this on the “APIs you won’t hate” podcast.
评论 #30255569 未加载
vrepsysover 3 years ago
Shameless plug: here&#x27;s my indie-project that converts an OpenAPI&#x2F;Swagger spec into something that aims to look like Stripe&#x27;s API Reference: <a href="https:&#x2F;&#x2F;portal.dev" rel="nofollow">https:&#x2F;&#x2F;portal.dev</a><p>Here are a couple of example docs: <a href="https:&#x2F;&#x2F;space-api.portaldocs.dev" rel="nofollow">https:&#x2F;&#x2F;space-api.portaldocs.dev</a> (and the OpenAPI behind it: <a href="https:&#x2F;&#x2F;github.com&#x2F;portaldev&#x2F;nasa-apod-api-docs&#x2F;blob&#x2F;main&#x2F;openapi.yaml" rel="nofollow">https:&#x2F;&#x2F;github.com&#x2F;portaldev&#x2F;nasa-apod-api-docs&#x2F;blob&#x2F;main&#x2F;op...</a>)<p><a href="https:&#x2F;&#x2F;recur-api-beta.portaldocs.dev" rel="nofollow">https:&#x2F;&#x2F;recur-api-beta.portaldocs.dev</a><p>At my previous workplace we&#x27;ve built the whole docs portal (including the API reference) as a custom static website with Contentful (a json CMS) underneath. It was a real pain in the ass to edit and maintain, that&#x27;s how I got the idea.
评论 #30257467 未加载
评论 #30257906 未加载
mythzover 3 years ago
Our approach for generating API docs is generating a default UI including all the metadata that can be inferred from Typed DTOs and further enhanced with custom DTO attributes:<p><a href="https:&#x2F;&#x2F;docs.servicestack.net&#x2F;api-explorer#api-customizations" rel="nofollow">https:&#x2F;&#x2F;docs.servicestack.net&#x2F;api-explorer#api-customization...</a><p>But also allow users to define their own custom HTML Components for each API to provide full control to be able to include their own rich interactive content for any of their Types:<p><a href="https:&#x2F;&#x2F;docs.servicestack.net&#x2F;api-explorer#api-docs" rel="nofollow">https:&#x2F;&#x2F;docs.servicestack.net&#x2F;api-explorer#api-docs</a><p>That for optimal UX all gets bundled together with all the App&#x27;s components into a single cached download.
arcbyteover 3 years ago
I&#x27;ve never found anything better than Enunciate. Works very well and it&#x27;s guaranteed always up to date because it&#x27;s a compile time artifact. I really like that all the documentation and code are in one place, next to each other, and have a higher chance of being true and up to date than any other method
评论 #30254151 未加载
mrlatinosover 3 years ago
Heroku&#x27;s API docs made my mobile browser freeze
faizshahover 3 years ago
Anyone tried rswag with rails? I’m trying it now.<p>I’m also considering schemathesis &amp; fastapi from python.