@redocly/redoc-reef 0.139.0-next.1 → 0.139.0-next.11
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +192 -0
- package/dist/cli/eject/resolveEjectParams.js +1 -1
- package/dist/client/app/Sidebar/RequestAccessButton.js +2 -2
- package/dist/client/app/hooks/useL10nConfig.d.ts +1 -0
- package/dist/client/app/markdoc/custom-components/openapi/openapi-example.js +1 -1
- package/dist/client/app/markdoc/custom-components/openapi/replay-openapi.js +1 -1
- package/dist/client/app/search/useSearch.js +1 -1
- package/dist/client/app/utils/programmatic-scroll.js +1 -1
- package/dist/client/app/webmcp/tools/api-tools.js +1 -1
- package/dist/client/app/webmcp/tools/site-tools.js +2 -2
- package/dist/client/app/webmcp/useWebMcpTools.js +1 -1
- package/dist/client/templates/api-docs/template.js +10 -8
- package/dist/constants/common.d.ts +1 -0
- package/dist/constants/common.js +1 -1
- package/dist/constants/l10n/langs/ar.js +1 -1
- package/dist/constants/l10n/langs/de.js +1 -1
- package/dist/constants/l10n/langs/en.js +1 -1
- package/dist/constants/l10n/langs/es.js +1 -1
- package/dist/constants/l10n/langs/fr.js +1 -1
- package/dist/constants/l10n/langs/hi.js +1 -1
- package/dist/constants/l10n/langs/it.js +1 -1
- package/dist/constants/l10n/langs/ja.js +1 -1
- package/dist/constants/l10n/langs/ko.js +1 -1
- package/dist/constants/l10n/langs/pl.js +1 -1
- package/dist/constants/l10n/langs/pt-BR.js +1 -1
- package/dist/constants/l10n/langs/pt.js +1 -1
- package/dist/constants/l10n/langs/ru.js +1 -1
- package/dist/constants/l10n/langs/uk.js +1 -1
- package/dist/constants/l10n/langs/zh.js +1 -1
- package/dist/markdoc/helpers/get-inner-text.d.ts +2 -0
- package/dist/markdoc/helpers/get-inner-text.js +2 -2
- package/dist/markdoc/helpers/remove-markdoc-tags.js +1 -1
- package/dist/server/config/env-schemas/feature-flags.d.ts +1 -1
- package/dist/server/constants/entitlements.d.ts +2 -2
- package/dist/server/constants/entitlements.js +1 -1
- package/dist/server/entitlements/entitlements-provider.d.ts +2 -2
- package/dist/server/entitlements/is-valid-plan.d.ts +2 -2
- package/dist/server/entitlements/is-valid-plan.js +1 -1
- package/dist/server/fs/content-fs.js +1 -1
- package/dist/server/fs/utils/external-ref-resolver.js +2 -2
- package/dist/server/fs/utils/is-translation-fallback.d.ts +9 -0
- package/dist/server/fs/utils/is-translation-fallback.js +1 -0
- package/dist/server/node-bundle-entry.js +1 -1
- package/dist/server/plugins/api-docs/get-server-props.js +1 -1
- package/dist/server/plugins/api-docs/index.js +1 -1
- package/dist/server/plugins/api-docs/loader.js +3 -3
- package/dist/server/plugins/api-docs/search/get-ai-search-documents.d.ts +6 -3
- package/dist/server/plugins/api-docs/search/get-ai-search-documents.js +69 -69
- package/dist/server/plugins/api-docs/utils/inject-metadata.d.ts +19 -0
- package/dist/server/plugins/api-docs/utils/inject-metadata.js +1 -0
- package/dist/server/plugins/arazzo-docs/arazzo-doc-loader.js +2 -2
- package/dist/server/plugins/arazzo-docs/index.js +1 -1
- package/dist/server/plugins/catalog-entities/extensions/extractors/api-description/openapi-entities-extractor.js +1 -1
- package/dist/server/plugins/catalog-entities/template/index.js +1 -1
- package/dist/server/plugins/config-parser/loaders/versions-config-loader.js +1 -1
- package/dist/server/plugins/default-theme/resolve-logo.js +1 -1
- package/dist/server/plugins/dev-onboarding/api/routes/index.js +1 -1
- package/dist/server/plugins/dev-onboarding/api/routes/products.js +1 -1
- package/dist/server/plugins/dev-onboarding/template/App.js +4 -4
- package/dist/server/plugins/dev-onboarding/template/AppsList.js +7 -7
- package/dist/server/plugins/dev-onboarding/template/CreateAppDialog.js +3 -3
- package/dist/server/plugins/dev-onboarding/template/components/ApiKeyItem.js +4 -4
- package/dist/server/plugins/dev-onboarding/template/components/ApiLogDetails.js +7 -7
- package/dist/server/plugins/dev-onboarding/template/components/ApiLogs.js +5 -5
- package/dist/server/plugins/dev-onboarding/template/components/ApiLogsActions.js +6 -6
- package/dist/server/plugins/dev-onboarding/template/components/ApisList.js +1 -1
- package/dist/server/plugins/dev-onboarding/template/components/CreateApiKey.js +1 -1
- package/dist/server/plugins/dev-onboarding/template/components/DeleteAppDialog.js +1 -1
- package/dist/server/plugins/dev-onboarding/template/components/EditApis.js +1 -1
- package/dist/server/plugins/dev-onboarding/template/components/EditAppDescriptionDialog.js +1 -1
- package/dist/server/plugins/dev-onboarding/template/components/EditAppDialog.js +1 -1
- package/dist/server/plugins/dev-onboarding/template/components/EditCallbackUrlDialog.js +1 -1
- package/dist/server/plugins/dev-onboarding/template/components/RevokeAPIKey.js +5 -5
- package/dist/server/plugins/dev-onboarding/template/components/RollAPIKey.js +5 -5
- package/dist/server/plugins/dev-onboarding/template/components/UpdateApiKey.js +1 -1
- package/dist/server/plugins/l10n/index.js +1 -1
- package/dist/server/plugins/markdown/attribute-resolvers/resolve-json-example-ref.js +1 -1
- package/dist/server/plugins/markdown/attribute-resolvers/resolve-link.js +1 -1
- package/dist/server/plugins/markdown/get-server-props.js +1 -1
- package/dist/server/plugins/markdown/index.js +1 -1
- package/dist/server/plugins/markdown/markdoc/plugins/utils.js +1 -1
- package/dist/server/plugins/markdown/markdoc/resolve-raw-partials.js +1 -1
- package/dist/server/plugins/markdown/markdown-static-data-loader.js +1 -1
- package/dist/server/plugins/markdown/read-file-content.js +1 -1
- package/dist/server/plugins/markdown/search/search-resolver.js +1 -1
- package/dist/server/plugins/mcp/codemode/prompts.d.ts +0 -1
- package/dist/server/plugins/mcp/codemode/prompts.js +3 -3
- package/dist/server/plugins/mcp/constants.d.ts +0 -2
- package/dist/server/plugins/mcp/constants.js +1 -1
- package/dist/server/plugins/mcp/docs-mcp/tool-schemas.js +1 -1
- package/dist/server/plugins/mcp/docs-mcp/tools/openapi/endpoint-suggestions.d.ts +0 -2
- package/dist/server/plugins/mcp/docs-mcp/tools/openapi/endpoint-suggestions.js +1 -1
- package/dist/server/plugins/mcp/gateway-mcp/allowed-http-methods.d.ts +0 -5
- package/dist/server/plugins/mcp/gateway-mcp/allowed-http-methods.js +1 -1
- package/dist/server/plugins/mcp/gateway-mcp/caller-api-calls.d.ts +3 -4
- package/dist/server/plugins/mcp/gateway-mcp/caller-api-calls.js +1 -1
- package/dist/server/plugins/mcp/gateway-mcp/eligibility.d.ts +1 -12
- package/dist/server/plugins/mcp/gateway-mcp/eligibility.js +1 -1
- package/dist/server/plugins/mcp/handlers/errors.d.ts +0 -2
- package/dist/server/plugins/mcp/handlers/errors.js +1 -1
- package/dist/server/plugins/mcp/utils.d.ts +0 -8
- package/dist/server/plugins/mcp/utils.js +1 -1
- package/dist/server/plugins/nav-utils.js +1 -1
- package/dist/server/plugins/pages/index.js +1 -1
- package/dist/server/plugins/register-page-props.d.ts +1 -1
- package/dist/server/plugins/register-page-props.js +1 -1
- package/dist/server/plugins/sidebars/index.js +1 -1
- package/dist/server/plugins/sidebars/utils.js +1 -1
- package/dist/server/store.d.ts +3 -1
- package/dist/server/store.js +1 -1
- package/dist/server/types/index.d.ts +1 -0
- package/dist/server/types/plugins/markdown.d.ts +1 -0
- package/dist/server/types/static-files.d.ts +6 -0
- package/dist/server/types/static-files.js +0 -0
- package/dist/server/utils/content/build-static-file-paths.d.ts +15 -0
- package/dist/server/utils/content/build-static-file-paths.js +1 -0
- package/dist/server/utils/envs/load-env-variables.js +1 -1
- package/dist/server/utils/lifecycle-hooks.js +1 -1
- package/dist/server/utils/rbac-expand.d.ts +4 -0
- package/dist/server/utils/rbac-expand.js +1 -1
- package/dist/server/utils/rbac.js +1 -1
- package/dist/server/utils/redirects/find-redirect.d.ts +4 -3
- package/dist/server/utils/redirects/find-redirect.js +1 -1
- package/dist/server/utils/resolve-asset-path.js +1 -1
- package/dist/server/web-server/auth.d.ts +2 -0
- package/dist/server/web-server/auth.js +3 -3
- package/dist/server/web-server/jwt/jwt.js +1 -1
- package/dist/server/web-server/middleware/catalogAuthMiddleware.js +1 -1
- package/dist/server/web-server/routes/mcp-routes/mcp-oauth.js +1 -1
- package/dist/types/entitlements.d.ts +2 -1
- package/dist/types/global-data.d.ts +1 -0
- package/dist/utils/url/api-keys-url.d.ts +11 -0
- package/dist/utils/url/api-keys-url.js +1 -0
- package/package.json +7 -7
- package/dist/server/plugins/mcp/docs-mcp/tools/core/utils.d.ts +0 -3
- package/dist/server/plugins/mcp/docs-mcp/tools/core/utils.js +0 -11
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,187 @@
|
|
|
1
1
|
# @redocly/redoc-reef
|
|
2
2
|
|
|
3
|
+
## 0.139.0-next.11
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- 591465450a1: Added a schema status (**No schema**, **Loading schema...**, **Schema loaded**) to the **Query** editor header of GraphQL requests in Replay and the **Try it** console.
|
|
8
|
+
Schema notifications appear only after **Fetch schema** or **Load schema file**.
|
|
9
|
+
|
|
10
|
+
### Patch Changes
|
|
11
|
+
|
|
12
|
+
- e6f7379a3a0: Improved access control to better protect customer resources.
|
|
13
|
+
- 9a8eefed65a: Fixed performance issues with the **Expand all** and **Collapse all** controls on GraphQL pages with many fields.
|
|
14
|
+
- 37e93575404: Fixed an issue in OpenAPI docs where `llms.txt` showed the API `description` from the `metadata` configuration two times: as the API description and again in the metadata list.
|
|
15
|
+
- 37e93575404: Fixed an issue in API docs where the `.md` routes and `llms.txt` left out Markdoc tags that resolved data at build time, such as `json-schema` and the OpenAPI sample tags, from the API description and operation descriptions.
|
|
16
|
+
- b4edb142025: Updated `@redocly/openapi-core` to version `2.66.0`.
|
|
17
|
+
- 250163f65ec: Reduced the page actions button to 24px in Markdown pages and API docs, and moved it below the title on mobile devices, so long titles use the full width of the screen.
|
|
18
|
+
- b82ff0e046f: Fixed an issue where a wildcard redirect to a file in the `static` folder returned a 404 error when the file name contained uppercase characters.
|
|
19
|
+
- Updated dependencies [9a8eefed65a]
|
|
20
|
+
- Updated dependencies [b4edb142025]
|
|
21
|
+
- Updated dependencies [250163f65ec]
|
|
22
|
+
- Updated dependencies [d888b826a0c]
|
|
23
|
+
- @redocly/api-docs@0.4.0-next.11
|
|
24
|
+
- @redocly/theme@0.71.0-next.7
|
|
25
|
+
- @redocly/portal-plugin-mock-server@0.24.0-next.3
|
|
26
|
+
|
|
27
|
+
## 0.139.0-next.10
|
|
28
|
+
|
|
29
|
+
### Patch Changes
|
|
30
|
+
|
|
31
|
+
- a4e681b2665: Fixed the **Expand all** and **Collapse all** buttons on GraphQL pages so they respect fields expanded or collapsed manually.
|
|
32
|
+
- Updated dependencies [a4e681b2665]
|
|
33
|
+
- @redocly/api-docs@0.4.0-next.10
|
|
34
|
+
|
|
35
|
+
## 0.139.0-next.9
|
|
36
|
+
|
|
37
|
+
### Minor Changes
|
|
38
|
+
|
|
39
|
+
- bb237d4d6af: Added the **Copy MCP server URL** page action and reordered the default MCP page actions to **Connect to Claude**, **Connect to VS Code**, then **Connect to Cursor**.
|
|
40
|
+
- 5528de79174: Added Grok setup instructions to the MCP server page.
|
|
41
|
+
- 366a568158c: Added the **deprecated** badges to the **Try it** console to mark deprecated operations and security schemes and to match the badges on the API reference page.
|
|
42
|
+
- 1897e43b9e6: Added a resize handle between the name and value columns of the parameter tables in the **Try it** console.
|
|
43
|
+
Readers can widen either column to read long parameter names or values.
|
|
44
|
+
|
|
45
|
+
### Patch Changes
|
|
46
|
+
|
|
47
|
+
- ba104a57878: Fixed an issue where **Copy for LLM**, **Open in Claude**, and **Open in ChatGPT** included default credentials and server values stored in the API description.
|
|
48
|
+
- 3abdbf8ec2c: Fixed an issue in OpenAPI docs where request and response samples and schemas for a `discriminator` displayed placeholder values or fields from other options instead of the selected option.
|
|
49
|
+
- d56772035fb: Fixed an issue where GraphQL docs showed argument names in the operation overview list with a capital first letter instead of the case defined in the schema.
|
|
50
|
+
- b8b28dd3892: Improved page load times on pages that don't use GraphQL.
|
|
51
|
+
- 1cb19b59c68: Fixed an issue in API docs where the example selected in the request samples and in **Try it** got out of sync.
|
|
52
|
+
- e9df1370508: Fixed an issue where the `sentiment`, `rating`, `mood`, and `scale` feedback forms didn't display the **Submit** button for anonymous users when `comment.hide` was set to `true` and no reasons were configured.
|
|
53
|
+
- 30084fabe22: Fixed an issue in Markdown pages and API docs where the Copy button label in page actions was highlighted when users selected the page title.
|
|
54
|
+
- aecc0761d29: Improved page load by not loading the API reference code on pages that do not show API docs.
|
|
55
|
+
- 57b0acb89cb: Fixed an issue where the mock server rejected valid query parameter, cookie, and form body values that contained URL-encoded characters.
|
|
56
|
+
- e3dcf465a70: Fixed an issue where the `replay-openapi` embed started loading about two seconds after the page and moved the content below it when it appeared.
|
|
57
|
+
- b0fd3d5df14: Fixed OIDC sign-in failures after an identity provider rotated its signing key.
|
|
58
|
+
- 59b42652f83: Fixed an issue where the sidebar highlight and the page URL stayed on the previous section when users scrolled a long distance in one step on Markdown pages and in API reference docs.
|
|
59
|
+
- Updated dependencies [ba104a57878]
|
|
60
|
+
- Updated dependencies [3abdbf8ec2c]
|
|
61
|
+
- Updated dependencies [d56772035fb]
|
|
62
|
+
- Updated dependencies [b8b28dd3892]
|
|
63
|
+
- Updated dependencies [1cb19b59c68]
|
|
64
|
+
- Updated dependencies [bb237d4d6af]
|
|
65
|
+
- Updated dependencies [e9df1370508]
|
|
66
|
+
- Updated dependencies [5528de79174]
|
|
67
|
+
- Updated dependencies [9c7122e817b]
|
|
68
|
+
- Updated dependencies [30084fabe22]
|
|
69
|
+
- Updated dependencies [366a568158c]
|
|
70
|
+
- Updated dependencies [e3dcf465a70]
|
|
71
|
+
- Updated dependencies [59b42652f83]
|
|
72
|
+
- @redocly/api-docs@0.4.0-next.9
|
|
73
|
+
- @redocly/theme@0.71.0-next.6
|
|
74
|
+
- @redocly/realm-asyncapi-sdk@0.17.0-next.1
|
|
75
|
+
- @redocly/portal-plugin-mock-server@0.24.0-next.2
|
|
76
|
+
|
|
77
|
+
## 0.139.0-next.8
|
|
78
|
+
|
|
79
|
+
### Minor Changes
|
|
80
|
+
|
|
81
|
+
- e98769a56c2: Added CSV rendering for request and response examples with a CSV media type.
|
|
82
|
+
- 173a70ea8b1: Added an **Open in Grok** page action, enabled by default.
|
|
83
|
+
- 298fd5a0666: Added a `visibility` Markdoc tag that targets content at humans or at AI agents.
|
|
84
|
+
|
|
85
|
+
### Patch Changes
|
|
86
|
+
|
|
87
|
+
- 9597ef656f7: Fixed an issue in API docs where the title and close button of the security, AsyncAPI server, and GraphQL required scopes dialogs scrolled out of view, and the dialogs did not fit in short browser windows.
|
|
88
|
+
- 9597ef656f7: Fixed an issue in API docs dialogs where the `Tab` key moved focus out of the dialog or skipped links that appeared after the dialog opened.
|
|
89
|
+
- 298fd5a0666: Fixed an issue where custom Markdoc tags in GraphQL descriptions ignored their `renderForLlms` output in AI search and `llms.txt`.
|
|
90
|
+
- c1c61897407: Improved how quickly the mobile navigation menu button responds to taps on slower phones.
|
|
91
|
+
- ced24390fd0: Improved the readability of JSON in the **Try it** console: keys, string values, numbers, and `true`, `false`, and `null` values have distinct colors.
|
|
92
|
+
- d8b32188630: Fixed an issue in the **Try it** console in OpenAPI docs where a search for an operation by its path returned no results.
|
|
93
|
+
- Updated dependencies [e98769a56c2]
|
|
94
|
+
- Updated dependencies [9597ef656f7]
|
|
95
|
+
- Updated dependencies [9597ef656f7]
|
|
96
|
+
- Updated dependencies [173a70ea8b1]
|
|
97
|
+
- Updated dependencies [c1c61897407]
|
|
98
|
+
- Updated dependencies [6823e2a37f8]
|
|
99
|
+
- Updated dependencies [298fd5a0666]
|
|
100
|
+
- @redocly/api-docs@0.4.0-next.8
|
|
101
|
+
- @redocly/theme@0.71.0-next.5
|
|
102
|
+
- @redocly/realm-asyncapi-sdk@0.17.0-next.0
|
|
103
|
+
|
|
104
|
+
## 0.139.0-next.7
|
|
105
|
+
|
|
106
|
+
### Patch Changes
|
|
107
|
+
|
|
108
|
+
- c5e11a6d4ff: Fixed the additional properties label in API docs, which looked like a required property named "name".
|
|
109
|
+
- 194b4cb7650: Fixed an issue where developer onboarding routes didn't respect path prefix.
|
|
110
|
+
- fec5c6c2bdd: Fixed an issue where hovering anywhere in a numbered-list item replaced its number or icon with a link icon.
|
|
111
|
+
- 1b2d2cd0851: Updated `@redocly/openapi-core` to version `2.64.0`.
|
|
112
|
+
- 311a8448281: Fixed an issue in the **Try it** console where the **OpenId Connect URL** field stayed empty for `openIdConnect` security schemes instead of displaying the URL from the API description.
|
|
113
|
+
|
|
114
|
+
Fixed a misleading message in the **Try it** console for `mutualTLS` security schemes that suggested adding an `Authorization` header. Attaching client certificates is not supported: request are sent without them.
|
|
115
|
+
|
|
116
|
+
- 204627e1fd0: Fixed an issue in the **Try it** console where switching to an operation without its own security lost the document-level security.
|
|
117
|
+
As a result, requests were sent without credentials.
|
|
118
|
+
- Updated dependencies [c5e11a6d4ff]
|
|
119
|
+
- Updated dependencies [fec5c6c2bdd]
|
|
120
|
+
- Updated dependencies [1b2d2cd0851]
|
|
121
|
+
- Updated dependencies [204627e1fd0]
|
|
122
|
+
- @redocly/api-docs@0.4.0-next.7
|
|
123
|
+
- @redocly/theme@0.71.0-next.4
|
|
124
|
+
- @redocly/portal-plugin-mock-server@0.24.0-next.1
|
|
125
|
+
|
|
126
|
+
## 0.139.0-next.6
|
|
127
|
+
|
|
128
|
+
### Patch Changes
|
|
129
|
+
|
|
130
|
+
- 1f99eb40dbb: Fixed an issue in the **Try it** console where request body validation reported required `readOnly` properties as missing.
|
|
131
|
+
- d1c8ff2547e: Fixed an issue in the **Try it** console that caused `QUERY` and custom HTTP methods to reach the server as `POST`.
|
|
132
|
+
The console displays an error for `TRACE`, `CONNECT`, and `TRACK` requests, which browsers block.
|
|
133
|
+
- Updated dependencies [652fdc936d2]
|
|
134
|
+
- @redocly/theme@0.71.0-next.3
|
|
135
|
+
- @redocly/api-docs@0.4.0-next.6
|
|
136
|
+
|
|
137
|
+
## 0.139.0-next.5
|
|
138
|
+
|
|
139
|
+
### Patch Changes
|
|
140
|
+
|
|
141
|
+
- 498cecc7a30: Fixed an issue where screen readers announced the close button without a name in **Try it** console.
|
|
142
|
+
- 498cecc7a30: Fixed an issue in **Try it** console where pressing <kbd>Space</kbd> on the focused close button did not close the console.
|
|
143
|
+
- 6409d73811e: Fixed the **Close all tabs** action in the **Try it** panel of API docs to ask for confirmation before it closes open requests and discards entered values.
|
|
144
|
+
- 25f78711989: Fixed an issue in the **Try it** console in OpenAPI docs where the first request left out parameters with an empty example value (`''`, `[]`, or `null`) and query parameters with `allowEmptyValue: true`.
|
|
145
|
+
- Updated dependencies [6409d73811e]
|
|
146
|
+
- Updated dependencies [25f78711989]
|
|
147
|
+
- @redocly/theme@0.71.0-next.2
|
|
148
|
+
- @redocly/api-docs@0.4.0-next.5
|
|
149
|
+
|
|
150
|
+
## 0.139.0-next.4
|
|
151
|
+
|
|
152
|
+
### Patch Changes
|
|
153
|
+
|
|
154
|
+
- Updated dependencies [a52a520badc]
|
|
155
|
+
- @redocly/theme@0.71.0-next.1
|
|
156
|
+
- @redocly/api-docs@0.4.0-next.4
|
|
157
|
+
|
|
158
|
+
## 0.139.0-next.3
|
|
159
|
+
|
|
160
|
+
### Patch Changes
|
|
161
|
+
|
|
162
|
+
- b07968f01e6: Fixed an issue in OpenAPI docs where the samples panel displayed a variant dropdown that had no effect on schemas with an `example` and a nested `oneOf` or `anyOf`.
|
|
163
|
+
- e3bbc9190a3: Updated `@redocly/openapi-core` to version `2.63.0`.
|
|
164
|
+
- 4e08c72bec8: Fixed an issue where Reunite project analytics displayed the number of result categories instead of the number of results for each search query.
|
|
165
|
+
- Updated dependencies [b07968f01e6]
|
|
166
|
+
- Updated dependencies [e3bbc9190a3]
|
|
167
|
+
- @redocly/api-docs@0.4.0-next.3
|
|
168
|
+
- @redocly/portal-plugin-mock-server@0.24.0-next.0
|
|
169
|
+
|
|
170
|
+
## 0.139.0-next.2
|
|
171
|
+
|
|
172
|
+
### Minor Changes
|
|
173
|
+
|
|
174
|
+
- 229406a7c50: Added support for the `encoding` object of `multipart/form-data` bodies in OpenAPI code samples and **Try It**.
|
|
175
|
+
|
|
176
|
+
### Patch Changes
|
|
177
|
+
|
|
178
|
+
- 01e8f8211cf: Fixed an issue in API docs where links to sections of the API description didn't scroll to the section on projects with a path prefix.
|
|
179
|
+
- c836c43c6a9: Fixed an issue in AsyncAPI docs where the **Payload** panel displayed examples from all channel messages on initial page load.
|
|
180
|
+
- Updated dependencies [229406a7c50]
|
|
181
|
+
- Updated dependencies [01e8f8211cf]
|
|
182
|
+
- Updated dependencies [c836c43c6a9]
|
|
183
|
+
- @redocly/api-docs@0.4.0-next.2
|
|
184
|
+
|
|
3
185
|
## 0.139.0-next.1
|
|
4
186
|
|
|
5
187
|
### Patch Changes
|
|
@@ -24,6 +206,16 @@
|
|
|
24
206
|
- @redocly/theme@0.71.0-next.0
|
|
25
207
|
- @redocly/api-docs@0.4.0-next.0
|
|
26
208
|
|
|
209
|
+
## 0.138.1
|
|
210
|
+
|
|
211
|
+
### Patch Changes
|
|
212
|
+
|
|
213
|
+
- 05163ee7071: Fixed an issue where page content jumped to the side while long pages were loading.
|
|
214
|
+
- 6bb2e1e62d0: Fixed security vulnerability `CVE-2026-93687` by removing the `braces` dependency.
|
|
215
|
+
- Updated dependencies [05163ee7071]
|
|
216
|
+
- @redocly/theme@0.70.1
|
|
217
|
+
- @redocly/api-docs@0.3.1
|
|
218
|
+
|
|
27
219
|
## 0.138.0
|
|
28
220
|
|
|
29
221
|
### Minor Changes
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import*as c from"path";import{DEFAULT_THEME_NAME as i,USER_THEME_ALIAS as f}from"../../constants/common.js";import{logger as k}from"../../server/tools/notifiers/logger.js";import{reporter as T}from"../../server/tools/notifiers/reporter.js";import{resolveTheme as A}from"./resolveTheme.js";import{EntitlementsProvider as F}from"../../server/entitlements/entitlements-provider.js";const
|
|
1
|
+
import*as c from"path";import{DEFAULT_THEME_NAME as i,USER_THEME_ALIAS as f}from"../../constants/common.js";import{logger as k}from"../../server/tools/notifiers/logger.js";import{reporter as T}from"../../server/tools/notifiers/reporter.js";import{resolveTheme as A}from"./resolveTheme.js";import{EntitlementsProvider as F}from"../../server/entitlements/entitlements-provider.js";const C=["markdoc/attributes/code-walkthrough-filesets.ts","markdoc/attributes/code-walkthrough-filters.ts","markdoc/components/CodeWalkthrough/**","markdoc/tags/code-step.ts","markdoc/tags/code-toggle.ts","markdoc/tags/code-walkthrough.ts"],m=["./core/**","./markdoc/**/default.*","**/__mocks__/**","**/index.*","**/utils/**/*","**/__tests__/**/*","**/__snapshots__/**/*","**/*.stories.*","**/variables.*",...C],v=["./components/CatalogClassic/CatalogClassicCard.*","./components/ColorModeSwitcher/**","./components/ReplayGate/**","./components/ReplaySecuritySchemeActions/**","./components/ReplayTopBarActions/**","./components/Feedback/**","./components/Filter/**","./components/Footer/**","./components/LanguagePicker/**","./components/Menu/**","./components/Navbar/**","./components/PageNavigation/**","./components/Product/**","./components/Search/**","./components/MissingTranslationNotice/**","./components/NavigationTabs/**","./components/UserMenu/**","./layouts/RootLayout.*","./layouts/CustomContexts.*","./layouts/NotFound.*","./layouts/Forbidden.*","./layouts/DocumentationLayoutTop.*","./layouts/DocumentationLayoutBottom.*","./icons/**","./markdoc/**","./ext/**"];async function L(t){const[p,r]=t._,{theme:l,force:u,onSuccess:d,onError:g,onOverride:h,config:E}=t,y=F.instance(),s=c.resolve(t["project-dir"]);let o=l;o||(o=i);const n=await A(s,E.plugins||[],o,r);n||await T.panicOnContentError(`Theme ${o} not found. Skipping eject.`);const e=n?.config.ejectIgnore;e&&!Array.isArray(e)&&k.warn("'ejectIgnore' must be of type Array. Skipping.");const a=await y.getPackageEjectIgnore(),_={force:u,onSuccess:d,onError:g,onOverride:h,onlyFiles:o===i?v:void 0,ignoreFiles:Array.isArray(e)?[...e,...a,...m]:[...a,...m]};return{objectType:p,pathToThemeFolder:n?.pluginDirAbsolutePath,pathToPortalCustomThemeFolder:c.resolve(s,f),componentToEject:r,theme:o,options:_}}export{m as DEFAULT_IGNORED_FILES,v as EJECTABLE_FILES,L as default};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import n,{useEffect as
|
|
1
|
+
import n,{useEffect as C,useState as a}from"react";import I from"styled-components";import{Button as N}from"@redocly/theme/components/Button/Button";import{Admonition as y}from"@redocly/theme/markdoc/components/Admonition/Admonition";import{withPathPrefix as c,getBaseDataAttributes as q}from"@redocly/theme/core/utils";import{usePageData as w}from"../hooks/usePageData";import{usePreloadHistory as b}from"../usePreloadHistory";import{telemetry as k}from"../telemetry/index.js";import{useLoginUrl as x}from"../hooks";import{apiKeysUrl as R}from"../../../utils/url/api-keys-url";const j=e=>{const{apiId:s,status:t,setStatus:i}=e,u=b(),{userData:r}=w("userData")||{},l=x(),[p,m]=a(),[A,g]=a(),[d,E]=a(!0);C(()=>{r?.isAuthenticated&&fetch(R(`/api-products/${s}/access`)).then(f=>f.json().then(o=>{f.ok?(i(o.status),g(o.appId)):m(o.message)}).catch(()=>m("Something went wrong")).finally(()=>E(!1)))},[r?.isAuthenticated,s,i]);const P=()=>{!r?.isAuthenticated&&l?window.location.href=c(l):t==="ACCEPTED"?u.push(c("/apps/"+(A||""))):t==="NONE"&&u.push(c("/apps/?createApp&apiId="+s)),k.sendRequestApiAccessClickedMessage([q("requestApiAccess","button")])},D=(t==="PENDING"||d||p!=null)&&r?.isAuthenticated;return n.createElement(n.Fragment,null,n.createElement(N,{disabled:D,onClick:P,fullWidth:!0,size:"small"},B(t,d,p,!!r?.isAuthenticated)))},B=(e,s,t,i)=>{if(!i)return"Request access";if(s)return"Loading...";if(t)return"Failed to check access";switch(e){case"NONE":return"Request access";case"ACCEPTED":return"Credentials";case"PENDING":return"Pending access..."}return null},z=e=>e==="ACCEPTED"?n.createElement(h,{type:"success",name:"You have access to this API"}):e==="PENDING"?n.createElement(h,{type:"info",name:"You have requested access to this API"}):null,h=I(y)`
|
|
2
2
|
margin-top: 0px;
|
|
3
3
|
margin-bottom: var(--spacing-sm);
|
|
4
|
-
`;export{
|
|
4
|
+
`;export{j as RequestAccessButton,z as renderAdmonition};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import*as e from"react";import{MarkdownAdapterProvider as
|
|
1
|
+
import*as e from"react";import{MarkdownAdapterProvider as c,RedocExample as l,StoreProvider as E,findExampleEncoding as f,markdocParser as u}from"@redocly/api-docs";import{ErrorMessage as k,OpenApiComponentWrap as x}from"../styled.elements";import{useStore as A}from"../../hooks/use-store";import{usePortalMarkdownAdapter as P}from"./use-markdown-adapter";function S(n){const{descriptionFile:i,pointer:o,options:p,mimeType:a}=n,{store:r,error:m}=A(i),s=P(),t=r?.items,d=e.useMemo(()=>t?f(t,o):void 0,[t,o]);return r?e.createElement(x,{"data-testid":"openapi-example"},e.createElement(E,{options:{...r.options,...p,markdownParser:u},apiStore:r.store},e.createElement(c,{value:s},e.createElement(l,{pointer:o,mimeType:a||"application/json",encoding:d})))):e.createElement(k,null,m)}export{S as OpenApiExample};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import o from"react";import{useLocation as g}from"react-router";import{EmbeddedReplay as k,StoreProvider as I,buildReplayPredefinedEnvValues as P,mergeEnvData as b,useOpenApiDefinition as h,withReplayPrefetch as R,markdocParser as w}from"@redocly/api-docs";import{Admonition as V}from"@redocly/theme/markdoc/components/Admonition/Admonition";import{ErrorMessage as C,OpenApiComponentWrap as D}from"../styled.elements.js";import{useStore as v}from"../../hooks/use-store.js";import{getMockServerDocsConfig as y}from"../../../../templates/api-docs/mock-server-config.js";import{buildReplayOperationSourceMap as F}from"../../utils/build-replay-operation-source-map.js";import{findApiItem as $}from"../../utils/find-api-item.js";const x=R(function({descriptionFile:p,operationId:r,pointer:n,exampleKey:s,mimeType:e,requestBody:d,parameters:a,environment:i,environments:
|
|
1
|
+
import o from"react";import{useLocation as g}from"react-router";import{EmbeddedReplay as k,StoreProvider as I,buildReplayPredefinedEnvValues as P,mergeEnvData as b,useOpenApiDefinition as h,withReplayPrefetch as R,markdocParser as w}from"@redocly/api-docs";import{Admonition as V}from"@redocly/theme/markdoc/components/Admonition/Admonition";import{ErrorMessage as C,OpenApiComponentWrap as D}from"../styled.elements.js";import{useStore as v}from"../../hooks/use-store.js";import{getMockServerDocsConfig as y}from"../../../../templates/api-docs/mock-server-config.js";import{buildReplayOperationSourceMap as F}from"../../utils/build-replay-operation-source-map.js";import{findApiItem as $}from"../../utils/find-api-item.js";const x=R(function({descriptionFile:p,operationId:r,pointer:n,exampleKey:s,mimeType:e,requestBody:d,parameters:a,environment:i,environments:c,hideOtherSecuritySchemes:m}){const f=g(),{store:t,baseSlug:S}=v(p),u=h(),O=o.useMemo(()=>{if(!u)return{};const M=y(t?.options?.mockServer,S??""),A=P(u,M);return b(A,c??{})},[u,t?.options?.mockServer,S,c]),E=o.useMemo(()=>t?.items?F(t.items,{pointer:n,sourceId:r},{mimeType:e,exampleKey:s},t.store?.exampleStore??{}):new Map,[t?.items,t?.store?.exampleStore,n,r,e,s]);return o.createElement(k,{key:`${f.pathname}-${p}-${r||n}`,activeOperationId:r,fullOpenApi:u,pointer:n,operationSourceMap:E,hideOtherSecuritySchemes:m,predefinedEnvValues:O,allowedEnvironments:i?[i]:void 0,requestValues:{body:d,...a},activeMimeName:e})},{immediate:!0}),J=l=>{const{descriptionFile:p,operationId:r,pointer:n,options:s}=l,{store:e,error:d,baseSlug:a}=v(p),i=o.useMemo(()=>({...e?.options,...s}),[s,e?.options]),c=o.useMemo(()=>({specType:"openapi",...i,mockServer:y(i.mockServer,a??""),basePath:a,markdownParser:w,replayFeatures:e?.options.replayFeatures}),[i,a,e?.options.replayFeatures]),m=o.useMemo(()=>e?.items?.length?$(e.items,{pointer:n,sourceId:r}):void 0,[e?.items,n,r]);if(!e)return o.createElement(C,null,d);if(!m?.content?.meta?.pointer)return o.createElement(V,{type:"danger"},"Cannot find OpenAPI operation by operationId or pointer in ",p);const f=m.content.meta.pointer,t=m.content.meta.sourceId??"";return o.createElement(D,{"data-testid":"replay-openapi"},o.createElement(I,{apiStore:e.store,options:c},o.createElement(x,{...l,pointer:f,operationId:t})))};export{J as ReplayOpenApi};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{useCallback as
|
|
1
|
+
import{useCallback as v,useEffect as D,useMemo as L,useState as S,useRef as A}from"react";import{SEARCH_DEBOUNCE_TIME_MS as U}from"@redocly/theme/core/constants";import{getBaseDataAttributes as B,withPathPrefix as H}from"@redocly/theme/core/utils";import{ServerRoutes as T}from"../../../constants/api";import{SEARCH_GROUP_FACET_FIELD as j,SEARCH_PRODUCT_FIELD as J,SEARCH_VERSION_FIELD as K}from"../../../constants/common";import{debounce as $}from"../../../utils/time/debounce.js";import{useSearchSession as z}from"@redocly/theme/core/contexts";import{useGlobalData as k,useI18nConfig as x}from"../hooks";import{usePageVersions as W}from"../../providers/page-data/hooks";import{useFacets as X}from"./useFacets";import{telemetry as Y}from"../telemetry/index.js";const Z=(n,u,r,l,R,s,F,i,o,d)=>{const{searchSessionId:g}=z(),{currentLocale:E}=x(),f=A(""),p=A(null),h=A(async(e,a)=>{try{F(null);const t=await fetch(H(T.SEARCH),a);if(!t.ok)throw new Error(t.statusText||`Search failed (${t.status})`);if(C(e)){const c=await t.json();l(c.facets),r(c.documents),R(c.groupCounts??{}),p.current=null,e.trim().length>1&&Y.sendSearchQueryMessage([{...B("searchQuery","search"),query:e,resultCount:Object.values(c.documents).flat().length.toString(),searchSessionId:g,...o&&{product:o}}]),s(!1)}}catch(t){if(!C(e))return;p.current={query:e,requestParams:a},r({}),s(!1),F(t instanceof Error?t.message:"An unknown error occurred")}}),C=e=>f.current===e,m=L(()=>$(async(e,a,t,c)=>{if(!e.trim().length&&!a.length){r({}),l({}),R({}),s(!1),F(null),p.current=null;return}const y={method:"POST",headers:{"content-type":"application/json"},body:JSON.stringify({query:e,filter:G(a,c,i),locale:t})};await h.current(e,y)},U),[i?.version,i?.folderId,o]);return D(()=>{d||(s(!0),m(n,u,E,o),f.current=n)},[d,u,E,o,n,m,s]),{retrySearch:v(async()=>{const e=p.current;e&&(s(!0),f.current=e.query,await h.current(e.query,e.requestParams))},[s])}},V=(n,u,r,l,R,s,F,i,o,d)=>{const{currentLocale:g}=x();D(()=>{E(r,n,u,g,l,R,o,d)},[l,o,d?.version,d?.folderId]);const E=v(async(f,p,h,C,m,b,e,a)=>{if(m){const{groupKey:t}=m;i(!0);const y={method:"POST",headers:{"content-type":"application/json"},body:JSON.stringify({query:p,filter:(()=>{const I=b.find(O=>O.field===j);let _=h;return I&&(h.find(q=>q.field===I.field)||(_=[...h,{field:I.field,values:[t]}])),G(_,e,a)})(),loadMore:m,locale:C})},w=await(await fetch(H(T.SEARCH),y)).json(),M=f[t]||[],N=w.documents[t]??[],Q={...f,[t]:[...M,...N]};s(Q),w.groupCounts&&F(I=>({...I,...w.groupCounts})),i(!1)}},[]);return{}};function fe(){const{searchFeatures:n}=k();return{askAi:n?.ai?.enabled}}function me(n,u){const{searchFeatures:r}=k(),[l,R]=S(""),[s,F]=S([]),[i,o]=S({}),[d,g]=S({}),[E,f]=S({}),[p,h]=S(),[C,m]=S(!1),[b,e]=S(null),{facets:a}=X(d),{versions:t=[]}=W()||{},c=t.find(P=>P?.active),{retrySearch:y}=Z(l,s,o,g,f,m,e,c,n,u);return V(l,s,i,p,a,o,f,m,n,c),{query:l,setQuery:R,filter:s,setFilter:F,items:i,isSearchLoading:C,searchError:b,facets:a,groupCounts:E,groupField:j,setLoadMore:h,retrySearch:y,advancedSearch:r?.advanced?.enabled,askAi:r?.ai?.enabled}}function G(n,u,r){return[...n,...u?[{field:J,values:[u]}]:[],...r?[{field:K,values:[...r.default?["default"]:[r.folderId,r.version]]}]:[]]}export{me as useSearch,fe as useSearchFeatures};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const n=150;let r=!1,o=null;function c(){r=!0,o&&clearTimeout(o),o=setTimeout(()=>{r=!1,o=null},150)}function a(){return r}let l=!1;function s(){if(!l){l=!0;for(const t of["scrollTo","scroll","scrollBy"]){const e=window[t].bind(window);window[t]=(
|
|
1
|
+
const n=150;let r=!1,o=null;function c(){r=!0,o&&clearTimeout(o),o=setTimeout(()=>{r=!1,o=null},150)}function a(){return r}let l=!1;function s(){if(!l){l=!0;for(const t of["scrollTo","scroll","scrollBy"]){const e=window[t].bind(window);window[t]=(...i)=>{c(),e(...i)}}}}export{n as SCROLL_SETTLE_MS,s as installProgrammaticScrollMarking,a as isProgrammaticScrollEvent,c as markProgrammaticScroll};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{buildApiDocsAgentTools as e}from"@redocly/api-docs";import{fetchText as i,markdownPathForRoute as l}from"./shared.js";function u(o,r){return e({items:r.items,store:r.store,resolveDocUrl:o.withPrefix,getOperationDetail:t=>i(o.routeUrl(l(t.url)))})}export{u as buildApiTools};
|
|
1
|
+
import{buildApiDocsAgentTools as e}from"@redocly/api-docs/lib/services/agent-tools/index.js";import{fetchText as i,markdownPathForRoute as l}from"./shared.js";function u(o,r){return e({items:r.items,store:r.store,resolveDocUrl:o.withPrefix,getOperationDetail:t=>i(o.routeUrl(l(t.url)))})}export{u as buildApiTools};
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import{agentErrorResult as o,agentJsonResult as h,agentTextResult as d,collectOperations as v}from"@redocly/api-docs";import{ServerRoutes as b}from"../../../../constants/api.js";import{AGENT_SKILLS_BASE as S}from"../../../../constants/common.js";import{clampLimit as P,fetchText as
|
|
1
|
+
import{agentErrorResult as o,agentJsonResult as h,agentTextResult as d,collectOperations as v}from"@redocly/api-docs/lib/services/agent-tools/index.js";import{ServerRoutes as b}from"../../../../constants/api.js";import{AGENT_SKILLS_BASE as S}from"../../../../constants/common.js";import{clampLimit as P,fetchText as f,isRecord as m,joinField as g,markdownPathForRoute as T,toSitePath as y}from"./shared.js";const A=`${S}/index.json`,_="mcp",O="webmcp-browser-agent",R="/llms.txt",w=10,E=50,H=3;function G(e){return[...e.feedbackHidden?[]:[U(e)],{name:"get_current_page",title:"Get current page",description:"Report which documentation page the user is looking at right now, including the product and version in scope and whether it is an API reference page. Call this first so an answer matches what is on screen.",inputSchema:{type:"object",properties:{},additionalProperties:!1},annotations:{readOnlyHint:!0},execute:async()=>j(e)},{name:"search_docs",title:"Search documentation",description:"Search this documentation site and return matching pages with their titles and URLs. Use it to find the page that answers a question before reading it.",inputSchema:{type:"object",properties:{query:{type:"string",description:"What to search for"},limit:{type:"integer",description:`Maximum number of results, ${w} by default`}},required:["query"],additionalProperties:!1},annotations:{readOnlyHint:!0,untrustedContentHint:!0},execute:async t=>C(e,t)},{name:"read_page",title:"Read a page",description:"Return the full Markdown source of a documentation page. Omit the url to read the page the user is currently on.",inputSchema:{type:"object",properties:{url:{type:"string",description:"Site-relative page path, for example /guides/quickstart"}},additionalProperties:!1},annotations:{readOnlyHint:!0,untrustedContentHint:!0},execute:async t=>L(e,t)},{name:"get_site_overview",title:"Get site overview",description:"Return the outline of this documentation site: its sections and the pages inside them, limited to what the current user may see. Use it to orient before searching.",inputSchema:{type:"object",properties:{},additionalProperties:!1},annotations:{readOnlyHint:!0,untrustedContentHint:!0},execute:async()=>q(e)},{name:"read_skill",title:"Read an agent skill",description:"List the agent skills this site publishes, or read one by name. A skill explains how to carry out a task against the documented product.",inputSchema:{type:"object",properties:{name:{type:"string",description:"Skill name; omit to list every skill"}},additionalProperties:!1},annotations:{readOnlyHint:!0,untrustedContentHint:!0},execute:async t=>M(e,t)},{name:"navigate_page",title:"Open a page",description:"Move the browser tab to another page of this documentation site, so the user sees what an answer is based on. Accepts site-relative paths only.",inputSchema:{type:"object",properties:{url:{type:"string",description:"Site-relative page path, optionally with a #section anchor"}},required:["url"],additionalProperties:!1},annotations:{readOnlyHint:!1},execute:async t=>D(e,t)}]}async function j(e){const t=e.versions.find(n=>n.active);return h({url:e.pathname,title:e.pageTitle??document.title,locale:e.locale,product:e.product,version:t?.label??t?.version,isApiReference:!!e.apiDocs,...e.apiDocs?{apiBasePath:e.withPrefix(e.apiDocs.baseSlug),apiSpecType:e.apiDocs.store.specType,operationCount:v(e.apiDocs.items).length}:{}})}async function C(e,t){const n=typeof t.query=="string"?t.query.trim():"";if(!n)return o("Provide a query to search for.");const i=P(t.limit,w,E),a=await fetch(e.sitePathUrl(b.SEARCH),{method:"POST",headers:{"content-type":"application/json"},body:JSON.stringify({query:n,locale:e.locale})});if(!a.ok)return o(`Search failed with status ${a.status}.`);const r=await a.json(),s=m(r)&&m(r.documents)?r.documents:{},u=Object.entries(s).flatMap(([c,p])=>(Array.isArray(p)?p:[]).map(l=>({group:c,item:l}))).slice(0,i).map(({group:c,item:p})=>{const l=p.document;return{title:g(l?.title),url:l?.url&&e.withPrefix(l.url),section:c,method:l?.httpMethod?l.httpMethod.toUpperCase():void 0,path:l?.httpMethod?g(l.httpPath):void 0,deprecated:l?.deprecated?!0:void 0,snippet:g(l?.text).slice(0,300)}});return u.length?h({query:n,resultCount:u.length,results:u}):d(`No documentation pages matched "${n}".`)}async function L(e,t){const n=typeof t.url=="string"&&t.url.trim()?t.url.trim():e.pathname,i=y(n);if(!i)return o('Provide a site-relative path that starts with "/".');const a=await f(e.routeUrl(T(i)));return a?d(a):o(`${i} has no Markdown version. Either the path is wrong, or the page is built from code rather than Markdown. Use search_docs to find a documentation page.`)}async function q(e){const t=k(e.sidebarItems,e.withPrefix,0);if(t.length)return h({product:e.product,pages:t});const n=await f(e.sitePathUrl(R));return n?d(n):o("This site publishes no navigation tree.")}function k(e,t,n){if(n>=H)return[];const i=[];for(const a of e){if(!m(a))continue;const r=typeof a.label=="string"?a.label:"",s=typeof a.link=="string"?a.link:void 0;if(!r&&!s)continue;const u=Array.isArray(a.items)?k(a.items,t,n+1):[];i.push({title:r,...s?{url:t(s)}:{},...u.length?{pages:u}:{}})}return i}async function M(e,t){const n=await fetch(e.sitePathUrl(A),{headers:{accept:"application/json"}});if(!n.ok)return o("This site does not publish agent skills.");const i=await n.json(),a=m(i)&&Array.isArray(i.skills)?i.skills:[],r=typeof t.name=="string"?t.name.trim():"";if(!r)return h({skills:a.map(c=>({name:c.name,description:c.description}))});const s=a.find(c=>c.name.toLowerCase()===r.toLowerCase());if(!s){const c=a.map(p=>p.name).join(", ");return o(`No skill named "${r}". Available skills: ${c||"none"}.`)}const u=await f(e.routeUrl(s.url));return u?d(u):o(`The "${s.name}" skill could not be read.`)}function U(e){return{name:"leave_feedback",title:"Leave feedback on a page",description:"Report that a documentation page is wrong, outdated, confusing or incomplete. Use it only when the user agrees, and summarize the problem in their words. Reports reach the team that owns the page.",inputSchema:{type:"object",properties:{summary:{type:"string",description:"One sentence naming the problem"},details:{type:"string",description:"What is wrong and what the page should say"},url:{type:"string",description:"Site-relative path of the page; the current page by default"}},required:["summary"],additionalProperties:!1},annotations:{readOnlyHint:!1,consequentialHint:!0},execute:async t=>$(e,t)}}async function $(e,t){const n=typeof t.summary=="string"?t.summary.trim():"";if(!n)return o("Describe the problem in one sentence.");const i=typeof t.details=="string"?t.details.trim():"",a=typeof t.url=="string"&&t.url.trim()?t.url.trim():e.pathname,r=y(a);if(!r)return o('Provide a site-relative path that starts with "/".');const s=await fetch(e.sitePathUrl(b.FEEDBACK),{method:"POST",headers:{"content-type":"application/json"},body:JSON.stringify({component:"comment",path:e.routeUrl(r),comment:i?`${n}
|
|
2
2
|
|
|
3
|
-
${i}`:n,agent:O,origin:_})});return s.ok?d(`Thanks. The feedback about ${r} reached the documentation team.`):o(s.status===403||s.status===404?`Feedback cannot be left for ${r}.`:`Feedback could not be sent, status ${s.status}.`)}async function
|
|
3
|
+
${i}`:n,agent:O,origin:_})});return s.ok?d(`Thanks. The feedback about ${r} reached the documentation team.`):o(s.status===403||s.status===404?`Feedback cannot be left for ${r}.`:`Feedback could not be sent, status ${s.status}.`)}async function D(e,t){const n=typeof t.url=="string"?y(t.url):void 0;return n?(await e.navigate(n),d(`Opened ${n}.`)):o('Provide a site-relative path that starts with "/". This tool cannot leave the documentation site.')}export{G as buildSiteTools};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{useEffect as u,useRef as S}from"react";import{useLocation as h,useNavigate as A}from"react-router";import{withPathPrefix as g}from"@redocly/theme/core/utils";import{useThemeConfig as R}from"@redocly/theme/core/hooks";import{usePageProps as v,usePageSharedData as C,usePageVersions as L,useSidebarItemsData as x}from"../../providers/page-data/hooks";import{useCurrentProduct as D}from"../hooks/products/useCurrentProduct";import{useL10nConfig as U}from"../hooks/useL10nConfig";import{loadAndNavigate as E}from"../utils/loadAndNavigate";import{telemetry as m}from"../telemetry/index.js";import{registerAgentTools as p}from"@redocly/api-docs";import{buildApiTools as O}from"./tools/api-tools.js";import{buildSiteTools as y}from"./tools/site-tools.js";function z(){const r=h(),o=A(),{currentLocale:n}=U(),{versions:b}=L(),T=x(),i=D(),P=v(),s=C("apiDocsStore"),w=s?.baseSlug,a=R().feedback?.hide===!0,c={pathname:r.pathname,pageTitle:P.seo?.title,locale:n,product:i?.name??i?.slug,versions:b,sidebarItems:T,apiDocs:s,feedbackHidden:a,navigate:e=>E({navigate:o,to:e}),withPrefix:g,routeUrl:e=>new URL(e,window.location.origin).toString(),sitePathUrl:e=>new URL(g(e),window.location.origin).toString()},t=S(c);Object.assign(t.current,c),u(()=>{const e=new AbortController;return p(y(t.current),e.signal,d("site")),()=>e.abort()},[a]),u(()=>{const e=t.current.apiDocs;if(!e)return;const l=new AbortController;return p(O(t.current,e),l.signal,d("apiReference")),()=>l.abort()},[w])}const f={id:"agentTools",object:"feature",uri:"urn:redocly:realm:ui:feature:agentTools"};function d(r){return{registered:o=>m.sendAgentToolsRegisteredMessage([{...f,toolCount:o,scope:r}]),called:(o,n)=>m.sendAgentToolCalledMessage([{...f,toolName:o,outcome:n}])}}export{z as useWebMcpTools};
|
|
1
|
+
import{useEffect as u,useRef as S}from"react";import{useLocation as h,useNavigate as A}from"react-router";import{withPathPrefix as g}from"@redocly/theme/core/utils";import{useThemeConfig as R}from"@redocly/theme/core/hooks";import{usePageProps as v,usePageSharedData as C,usePageVersions as L,useSidebarItemsData as x}from"../../providers/page-data/hooks";import{useCurrentProduct as D}from"../hooks/products/useCurrentProduct";import{useL10nConfig as U}from"../hooks/useL10nConfig";import{loadAndNavigate as E}from"../utils/loadAndNavigate";import{telemetry as m}from"../telemetry/index.js";import{registerAgentTools as p}from"@redocly/api-docs/lib/services/agent-tools/index.js";import{buildApiTools as O}from"./tools/api-tools.js";import{buildSiteTools as y}from"./tools/site-tools.js";function z(){const r=h(),o=A(),{currentLocale:n}=U(),{versions:b}=L(),T=x(),i=D(),P=v(),s=C("apiDocsStore"),w=s?.baseSlug,a=R().feedback?.hide===!0,c={pathname:r.pathname,pageTitle:P.seo?.title,locale:n,product:i?.name??i?.slug,versions:b,sidebarItems:T,apiDocs:s,feedbackHidden:a,navigate:e=>E({navigate:o,to:e}),withPrefix:g,routeUrl:e=>new URL(e,window.location.origin).toString(),sitePathUrl:e=>new URL(g(e),window.location.origin).toString()},t=S(c);Object.assign(t.current,c),u(()=>{const e=new AbortController;return p(y(t.current),e.signal,d("site")),()=>e.abort()},[a]),u(()=>{const e=t.current.apiDocs;if(!e)return;const l=new AbortController;return p(O(t.current,e),l.signal,d("apiReference")),()=>l.abort()},[w])}const f={id:"agentTools",object:"feature",uri:"urn:redocly:realm:ui:feature:agentTools"};function d(r){return{registered:o=>m.sendAgentToolsRegisteredMessage([{...f,toolCount:o,scope:r}]),called:(o,n)=>m.sendAgentToolCalledMessage([{...f,toolName:o,outcome:n}])}}export{z as useWebMcpTools};
|
|
@@ -1,8 +1,15 @@
|
|
|
1
|
-
import*as
|
|
1
|
+
import*as o from"react";import{useMemo as i}from"react";import p from"styled-components";import{RedoclyApiDocs as O,createMarkdocAdapter as _}from"@redocly/api-docs";import{LayoutVariant as T}from"@redocly/theme/components/SidebarActions/SidebarActions";import{ThreePanelLayout as x}from"@redocly/theme/layouts/ThreePanelLayout";import{CatalogClassicInfoBlock as B}from"@redocly/theme/components/CatalogClassic/CatalogClassicInfoBlock";import{Breadcrumbs as U}from"@redocly/theme/components/Breadcrumbs/Breadcrumbs";import{MissingTranslationNotice as D}from"@redocly/theme/components/MissingTranslationNotice/MissingTranslationNotice";import{withPathPrefix as s}from"@redocly/theme/core/utils";import{usePageSharedData as I,useUserClaims as M}from"../../app/hooks";import{ServerRoutes as f}from"../../../constants/api.js";import{isBrowser as N}from"../../../utils/env/is-browser.js";import{CLIENT_TELEMETRY_ENABLED as $}from"../../constants/common.js";import{PACKAGE_NAME as H}from"../../../config/product-gates";import{applyPathPrefixToApiItems as Y,safeParseFunction as V,useCollectMarkdocOptions as W}from"./helpers";function z({pageProps:{markdown:c,apiOptions:u,metadata:A}}){const g=I("apiDocsStore"),{items:l,options:e,store:R,baseSlug:r}=g,a=N(),E=M(),n=W(c,e.markdocOptions),d=i(()=>s(r),[r]),v=i(()=>d===r?l:Y(l),[l,r,d]),y=i(()=>_(n,e),[n,e]),C=i(()=>{const L=a?`${window.location.origin}${s(f.REPLAY_OAUTH2_CALLBACK)}`:void 0;let m=e.corsProxyUrl;if(m===void 0){const t=s(`${f.CORS_PROXY}/`);m=a?new URL(t,window.location.origin).toString():t}const h=e.events,P=h?Object.entries(h).reduce((t,[S,b])=>{const w=V(b);return w&&(t[S]=w),t},{}):void 0;return{...e,markdocOptions:n,oAuth2RedirectURI:L,corsProxyUrl:m,userClaims:E,...P&&{events:P},unstable_hooks:{...e.unstable_hooks,MiddlePanelHeader:()=>o.createElement(o.Fragment,null,o.createElement(U,null),o.createElement(F,null))}}},[e,n,a,E]);if(!g)return o.createElement("div",null,"Something went wrong");const k=a?{collectorUrl:new URL(s(f.OTEL_TRACES),window.location.origin).toString(),disabled:!$,serviceVersion:`${H}@${process.env.REDOCLY_PORTAL_VERSION}`}:void 0;return o.createElement(j,null,o.createElement(K,{layout:u?.layout},o.createElement(B,{metadata:A})),o.createElement(O,{items:v,store:R,basePath:d,options:C,markdownAdapter:y,layout:u?.layout,telemetryConfig:k}))}const F=p(D)`
|
|
2
|
+
width: 100%;
|
|
3
|
+
`,K=p(x)`
|
|
2
4
|
&& {
|
|
3
|
-
padding-right: ${({layout:c})=>c===
|
|
5
|
+
padding-right: ${({layout:c})=>c===T.THREE_PANEL?"calc(var(--panel-gap-horizontal) * 2)":"var(--panel-gap-horizontal)"};
|
|
4
6
|
}
|
|
5
|
-
|
|
7
|
+
|
|
8
|
+
/* Hide the catalog info block (scorecard badge) when api-docs renders its 404 or error fallback page. */
|
|
9
|
+
&:has(~ .not-found-page, ~ .api-docs-error-page) {
|
|
10
|
+
display: none;
|
|
11
|
+
}
|
|
12
|
+
`,j=p.main`
|
|
6
13
|
div[id],
|
|
7
14
|
a[id],
|
|
8
15
|
a[data-section-id],
|
|
@@ -15,9 +22,4 @@ import*as e from"react";import{useMemo as i}from"react";import A from"styled-com
|
|
|
15
22
|
}
|
|
16
23
|
|
|
17
24
|
--sidebar-width: 0px;
|
|
18
|
-
|
|
19
|
-
/* Hide the catalog info block (scorecard badge) when api-docs renders its 404 or error fallback page. */
|
|
20
|
-
&:has(.not-found-page, .api-docs-error-page) ${R} {
|
|
21
|
-
display: none;
|
|
22
|
-
}
|
|
23
25
|
`;export{z as default};
|
|
@@ -115,6 +115,7 @@ export declare const FEATURE: {
|
|
|
115
115
|
readonly mcpRequestQuotaPerDay: 'mcpRequestQuotaPerDay';
|
|
116
116
|
readonly banner: 'banner';
|
|
117
117
|
readonly cookieConsent: 'cookieConsent';
|
|
118
|
+
readonly sdkGeneration: 'sdkGeneration';
|
|
118
119
|
};
|
|
119
120
|
export declare const GATEWAY_FETCH_LIMIT_DEFAULTS: {
|
|
120
121
|
readonly ratePerMin: 60;
|
package/dist/constants/common.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const n={AUTHORIZATION:"authorization",IDP_ID_TOKEN:"idp_id_token",IDP_ACCESS_TOKEN:"idp_access_token",IDP_REFRESH_TOKEN:"idp_refresh_token",FEDERATED_ACCESS_TOKEN:"federated_access_token",FEDERATED_ID_TOKEN:"federated_id_token"},s="post_logout",_="openapi_docs",E="asyncapi_docs",p="graphql_docs",i="api_docs",A="/_spec-gql",S="markdoc",d="tags",a="*",T={[a]:"read"},L=["openid","email"],I=1440*60,R=720*60*60,O="anonymous",P="authenticated",l="**",C="Reunite",x="translations.yaml",D="redocly.yaml",u="@redocly/theme",m="@theme",M="@skills",N="SKILL.md",g="/.well-known/agent-skills",U="/.well-known/agent-card.json",F="/a2a",h="/.well-known/mcp/server-card.json",y="/app-data.json",k="/eject-component";var t;(function(e){e.BUILD="build",e.DEVELOP="develop",e.PREPARE="prepare"})(t||(t={}));var o;(function(e){e.RATING="rating",e.SENTIMENT="sentiment",e.COMMENT="comment",e.MOOD="mood",e.PROBLEM="problem",e.SCALE="scale"})(o||(o={}));var r;(function(e){e.AI_SEARCH="aiSearch",e.MCP="mcp"})(r||(r={}));const G="/login",b="/invite",v={AUTH0_PASS:"/auth/auth0-pass"},H={NotExist:"ENOENT"},w="default_locale",K="sidebar-",B="PUBLIC_",q="branch.",f=["BROKEN_LINK","MARKDOC","RESOLVE"],V=["logo","navbar","products","footer","sidebar","scripts","links","feedback","search","aiAssistant","colorMode","palette","navigation","codeSnippet","markdown","openapi","graphql","analytics","consent","userMenu","versionPicker","breadcrumbs","catalog","entitiesCatalog","scorecard","scorecards","scorecardClassic","mcp","banner"],c="redocly_category",Q="redocly_product",j="redocly_version",X="redocly_teams",W=c,z={asyncapi:"asyncapi",apiFunctions:"apiFunctions",reactPages:"reactPages",catalog:"catalog",catalogClassic:"catalogClassic",lint:"lint",scorecard:"scorecard",scorecards:"scorecards",l10n:"l10n",openapi:"openapi",graphql:"graphql",markdown:"markdown",devOnboarding:"devOnboarding",seo:"seo",redirects:"redirects",customPlugins:"customPlugins",themeEjecting:"themeEjecting",products:"products",breadcrumbs:"breadcrumbs",mockServer:"mockServer",sso:"sso",rbac:"rbac",analytics:"analytics",removeAttribution:"removeAttribution",advancedSearch:"advancedSearch",soap:"soap",ssoDirect:"ssoDirect",codeWalkthrough:"codeWalkthrough",aiSearchLimit:"aiSearchLimit",kvStorageLimit:"kvStorageLimit",mcp:"mcp",mcpGateway:"mcpGateway",mcpMode:"mcpMode",gatewayFetchRatePerMin:"gatewayFetchRatePerMin",gatewayFetchQuotaPerDay:"gatewayFetchQuotaPerDay",gatewayFetchBudgetPerExec:"gatewayFetchBudgetPerExec",mcpRequestRatePerMin:"mcpRequestRatePerMin",mcpRequestQuotaPerDay:"mcpRequestQuotaPerDay",banner:"banner",cookieConsent:"cookieConsent",sdkGeneration:"sdkGeneration"},J={ratePerMin:60,quotaPerDay:2e3,budgetPerExec:25},Y={ratePerMin:600,quotaPerDay:2e4};export{F as A2A_SLUG,U as AGENT_CARD_SLUG,g as AGENT_SKILLS_BASE,i as API_DOCS_TEMPLATE_ID,E as ASYNC_API_DOCS_TEMPLATE_ID,n as AuthCookieNames,q as BRANCH_ENV_PREFIX,D as CONFIG_FILE_NAME,S as CUSTOM_MARKDOC_OPTIONS_PATH,d as CUSTOM_MARKDOC_TAGS_PATH,O as DEFAULT_ANONYMOUS_VISITOR_TEAM,P as DEFAULT_AUTHENTICATED_TEAM,I as DEFAULT_COOKIE_EXPIRATION,w as DEFAULT_LOCALE_PLACEHOLDER,l as DEFAULT_RBAC_SCOPE,C as DEFAULT_SSO_IDP_TITLE,u as DEFAULT_THEME_NAME,G as DEV_LOGIN_SLUG,k as EJECT_COMPONENT_URL,v as ExternalRoutes,z as FEATURE,o as FEEDBACK_TYPES,H as FsErrors,J as GATEWAY_FETCH_LIMIT_DEFAULTS,y as GLOBAL_DATA_URL,A as GRAPHQL_SPEC_SLUG,p as GRAPHQL_TEMPLATE_ID,b as INVITE_SLUG,f as MARKDOC_ERROR_TYPES,Y as MCP_REQUEST_LIMIT_DEFAULTS,h as MCP_SERVER_CARD_SLUG,_ as OPENAPI_DOCS_TEMPLATE_ID,R as POST_LOGOUT_COOKIE_EXPIRATION,s as POST_LOGOUT_COOKIE_NAME,B as PUBLIC_ENV_PREFIX,T as PUBLIC_RBAC_SCOPE_ITEM,a as RBAC_ALL_OTHER_TEAMS,L as REQUIRED_OIDC_SCOPES,r as RbacFeatures,c as SEARCH_CATEGORY_FIELD,W as SEARCH_GROUP_FACET_FIELD,Q as SEARCH_PRODUCT_FIELD,X as SEARCH_RBAC_FIELD,j as SEARCH_VERSION_FIELD,K as SIDEBAR_PREFIX,x as TRANSLATIONS_FILE_NAME,V as UI_ACCESSIBLE_CONFIG_PROPS,M as USER_SKILLS_ALIAS,N as USER_SKILL_FILENAME,m as USER_THEME_ALIAS,t as cliCommandNames};
|