2021-06-04 11:17:15 +02:00
|
|
|
/**
|
|
|
|
* Creating a sidebar enables you to:
|
|
|
|
- create an ordered group of docs
|
|
|
|
- render a sidebar for each doc of that group
|
|
|
|
- provide next/previous navigation
|
|
|
|
|
|
|
|
The sidebars can be generated from the filesystem, or explicitly defined here.
|
|
|
|
|
|
|
|
Create as many sidebars as you want.
|
|
|
|
*/
|
|
|
|
|
|
|
|
module.exports = {
|
2022-01-25 12:20:53 +01:00
|
|
|
documentation: [
|
|
|
|
'user_guide/index',
|
2022-01-12 11:44:14 +01:00
|
|
|
{
|
2022-01-24 13:41:29 +01:00
|
|
|
label: 'First steps and tutorials',
|
|
|
|
type: 'category',
|
2022-01-26 11:51:35 +01:00
|
|
|
collapsed: false,
|
2022-01-24 13:41:29 +01:00
|
|
|
link: {
|
|
|
|
type: 'generated-index',
|
|
|
|
title: 'First steps',
|
|
|
|
description: 'Learn how and where to get started with Unleash.',
|
|
|
|
slug: '/tutorials',
|
|
|
|
},
|
|
|
|
items: [
|
2022-01-12 11:44:14 +01:00
|
|
|
'user_guide/unleash_overview',
|
|
|
|
'user_guide/important-concepts',
|
|
|
|
'user_guide/quickstart',
|
|
|
|
],
|
|
|
|
},
|
docs: add "The Anatomy of Unleash" (#2138)
## What
This PR
1. adds a new topic document, "The Anatomy of Unleash", which explains
how Unleash is built up as a system.
2. It also moves the "topic guides" sidebar entry from position 4 to
position 2.
3. Finally, it introduces a new `Figure` component for the
documentation, to be used with images that should be shown with
captions.
## Why
Referring to the same numbers as mentioned above, here's some background
for these changes:
1. We have gotten requests from enterprise users for a way to help new
Unleash users understand the system. Together with customer success and
customer journey, we agreed that an explanatory guide would be suitable.
It aims to give the reader an introduction into what pieces constitute
the Unleash system.
2. As part of a discussion, it was suggested to move topic guides higher
up to make them more visible. There's a few reasons for this:
1. New users of Unleash should be able to keep reading about Unleash
after the basic introductory material. When left at the bottom, topic
guides are often overlooked
2. As a justification, it was proposed that reference docs are often the
last thing you look for, so it makes sense to put that last.
3. Thinking about a new user's flow, it also makes some sense: first
read introductory material, then dive deeper into what Unleash is and
what you can use it for, then look for how-to guides if you're stuck,
and finally consult the reference material for later.
3. These diagrams aren't necessarily very self-explanatory, so adding a
caption makes a lot of sense. We didn't have a component from this
previously, so I added one.
Co-authored-by: NicolaeUnleash <103567375+NicolaeUnleash@users.noreply.github.com>
Co-authored-by: Simon Hornby <liquidwicked64@gmail.com>
## Commits
* docs: add raw export of anatomy document
* docs: move the topic guides section to near top of sidebar
* docs: add inter-doc links, some reformatting
* docs: fix broken links
* docs: add a Figure element for figures with captions
* docs: add more styling to figures
* docs: align on styles
* Fix: add fuller figure caption
* docs: rephrase heading
* Docs(test): try new way of importing images
* Docs(test): images take 3
* docs: Convert all images to using the figure component
* docs: add projects to list of top-level resources
* docs: add captions for all figures.
* docs: reorder images
* Docs(fix): typo: extra brackets
* Docs(style): remove box shadows and border on fig caption images
* Docs(chore): remove commented-out css
* Docs(refactor): use css variable for small font size.
To facilitate reusability and convey meaning.
* docs: rename anatomy doc
* docs: add note about strategies vs constraints
* Updating the images
* Apply suggestions from code review
Co-authored-by: Simon Hornby <liquidwicked64@gmail.com>
* Update website/docs/topics/the-anatomy-of-unleash.mdx
* Docs(fix): remove redundant comma
* docs: add link to node js sdk
* docs: mention that a toggle must be active in an env to be enabled
* docs: add note about environments and api keys
* Docs(reword): swap dev and prod in example
* docs: fix typo in the image
* docs: make figures in text full-width
* docs: move environments and API keys call-out to after figure
* docs: add borders to figures
* docs: add image float css idea
* Revert "docs: add image float css idea"
This reverts commit 69f27d304b4a4d2a7422046475380011345736a2.
Co-authored-by: NicolaeUnleash <103567375+NicolaeUnleash@users.noreply.github.com>
Co-authored-by: Simon Hornby <liquidwicked64@gmail.com>
2022-10-19 13:14:49 +02:00
|
|
|
{
|
|
|
|
label: 'Topic guides',
|
|
|
|
collapsed: false,
|
|
|
|
type: 'category',
|
|
|
|
link: {
|
|
|
|
type: 'generated-index',
|
|
|
|
title: 'Topic guides',
|
|
|
|
description:
|
|
|
|
'Discussions, explanations, and explorations regarding topics related to Unleash.',
|
|
|
|
slug: '/topics',
|
|
|
|
},
|
|
|
|
items: [
|
|
|
|
'topics/the-anatomy-of-unleash',
|
|
|
|
'topics/a-b-testing',
|
|
|
|
'topics/proxy-hosting',
|
|
|
|
],
|
|
|
|
},
|
2022-01-12 11:44:14 +01:00
|
|
|
{
|
2022-01-21 07:39:10 +01:00
|
|
|
label: 'How-to guides',
|
2022-01-26 11:51:35 +01:00
|
|
|
collapsed: false,
|
2022-01-12 11:44:14 +01:00
|
|
|
type: 'category',
|
2022-01-14 08:19:34 +01:00
|
|
|
link: {
|
|
|
|
type: 'generated-index',
|
|
|
|
title: 'How-to guides',
|
2022-01-24 13:41:29 +01:00
|
|
|
description: 'Step-by-step recipes for you to follow.',
|
2022-01-14 08:19:34 +01:00
|
|
|
slug: '/how-to',
|
|
|
|
},
|
2022-01-12 11:44:14 +01:00
|
|
|
items: [
|
2022-01-14 13:19:13 +01:00
|
|
|
{
|
2022-01-24 13:41:29 +01:00
|
|
|
type: 'category',
|
|
|
|
link: {
|
|
|
|
type: 'generated-index',
|
|
|
|
title: 'How-to: Unleash API',
|
|
|
|
description: 'Learn how to work with the Unleash API',
|
|
|
|
slug: '/how-to/api',
|
|
|
|
},
|
2022-07-22 09:02:01 +02:00
|
|
|
label: 'Unleash API guides',
|
|
|
|
items: [
|
|
|
|
'user_guide/api-token',
|
2022-10-13 11:02:04 +02:00
|
|
|
'how-to/how-to-create-personal-access-tokens',
|
2022-07-22 09:02:01 +02:00
|
|
|
'advanced/api_access',
|
|
|
|
'how-to/how-to-enable-openapi',
|
|
|
|
],
|
2022-01-24 13:41:29 +01:00
|
|
|
},
|
2022-03-28 13:22:24 +02:00
|
|
|
{
|
|
|
|
type: 'category',
|
|
|
|
link: {
|
|
|
|
type: 'generated-index',
|
|
|
|
title: 'How-to: The Unleash Proxy',
|
|
|
|
description: 'Learn how to work with the Unleash Proxy',
|
|
|
|
slug: '/how-to/proxy',
|
|
|
|
},
|
|
|
|
label: 'Unleash Proxy guides',
|
|
|
|
items: ['how-to/how-to-run-the-unleash-proxy'],
|
|
|
|
},
|
2022-01-24 13:41:29 +01:00
|
|
|
{
|
|
|
|
label: 'Feature toggles, strategies, context',
|
|
|
|
items: [
|
2022-01-14 13:19:13 +01:00
|
|
|
'how-to/how-to-add-strategy-constraints',
|
2022-03-11 13:58:41 +01:00
|
|
|
'how-to/how-to-capture-impression-data',
|
2022-01-14 13:24:05 +01:00
|
|
|
'user_guide/create_feature_toggle',
|
2022-01-14 13:19:13 +01:00
|
|
|
'how-to/how-to-define-custom-context-fields',
|
|
|
|
'how-to/how-to-use-custom-strategies',
|
2022-03-11 13:58:41 +01:00
|
|
|
'how-to/how-to-schedule-feature-releases',
|
2022-01-14 13:19:13 +01:00
|
|
|
],
|
2022-01-24 13:41:29 +01:00
|
|
|
type: 'category',
|
|
|
|
link: {
|
|
|
|
type: 'generated-index',
|
|
|
|
title: 'How-to: general Unleash tasks',
|
|
|
|
description:
|
|
|
|
'Guides for how to perform general Unleash tasks.',
|
|
|
|
slug: '/how-to/misc',
|
|
|
|
},
|
|
|
|
},
|
2022-11-03 13:14:08 +01:00
|
|
|
{
|
|
|
|
label: 'Environments',
|
|
|
|
items: ['how-to/how-to-clone-environments'],
|
|
|
|
type: 'category',
|
|
|
|
link: {
|
|
|
|
type: 'generated-index',
|
|
|
|
title: 'How-to: environments',
|
|
|
|
description: 'Environments how-to guides.',
|
|
|
|
slug: '/how-to/env',
|
|
|
|
},
|
|
|
|
},
|
2022-01-24 13:41:29 +01:00
|
|
|
{
|
|
|
|
label: 'Users and permissions',
|
|
|
|
items: [
|
2022-01-14 13:19:13 +01:00
|
|
|
'user_guide/user-management',
|
2022-01-14 13:24:05 +01:00
|
|
|
'how-to/how-to-create-and-assign-custom-project-roles',
|
2022-07-21 16:23:56 +02:00
|
|
|
'how-to/how-to-create-and-manage-user-groups',
|
2022-11-03 13:59:12 +01:00
|
|
|
'how-to/how-to-set-up-group-sso-sync',
|
2022-01-14 13:19:13 +01:00
|
|
|
],
|
2022-01-24 13:41:29 +01:00
|
|
|
type: 'category',
|
|
|
|
link: {
|
|
|
|
type: 'generated-index',
|
|
|
|
title: 'How-to: users and permissions',
|
|
|
|
description: 'Users and permission how-to guides.',
|
|
|
|
slug: '/how-to/users-and-permissions',
|
|
|
|
},
|
|
|
|
},
|
|
|
|
{
|
|
|
|
label: 'Single Sign-On (SSO)',
|
|
|
|
items: [
|
2022-11-14 13:11:27 +01:00
|
|
|
'how-to/how-to-add-sso-open-id-connect',
|
|
|
|
'how-to/how-to-add-sso-saml',
|
|
|
|
'how-to/how-to-add-sso-saml-keycloak',
|
|
|
|
'how-to/how-to-add-sso-google',
|
2022-11-03 13:59:12 +01:00
|
|
|
'how-to/how-to-setup-sso-keycloak-group-sync',
|
2022-01-14 13:19:13 +01:00
|
|
|
],
|
2022-01-24 13:41:29 +01:00
|
|
|
type: 'category',
|
|
|
|
link: {
|
|
|
|
type: 'generated-index',
|
|
|
|
title: 'How-to: Single Sign-On',
|
|
|
|
description: 'Single Sign-On how-to guides.',
|
|
|
|
slug: '/how-to/sso',
|
|
|
|
},
|
2022-01-14 13:19:13 +01:00
|
|
|
},
|
2022-01-24 13:41:29 +01:00
|
|
|
,
|
2022-01-12 11:44:14 +01:00
|
|
|
],
|
|
|
|
},
|
2022-01-25 12:20:53 +01:00
|
|
|
{
|
2022-01-21 07:39:10 +01:00
|
|
|
label: 'Reference documentation',
|
2022-01-26 11:51:35 +01:00
|
|
|
collapsed: false,
|
2022-01-11 14:54:37 +01:00
|
|
|
type: 'category',
|
2022-01-24 13:41:29 +01:00
|
|
|
link: {
|
|
|
|
type: 'generated-index',
|
|
|
|
title: 'Reference documentation',
|
|
|
|
description:
|
|
|
|
'Technical reference documentation relating to Unleash, including APIs, SDKs, Unleash concepts and deployment.',
|
|
|
|
slug: '/reference',
|
|
|
|
},
|
2022-01-11 14:54:37 +01:00
|
|
|
items: [
|
2022-01-11 13:43:19 +01:00
|
|
|
{
|
2022-01-24 13:41:29 +01:00
|
|
|
type: 'category',
|
2022-01-26 11:51:35 +01:00
|
|
|
link: { type: 'doc', id: 'addons/index' },
|
2022-01-24 13:41:29 +01:00
|
|
|
items: [
|
2022-01-26 11:51:35 +01:00
|
|
|
'addons/datadog',
|
|
|
|
'addons/slack',
|
|
|
|
'addons/teams',
|
|
|
|
'addons/webhook',
|
2022-01-11 13:43:19 +01:00
|
|
|
],
|
2022-01-26 11:51:35 +01:00
|
|
|
label: 'Addons',
|
2022-01-11 13:43:19 +01:00
|
|
|
},
|
|
|
|
{
|
2022-01-12 11:44:14 +01:00
|
|
|
type: 'category',
|
|
|
|
link: { type: 'doc', id: 'api/index' },
|
|
|
|
label: 'APIs',
|
|
|
|
items: [
|
|
|
|
{
|
|
|
|
'Admin API': [
|
|
|
|
'api/admin/addons',
|
|
|
|
'api/admin/context',
|
|
|
|
'api/admin/events',
|
|
|
|
'api/admin/feature-toggles-v2',
|
|
|
|
'api/admin/feature-types',
|
|
|
|
'api/admin/features',
|
|
|
|
'api/admin/features-archive',
|
|
|
|
'api/admin/metrics',
|
|
|
|
'api/admin/projects',
|
2022-03-30 16:01:07 +02:00
|
|
|
'api/admin/segments',
|
2022-01-12 11:44:14 +01:00
|
|
|
'api/admin/state',
|
|
|
|
'api/admin/strategies',
|
2022-08-12 11:37:57 +02:00
|
|
|
'api/admin/tags',
|
2022-01-12 11:44:14 +01:00
|
|
|
'api/admin/user-admin',
|
|
|
|
],
|
|
|
|
'Client API': [
|
|
|
|
'api/client/features',
|
|
|
|
'api/client/metrics',
|
|
|
|
'api/client/register',
|
|
|
|
],
|
|
|
|
'System API': [
|
|
|
|
'api/internal/internal',
|
|
|
|
'api/internal/health',
|
|
|
|
],
|
|
|
|
},
|
Add OpenAPI docs (#1391) (#2066)
## What
This PR (finally 🎉) adds generated OpenAPI docs to the official Unleash documentation. In addition to generating docs when things get merged to main, it also pushes new doc updates every day at 12:00 AM (cron `@daily`).
## Why
Now that we have OpenAPI'd all the things, we can finally start using it. This will allow us to remove hand-written api docs from the documentation and should make sure everything is always kept up to date.
### Generating from us-hosted (Unleash enterprise)
Unleash has several different versions (open source, pro, enterprise). The versions do not necessarily have the exact same api surface. In fact, the enterprise version has a few endpoints that open source does not.
Because we want to have _all_ endpoints listed in the documentation we need to generated the docs from an enterprise spec. Which brings us into the next point:
### The need for scheduled jobs
Regarding the daily scheduled tasks to update the documentation: why do we need that?
The docs are generated from the tip of the main branch. For most of the docs, this is good and something that we want. However, because the OpenAPI docs are generated from the enterprise edition, it _will not be in sync_ with the open source main branch.
Also, we probably do not want the docs to list the current bleeding edge api changes. Instead, we should prefer to use the latest enterprise release (roughly). However, because we don't get notified when this version is released and deployed, we'll instead run the API generation on a daily cadence.
This isn't the perfect solution, but it's simple and gets us 80% of the way there. More intricate solutions can be set up later.
## How
- By adding a scheduled workflow to the generate docs config.
- By adding .gitignore entries for the generated files
There's also some minor changes in styling etc.
## Dependencies
This is dependent on the changes introduced in #2062 having propagated to the enterprise release, which will probably not be for another week or so.
## Discussion
What should the API reference docs url be? I've set it to be `/reference/api/unleash/*` for now, but I'm on the fence about whether it should be `apis` or `api` in there. I also want to get the proxy and other APIs in there as we grow.
-------
## Commits
* docs: style openapi operation buttons
* docs: minor operation badge adjustments
* docs: use permalink to css snippet i copied
* docs: ignore files related to openapi generation
* docs: re-enable openapi docs
* Docs(#1391): prep for integration
* docs(#1391): run docs generation daily
* docs(#1391): add generation step to doc prs too
* docs(#1391): use the US hosted instance to generate docs
* docs(#1391): move doc generation into build command
* docs(#1391): use `/reference/api/*` instead of `/reference/apis/*`
2022-09-19 14:50:24 +02:00
|
|
|
{
|
|
|
|
label: 'OpenAPI docs',
|
|
|
|
collapsed: true,
|
|
|
|
type: 'category',
|
|
|
|
link: {
|
|
|
|
title: 'Unleash Server APIs',
|
|
|
|
type: 'generated-index',
|
|
|
|
description:
|
|
|
|
'Generated API docs based on the Unleash OpenAPI schema. For the time being, some additional info can also be found in the older API docs.',
|
|
|
|
slug: '/reference/api/unleash',
|
|
|
|
},
|
|
|
|
items: require('./docs/reference/api/unleash/sidebar.js'),
|
|
|
|
},
|
2022-01-11 13:43:19 +01:00
|
|
|
],
|
2022-01-12 11:44:14 +01:00
|
|
|
},
|
|
|
|
{
|
2022-01-24 13:41:29 +01:00
|
|
|
type: 'category',
|
2022-09-15 09:02:10 +02:00
|
|
|
label: 'Application SDKs',
|
2022-01-24 13:41:29 +01:00
|
|
|
link: { type: 'doc', id: 'sdks/index' },
|
|
|
|
items: [
|
2022-01-11 14:54:37 +01:00
|
|
|
{
|
2022-01-13 11:07:44 +01:00
|
|
|
type: 'category',
|
|
|
|
label: 'Server-side SDKs',
|
|
|
|
items: [
|
|
|
|
'sdks/go_sdk',
|
|
|
|
'sdks/java_sdk',
|
|
|
|
'sdks/node_sdk',
|
|
|
|
'sdks/php_sdk',
|
|
|
|
'sdks/python_sdk',
|
|
|
|
'sdks/ruby_sdk',
|
|
|
|
{
|
|
|
|
type: 'link',
|
|
|
|
href: 'https://github.com/unleash/unleash-client-rust',
|
|
|
|
label: 'Rust SDK',
|
|
|
|
},
|
|
|
|
'sdks/dot_net_sdk',
|
|
|
|
],
|
|
|
|
},
|
|
|
|
{
|
|
|
|
type: 'category',
|
|
|
|
label: 'Client-side SDKs',
|
|
|
|
items: [
|
|
|
|
'sdks/android_proxy_sdk',
|
|
|
|
'sdks/proxy-ios',
|
|
|
|
'sdks/proxy-javascript',
|
|
|
|
'sdks/proxy-react',
|
2022-05-03 10:21:14 +02:00
|
|
|
'sdks/proxy-svelte',
|
2022-04-28 15:33:38 +02:00
|
|
|
'sdks/proxy-vue',
|
2022-01-13 11:07:44 +01:00
|
|
|
],
|
|
|
|
},
|
|
|
|
{
|
2022-01-11 14:54:37 +01:00
|
|
|
type: 'link',
|
2022-01-13 11:07:44 +01:00
|
|
|
label: 'Community SDKs',
|
2022-01-11 14:54:37 +01:00
|
|
|
href: '/sdks#community-sdks',
|
|
|
|
},
|
2022-01-11 15:06:32 +01:00
|
|
|
],
|
2022-01-24 13:41:29 +01:00
|
|
|
},
|
|
|
|
{
|
|
|
|
type: 'category',
|
|
|
|
link: {
|
|
|
|
type: 'generated-index',
|
|
|
|
title: 'Deployment and management of Unleash',
|
|
|
|
description:
|
|
|
|
'All you need to learn how to deploy and manage your own Unleash instance.',
|
|
|
|
slug: '/deploy',
|
|
|
|
},
|
|
|
|
label: 'Deploy and manage Unleash',
|
|
|
|
items: [
|
2022-01-12 11:44:14 +01:00
|
|
|
'deploy/getting_started',
|
|
|
|
'deploy/configuring_unleash',
|
|
|
|
'deploy/database-setup',
|
|
|
|
'deploy/database_backup',
|
2022-01-14 13:24:05 +01:00
|
|
|
'deploy/email',
|
|
|
|
'deploy/google_auth',
|
2022-01-12 11:44:14 +01:00
|
|
|
'deploy/import_export',
|
2022-01-14 13:24:05 +01:00
|
|
|
'deploy/migration_guide',
|
|
|
|
'deploy/securing_unleash',
|
2022-01-12 11:44:14 +01:00
|
|
|
],
|
|
|
|
},
|
|
|
|
{
|
|
|
|
type: 'category',
|
|
|
|
label: 'Integrations',
|
|
|
|
link: { type: 'doc', id: 'integrations/integrations' },
|
|
|
|
items: [
|
|
|
|
{
|
|
|
|
'Jira Server': [
|
|
|
|
'integrations/jira_server_plugin_installation',
|
|
|
|
'integrations/jira_server_plugin_usage',
|
|
|
|
],
|
|
|
|
},
|
|
|
|
,
|
|
|
|
],
|
2022-01-11 13:43:19 +01:00
|
|
|
},
|
2022-01-26 11:51:35 +01:00
|
|
|
{
|
|
|
|
type: 'category',
|
|
|
|
link: {
|
|
|
|
type: 'generated-index',
|
|
|
|
title: 'Unleash concepts',
|
|
|
|
description:
|
|
|
|
'Documents describing the inner parts of Unleash.',
|
|
|
|
slug: '/reference/concepts',
|
|
|
|
},
|
|
|
|
label: 'Unleash concepts',
|
|
|
|
items: [
|
|
|
|
'user_guide/activation_strategy',
|
2022-04-13 13:46:12 +02:00
|
|
|
'reference/api-tokens-and-client-keys',
|
2022-01-26 11:51:35 +01:00
|
|
|
'advanced/archived_toggles',
|
2022-09-14 09:59:18 +02:00
|
|
|
'reference/event-log',
|
2022-02-08 12:11:08 +01:00
|
|
|
'advanced/impression-data',
|
2022-01-26 11:51:35 +01:00
|
|
|
'advanced/custom_activation_strategy',
|
|
|
|
'user_guide/environments',
|
2022-06-17 12:36:19 +02:00
|
|
|
'reference/feature-toggles',
|
2022-01-26 11:51:35 +01:00
|
|
|
'advanced/feature_toggle_types',
|
|
|
|
'advanced/toggle_variants',
|
2022-09-15 09:02:10 +02:00
|
|
|
'reference/front-end-api',
|
2022-08-12 12:17:25 +02:00
|
|
|
'reference/playground',
|
2022-10-10 15:12:11 +02:00
|
|
|
'reference/public-signup',
|
2022-01-26 11:51:35 +01:00
|
|
|
'user_guide/projects',
|
|
|
|
'user_guide/rbac',
|
2022-03-30 12:31:51 +02:00
|
|
|
'reference/segments',
|
2022-01-26 11:51:35 +01:00
|
|
|
'advanced/enterprise-authentication',
|
|
|
|
'advanced/stickiness',
|
|
|
|
'advanced/strategy_constraints',
|
|
|
|
'advanced/tags',
|
|
|
|
'user_guide/technical_debt',
|
|
|
|
'user_guide/unleash_context',
|
|
|
|
'sdks/unleash-proxy',
|
|
|
|
],
|
|
|
|
},
|
2022-01-11 13:43:19 +01:00
|
|
|
],
|
2022-01-11 14:54:37 +01:00
|
|
|
},
|
2022-01-25 12:20:53 +01:00
|
|
|
],
|
2021-06-04 11:17:15 +02:00
|
|
|
};
|