Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
28 commits
Select commit Hold shift + click to select a range
d228655
Disable false-positive machine
b-long Jun 11, 2025
dd072fc
Run 'npm add docusaurus-plugin-openapi-docs docusaurus-theme-openapi-…
b-long Jun 11, 2025
0388399
Vendor spec files
b-long Jun 11, 2025
25e18af
Vendor spec files (samples)
b-long Jun 11, 2025
a00df29
Add generated files to .gitignore
b-long Jun 11, 2025
2a6ce91
Add 'npm run' commands
b-long Jun 11, 2025
abee6bd
Initial 'docusaurus-plugin-openapi-docs' code
b-long Jun 11, 2025
cf0745d
Cleanup / simplify code
b-long Jun 11, 2025
8467eee
Cleanup
b-long Jun 11, 2025
a52efbf
[MANUAL REVERT] onBrokenLinks: "throw"
b-long Jun 11, 2025
09ad3e6
Sort languages, rename file
b-long Jun 11, 2025
86ccfa4
Address copilot code review
b-long Jun 11, 2025
71c3985
Fix copilot review: use string literal
b-long Jun 11, 2025
49181a9
Clarify commented languages
b-long Jun 11, 2025
18cbaf5
Conditionally build, using BUILD_OPENAPI_SAMPLES env var
b-long Jun 11, 2025
22785c3
Revert "Disable false-positive machine"
b-long Jun 11, 2025
d01867c
Remove vendored swagger (JSON)
b-long Jun 11, 2025
46f2799
Add 'entityresolution_v2'
b-long Jun 12, 2025
64f8283
Remove unused import
b-long Jun 12, 2025
e56e95a
Disable false-positive machine
b-long Jun 11, 2025
41a8431
Allow users to specify OpenAPI URL
b-long Jun 12, 2025
ad459c9
Merge branch 'main' into chore/add-docusaurus-openapi-docs
b-long Jun 12, 2025
8e4f65c
Merge branch 'main' into chore/add-docusaurus-openapi-docs
b-long Jun 12, 2025
aa8d241
format api sidebards and remove unused sections (#115)
cassandrabailey293 Jun 12, 2025
2511d9e
Add 'npm run postbuild' process
b-long Jun 12, 2025
ea8140d
move intro removal into docusaurus config (#116)
cassandrabailey293 Jun 13, 2025
5f45934
Package 'glob' unused since ea8140d
b-long Jun 13, 2025
759dbab
Cleanup
b-long Jun 13, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/vale.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ name: Vale
on:
pull_request:
branches:
- main
- disabled

jobs:
vale-check:
Expand Down
4 changes: 4 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
specs-processed/
docs/SDK-OpenAPI/
Comment thread
b-long marked this conversation as resolved.
docs/SDK-Samples/

# Dependencies
/node_modules

Expand Down
15 changes: 14 additions & 1 deletion docusaurus.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@ import type { Config } from "@docusaurus/types";
import type * as Preset from "@docusaurus/preset-classic";
import matter from "gray-matter";
import listRemote from "./docusaurus-lib-list-remote";
import { openApiSpecs } from "./preprocessing";
import languageTabs from "./openapi-generated-clients";

const otdfctl = listRemote.createRepo("opentdf", "otdfctl", "main");

Expand Down Expand Up @@ -46,10 +48,11 @@ const config: Config = {

onBrokenLinks: "throw",
onBrokenMarkdownLinks: "warn",
onBrokenAnchors: "warn",
markdown: {
mermaid: true,
},
themes: ["@docusaurus/theme-mermaid", "docusaurus-theme-github-codeblock"],
themes: ["@docusaurus/theme-mermaid", "docusaurus-theme-github-codeblock", "docusaurus-theme-openapi-docs"],

// Even if you don't use internationalization, you can use this field to set
// useful metadata like html lang. For example, if your site is Chinese, you
Expand All @@ -67,6 +70,7 @@ const config: Config = {
docs: {
routeBasePath: "/",
sidebarPath: "./sidebars.js",
docItemComponent: "@theme/ApiItem", // Derived from docusaurus-theme-openapi
// Please change this to your repo.
// Remove this to remove the "edit this page" links.
// editUrl:
Expand Down Expand Up @@ -192,6 +196,7 @@ const config: Config = {
// template: '#zoom-template',
// },
},
languageTabs: languageTabs,
} satisfies Preset.ThemeConfig,
plugins: [
[
Expand Down Expand Up @@ -735,6 +740,14 @@ ${updatedContent}`,
},
},
],
[
"docusaurus-plugin-openapi-docs",
{
id: "api", // plugin id
docsPluginId: "classic", // configured for preset-classic
config: openApiSpecs
},
],
require.resolve("docusaurus-lunr-search"),
],
};
Expand Down
102 changes: 102 additions & 0 deletions openapi-generated-clients.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,102 @@
/**
* This file defines language tabs configuration for OpenAPI documentation
*
* TODO: Note that the languages commented below have been removed, since we offer
* official SDKs for them, and we don't want to duplicate code or cause confusion.
*/
const languageTabs = [
// {
// highlight: "go",
// language: "go",
// logoClass: "go",
// },
// {
// highlight: "javascript",
// language: "nodejs",
// logoClass: "nodejs",
// },
// {
// highlight: "java",
// language: "java",
// logoClass: "java",
// variant: "unirest",
// },
// {
// highlight: "javascript",
// language: "javascript",
// logoClass: "javascript",
// },
{
highlight: "bash",
language: "curl",
logoClass: "curl",
},
{
highlight: "csharp",
language: "csharp",
logoClass: "csharp",
},
{
highlight: "ruby",
language: "ruby",
logoClass: "ruby",
},
{
highlight: "php",
language: "php",
logoClass: "php",
},
{
highlight: "powershell",
language: "powershell",
logoClass: "powershell",
},
{
highlight: "dart",
language: "dart",
logoClass: "dart",
},
{
highlight: "c",
language: "c",
logoClass: "c",
},
{
highlight: "objective-c",
language: "objective-c",
logoClass: "objective-c",
},
{
highlight: "ocaml",
language: "ocaml",
logoClass: "ocaml",
},
{
highlight: "r",
language: "r",
logoClass: "r",
},
{
highlight: "swift",
language: "swift",
logoClass: "swift",
},
{
highlight: "kotlin",
language: "kotlin",
logoClass: "kotlin",
},
{
highlight: "rust",
language: "rust",
logoClass: "rust",
},
{
highlight: "python",
language: "python",
logoClass: "python",
},
];

// export it
export default languageTabs;
Loading