Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
82 changes: 82 additions & 0 deletions .github/workflows/check-links.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,82 @@
name: Check Links

on:
# Run monday mornings
schedule:
- cron: '0 12 * * MON'
workflow_dispatch:
jobs:
check-links:
name: Check links
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
site:
- name: Fern Docs
url: "buildwithfern.com/learn"
steps:
- name: Install link checker
run: pip install linkchecker
- name: Create config
run: echo -e "[csv]\nseparator=,\n[filtering]\nignore=\n\texample.com\n\tus.i.posthog.com\n\tc.vialoops.com/CL0\n[output]\nignoreerrors=\n ^http ^403 Forbidden" > lcconfig
- name: Check ${{ matrix.site.name }} Links
run: |
set +e
cat lcconfig
linkchecker https://${{ matrix.site.url }} --check-extern --no-status --no-warnings --config lcconfig -F csv/utf-8/link_report.csv

if [ $? -ne 0 ]; then
echo "Bad links found. Please see report."
else
echo "Check completed. No issues found."
exit 0
fi

echo "Scan done, generating summary"

started=false
shouldfail=false
while read p; do
# skip comments (top and bottom)
if [[ $p == \#* ]]; then
continue
fi
# make sure first line after comments is skipped
if [[ "$started" = false ]]; then
started=true
continue
fi

IFS=',' read -r -a array <<< "$p"

ret=$(curl -I -s "${array[0]}" -o /dev/null -w "%{http_code}\n")
if [[ $ret == 200 ]]; then
echo "Site now seems to be working, we should continue here"
continue
else
echo "There is still an issue with ${array[0]}"
fi

shouldfail=true

if [[ ${array[10]} == '' ]]; then
echo "::error::URL: ${array[0]} on page: ${array[1]} is returning a ${array[3]}"
else
echo "::error::URL: ${array[0]} linked from '${array[10]}' on page: ${array[1]} is returning a ${array[3]}"
fi

done < link_report.csv

if [[ "$shouldfail" = false ]]; then
exit 0
fi

exit 1

- name: Upload report
if: failure()
uses: actions/upload-artifact@v4
with:
name: Report - ${{ matrix.site.name }}
path: link_report.csv
6 changes: 3 additions & 3 deletions fern/docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -325,7 +325,7 @@ redirects:
destination: https://buildwithfern.com/customers
permanent: true
- source: /learn/docs/getting-started/global-configuration
destination: /learn/docs/customization/what-is-docs-yml
destination: /learn/docs/configuration/what-is-docs-yml
permanent: true
- source: /learn/docs/getting-started/development
destination: /learn/docs/preview-publish/previewing-changes-locally
Expand Down Expand Up @@ -378,7 +378,7 @@ redirects:
destination: /learn/docs/customization/custom-css-js
permanent: true
- source: /learn/docs/building-and-customizing-your-docs/custom-domain
destination: /learn/docs/getting-started/setting-up-your-domain
destination: /learn/docs/preview-publish/setting-up-your-domain
permanent: true
- source: /learn/docs/building-and-customizing-your-docs/rbac
destination: /learn/docs/authentication/rbac
Expand Down Expand Up @@ -549,7 +549,7 @@ redirects:
destination: https://buildwithfern.com/customers
permanent: true
- source: /learn/ask-fern/citations
destination: /learn/ask-fern/configuration/citations
destination: /learn/ask-fern/features/citations
permanent: true
- source: /learn/ask-fern/custom-prompting
destination: /learn/ask-fern/configuration/custom-prompting
Expand Down
8 changes: 4 additions & 4 deletions fern/products/api-def/openapi-pages/extensions/overview.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,10 @@ The table below shows all available extensions and links to detailed documentati
| [`x-fern-audiences`](./audiences) | Filter endpoints, schemas, and properties by audience |
| [`x-fern-availability`](./availability) | Mark availability status (beta, generally-available, deprecated) |
| [`x-fern-base-path`](./base-path) | Set base path prepended to all endpoints |
| [`x-fern-enum`](./enums) | Add descriptions and custom names to enum values |
| [`x-fern-examples`](./examples) | Associate request and response examples |
| [`x-fern-enum`](./enum-descriptions-and-names) | Add descriptions and custom names to enum values |
| [`x-fern-examples`](./request-response-examples) | Associate request and response examples |
| [`x-fern-global-headers`](./global-headers) | Configure headers used across all endpoints |
| [`x-fern-ignore`](./ignore) | Skip reading specific endpoints or schemas |
| [`x-fern-ignore`](./ignoring-elements) | Skip reading specific endpoints or schemas |
| [`x-fern-sdk-method-name`](./method-names) | Customize SDK method names |
| [`x-fern-sdk-group-name`](./method-names) | Organize methods into SDK groups |
| [`x-fern-parameter-name`](./parameter-names) | Customize parameter variable names |
Expand All @@ -33,4 +33,4 @@ The table below shows all available extensions and links to detailed documentati

### FastAPI

FastAPI allows you to add extensions directly in your route decorators and models. See our [FastAPI integration guide](/api-definition/openapi/frameworks/fastapi) for detailed examples.
FastAPI allows you to add extensions directly in your route decorators and models. See our [FastAPI integration guide](/learn/api-definitions/openapi/frameworks/fastapi) for detailed examples.
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ Fern AI Search indexes your documentation and provides an interface for your use
<Card
title="Citations"
icon="regular quote-right"
href="/learn/ai-search/citations"
href="/learn/ask-fern/features/citations"
>
Point users to the exact source of the answer.
</Card>
Expand Down
2 changes: 1 addition & 1 deletion fern/products/docs/pages/changelog/2025-05-23.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@

We've added a `max-toc-depth` frontmatter option to control the depth of the table of contents. Use this to limit the heading ranks included in the table of contents.

You can read more about this feature in the [frontmatter documentation](/learn/docs/content/frontmatter#max-depth).
You can read more about this feature in the [frontmatter documentation](/learn/docs/configuration/page-level-settings#max-depth).
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ css:

<Note>
For customizing the background, logo, font, and layout of your Docs via Fern's built-in styling,
check out the [Global Configuration](/learn/docs/getting-started/global-configuration).
check out the [Global Configuration](/learn/docs/configuration/what-is-docs-yml).
</Note>

### Common use cases
Expand Down
2 changes: 1 addition & 1 deletion fern/products/docs/pages/customization/frontmatter.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -245,7 +245,7 @@ Currently, relative paths are _not_ supported for this field.
## SEO metadata

<Note title="SEO Best Practices">
Looking to set metadata across the entire site? [Use the metadata field in the `docs.yml` file](/learn/docs/customization/what-is-docs-yml#metadata-configuration).
Looking to set metadata across the entire site? [Use the metadata field in the `docs.yml` file](/learn/docs/configuration/what-is-docs-yml#metadata-configuration).

When configuring SEO metadata, ensure your titles and descriptions are unique, descriptive, and relevant to the page content. Keep descriptions between 150-160 characters for optimal display in search results.
</Note>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,7 @@ instances:
</ParamField>

<ParamField path="instances.custom-domain" type="string or list of strings" required={false}>
The custom domain where your documentation is hosted. Learn more about [setting up a custom domain](/learn/docs/building-your-docs/custom-domain).
The custom domain where your documentation is hosted. Learn more about [setting up a custom domain](/learn/docs/preview-publish/setting-up-your-domain).
</ParamField>

<ParamField path="instances.edit-this-page" type="object" required={false}>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,7 @@ instances:
</ParamField>

<ParamField path="instances.custom-domain" type="string or list of strings" required={false}>
The custom domain where your documentation is hosted. Learn more about [setting up a custom domain](/learn/docs/building-your-docs/custom-domain).
The custom domain where your documentation is hosted. Learn more about [setting up a custom domain](/learn/docs/preview-publish/setting-up-your-domain).
</ParamField>

<ParamField path="instances.edit-this-page" type="object" required={false}>
Expand Down
2 changes: 1 addition & 1 deletion fern/products/docs/pages/enterprise/self-hosted.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ Unless you have specific requirements that prevent using Fern's default hosting,

Self-hosted deployments include core Fern documentation website features like auto-generated API references, interactive documentation, SDK code snippets, search, and customizable branding.

However, features requiring external connections aren't supported, including [Ask Fern](/ask-fern/getting-started/what-is-ask-fern) (AI chat), [analytics](/integrations/overview), [live API key population](/docs/authentication/api-key-injection), and [SSO integrations](/docs/authentication/sso).
However, features requiring external connections aren't supported, including [Ask Fern](/ask-fern/getting-started/what-is-ask-fern) (AI chat), [analytics](/docs/integrations/overview), [live API key population](/docs/authentication/api-key-injection), and [SSO integrations](/docs/authentication/sso).

<Info title="Extended feature support">
**PDF export** and **offline AI chat functionality** are in development for self-hosted deployments. [Email us](mailto:[email protected]) if you're interested in these features.
Expand Down
2 changes: 1 addition & 1 deletion fern/products/docs/pages/getting-started/overview.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ subtitle: A website builder for beautiful agent and developer-friendly docs.
</div>
</a>

<a class="fern-card interactive not-prose rounded-3 relative block border p-6 text-base" href="/docs/customization/what-is-docs-yml">
<a class="fern-card interactive not-prose rounded-3 relative block border p-6 text-base" href="/docs/configuration/what-is-docs-yml">
<div class="flex items-start flex-col space-y-3">
<img class="mx-auto dark:hidden" alt="Configure with ease" src="./images/configure.png" />
<img class="mx-auto hidden dark:block" alt="Configure with ease" src="./images/configure-dark.png" />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ The `assets` folder contains any images or videos used in your documentation. Yo

The `docs.yml` file is the heart of your Fern documentation site. This configuration file controls your documentation's navigation structure, visual design, site functionality, and hosting settings.

For complete configuration options, see the [docs.yml reference](/docs/customization/what-is-docs-yml).
For complete configuration options, see the [docs.yml reference](/docs/configuration/what-is-docs-yml).

<CodeBlock title="fern/docs.yml of this website">
```yml
Expand Down
2 changes: 1 addition & 1 deletion fern/products/docs/pages/navigation/overview.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -240,7 +240,7 @@ Here's an example of what the Tabs implementation looks like:
<img src="./images/tabs-sidebar.png" alt="Tabs displayed in the sidebar (default)" />
</Frame>

Tabs display in the left sidebar by default. To display them horizontally, set `tabs-placement` to `header` in your [layout configuration](/docs/customization/what-is-docs-yml#layout-configuration).
Tabs display in the left sidebar by default. To display them horizontally, set `tabs-placement` to `header` in your [layout configuration](/docs/configuration/what-is-docs-yml#layout-configuration).

<CodeBlock title="docs.yml">
```yaml
Expand Down
2 changes: 1 addition & 1 deletion fern/products/docs/pages/navigation/products.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -164,7 +164,7 @@ products:
```
</CodeBlock>

For more information on setting up versioned products, follow our [versioning docs](/docs/navigation/versions).
For more information on setting up versioned products, follow our [versioning docs](/docs/configuration/versions).
</Step>
<Step title="Remove extra navigation from docs.yml">

Expand Down
2 changes: 1 addition & 1 deletion fern/products/docs/pages/navigation/versions.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ tabs:
</CodeBlock>
</CodeBlocks>

<Note>You can also have multiple products, some versioned and some unversioned. For more information on setting up multiple products, follow our [product switching docs](/docs/navigation/products).</Note>
<Note>You can also have multiple products, some versioned and some unversioned. For more information on setting up multiple products, follow our [product switching docs](/docs/configuration/products).</Note>
</Step>
<Step title="Add your version configuration">

Expand Down