@scalar/workspace-store 0.40.2 → 0.40.4
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 +13 -0
- package/dist/client.d.ts +7 -2
- package/dist/client.d.ts.map +1 -1
- package/dist/client.js +820 -681
- package/dist/entities/auth/index.js +96 -101
- package/dist/entities/auth/schema.d.ts +10 -0
- package/dist/entities/auth/schema.d.ts.map +1 -1
- package/dist/entities/auth/schema.js +42 -116
- package/dist/entities/history/index.js +80 -60
- package/dist/entities/history/schema.js +94 -88
- package/dist/events/bus.js +146 -93
- package/dist/events/definitions/analytics.js +1 -1
- package/dist/events/definitions/auth.js +1 -1
- package/dist/events/definitions/common.js +1 -1
- package/dist/events/definitions/cookie.js +1 -1
- package/dist/events/definitions/document.js +1 -1
- package/dist/events/definitions/environment.js +1 -1
- package/dist/events/definitions/hooks.js +1 -1
- package/dist/events/definitions/index.js +1 -1
- package/dist/events/definitions/meta.js +1 -1
- package/dist/events/definitions/operation.js +1 -1
- package/dist/events/definitions/server.js +1 -1
- package/dist/events/definitions/tabs.js +1 -1
- package/dist/events/definitions/tag.js +1 -1
- package/dist/events/definitions/ui.js +1 -1
- package/dist/events/definitions/workspace.js +1 -1
- package/dist/events/index.js +3 -9
- package/dist/events/listeners.js +20 -22
- package/dist/events/old-definitions.js +15 -12
- package/dist/helpers/deep-clone.js +33 -17
- package/dist/helpers/detect-changes-proxy.js +95 -57
- package/dist/helpers/general.js +78 -23
- package/dist/helpers/generate-unique-value.js +77 -45
- package/dist/helpers/get-fetch.js +12 -10
- package/dist/helpers/get-resolved-ref.js +11 -10
- package/dist/helpers/is-non-optional-security-requirement.js +3 -6
- package/dist/helpers/merge-object.js +71 -30
- package/dist/helpers/overrides-proxy.js +98 -58
- package/dist/helpers/unpack-proxy.js +60 -58
- package/dist/mutators/auth.js +358 -230
- package/dist/mutators/cookie.js +59 -42
- package/dist/mutators/document.js +104 -66
- package/dist/mutators/environment.js +97 -72
- package/dist/mutators/helpers.js +9 -13
- package/dist/mutators/index.js +62 -49
- package/dist/mutators/operation/body.js +88 -57
- package/dist/mutators/operation/extensions.js +20 -12
- package/dist/mutators/operation/helpers/fetch-request-to-har.js +144 -107
- package/dist/mutators/operation/helpers/fetch-response-to-har.js +143 -95
- package/dist/mutators/operation/helpers/get-parameter-position.js +12 -12
- package/dist/mutators/operation/helpers/har-to-operation.js +169 -132
- package/dist/mutators/operation/helpers/sync-path-parameters.js +109 -60
- package/dist/mutators/operation/history.js +60 -64
- package/dist/mutators/operation/index.js +25 -49
- package/dist/mutators/operation/operation.js +349 -240
- package/dist/mutators/operation/parameters.js +157 -93
- package/dist/mutators/server.js +213 -152
- package/dist/mutators/tabs.js +173 -130
- package/dist/mutators/tag.js +131 -97
- package/dist/mutators/workspace.js +72 -42
- package/dist/navigation/get-navigation-options.js +97 -84
- package/dist/navigation/helpers/get-openapi-object.js +46 -29
- package/dist/navigation/helpers/get-operation-entries.js +72 -32
- package/dist/navigation/helpers/get-parent-entry.js +16 -12
- package/dist/navigation/helpers/get-tag-entries.js +56 -29
- package/dist/navigation/helpers/get-tag.js +22 -23
- package/dist/navigation/helpers/get-x-keys.js +13 -9
- package/dist/navigation/helpers/traverse-description.js +90 -72
- package/dist/navigation/helpers/traverse-document.js +111 -98
- package/dist/navigation/helpers/traverse-examples.js +35 -31
- package/dist/navigation/helpers/traverse-paths.js +118 -106
- package/dist/navigation/helpers/traverse-schemas.js +65 -64
- package/dist/navigation/helpers/traverse-tags.js +158 -129
- package/dist/navigation/helpers/traverse-webhooks.js +96 -90
- package/dist/navigation/helpers/update-order-ids.js +59 -51
- package/dist/navigation/helpers/utils.js +71 -21
- package/dist/navigation/index.js +5 -13
- package/dist/navigation/types.js +1 -1
- package/dist/persistence/index.js +283 -285
- package/dist/persistence/indexdb.js +263 -126
- package/dist/plugins/bundler/helpers.js +21 -12
- package/dist/plugins/bundler/index.d.ts +7 -0
- package/dist/plugins/bundler/index.d.ts.map +1 -1
- package/dist/plugins/bundler/index.js +305 -171
- package/dist/plugins/client/index.js +1 -5
- package/dist/plugins/client/persistence.js +95 -90
- package/dist/resolve.js +18 -25
- package/dist/schemas/compose.js +6 -7
- package/dist/schemas/extensions/document/x-internal.js +3 -7
- package/dist/schemas/extensions/document/x-scalar-environments.js +16 -22
- package/dist/schemas/extensions/document/x-scalar-icon.js +3 -7
- package/dist/schemas/extensions/document/x-scalar-ignore.js +3 -7
- package/dist/schemas/extensions/document/x-scalar-is-dirty.js +21 -8
- package/dist/schemas/extensions/document/x-scalar-original-document-hash.js +17 -8
- package/dist/schemas/extensions/document/x-scalar-registry-meta.js +15 -21
- package/dist/schemas/extensions/document/x-scalar-sdk-installation.js +5 -13
- package/dist/schemas/extensions/document/x-scalar-watch-mode.js +4 -8
- package/dist/schemas/extensions/document/x-tags.js +3 -7
- package/dist/schemas/extensions/example/x-disabled.js +17 -7
- package/dist/schemas/extensions/general/x-scalar-active-environment.js +4 -7
- package/dist/schemas/extensions/general/x-scalar-cookies.js +9 -14
- package/dist/schemas/extensions/general/x-scalar-order.js +8 -7
- package/dist/schemas/extensions/operation/index.js +4 -23
- package/dist/schemas/extensions/operation/x-badge.js +42 -50
- package/dist/schemas/extensions/operation/x-code-samples.js +8 -12
- package/dist/schemas/extensions/operation/x-draft-examples.js +3 -7
- package/dist/schemas/extensions/operation/x-post-response.js +18 -7
- package/dist/schemas/extensions/operation/x-scalar-disable-parameters.js +57 -13
- package/dist/schemas/extensions/operation/x-scalar-selected-content-type.js +9 -7
- package/dist/schemas/extensions/operation/x-scalar-stability.js +15 -14
- package/dist/schemas/extensions/parameter/x-global.js +12 -7
- package/dist/schemas/extensions/schema/x-additional-properties-name.js +10 -7
- package/dist/schemas/extensions/schema/x-enum-descriptions.js +17 -12
- package/dist/schemas/extensions/schema/x-enum-varnames.js +21 -8
- package/dist/schemas/extensions/schema/x-examples.js +3 -7
- package/dist/schemas/extensions/schema/x-variable.js +3 -7
- package/dist/schemas/extensions/security/index.js +1 -1
- package/dist/schemas/extensions/security/x-default-scopes.js +16 -7
- package/dist/schemas/extensions/security/x-scalar-credentials-location.js +16 -7
- package/dist/schemas/extensions/security/x-scalar-security-body.js +14 -7
- package/dist/schemas/extensions/security/x-scalar-security-query.js +14 -7
- package/dist/schemas/extensions/security/x-scalar-security-secrets.js +66 -37
- package/dist/schemas/extensions/security/x-tokenName.js +11 -7
- package/dist/schemas/extensions/security/x-use-pkce.js +6 -10
- package/dist/schemas/extensions/server/x-scalar-selected-server.js +3 -7
- package/dist/schemas/extensions/tag/index.js +1 -1
- package/dist/schemas/extensions/tag/x-display-name.js +11 -7
- package/dist/schemas/extensions/tag/x-tag-groups.js +13 -15
- package/dist/schemas/extensions/workspace/index.js +2 -11
- package/dist/schemas/extensions/workspace/x-scalar-active-proxy.js +13 -7
- package/dist/schemas/extensions/workspace/x-scalar-tabs.js +15 -13
- package/dist/schemas/extensions.js +11 -15
- package/dist/schemas/inmemory-workspace.d.ts +6 -0
- package/dist/schemas/inmemory-workspace.d.ts.map +1 -1
- package/dist/schemas/inmemory-workspace.js +13 -21
- package/dist/schemas/navigation.js +48 -85
- package/dist/schemas/reference-config/appearance.js +15 -22
- package/dist/schemas/reference-config/features.js +14 -21
- package/dist/schemas/reference-config/index.d.ts +2 -0
- package/dist/schemas/reference-config/index.d.ts.map +1 -1
- package/dist/schemas/reference-config/index.js +42 -44
- package/dist/schemas/reference-config/meta.js +11 -18
- package/dist/schemas/reference-config/routing.js +7 -14
- package/dist/schemas/reference-config/settings.d.ts +2 -0
- package/dist/schemas/reference-config/settings.d.ts.map +1 -1
- package/dist/schemas/reference-config/settings.js +10 -17
- package/dist/schemas/typebox-coerce.js +23 -6
- package/dist/schemas/v3.1/strict/callback.js +6 -12
- package/dist/schemas/v3.1/strict/components.js +26 -48
- package/dist/schemas/v3.1/strict/contact.js +9 -12
- package/dist/schemas/v3.1/strict/discriminator.js +11 -10
- package/dist/schemas/v3.1/strict/encoding.js +15 -12
- package/dist/schemas/v3.1/strict/example.js +11 -13
- package/dist/schemas/v3.1/strict/external-documentation.js +7 -10
- package/dist/schemas/v3.1/strict/header.js +27 -28
- package/dist/schemas/v3.1/strict/info.js +10 -16
- package/dist/schemas/v3.1/strict/license.js +9 -12
- package/dist/schemas/v3.1/strict/link.js +22 -19
- package/dist/schemas/v3.1/strict/media-type.js +17 -16
- package/dist/schemas/v3.1/strict/oauth-flow.js +28 -62
- package/dist/schemas/v3.1/strict/oauthflows.js +14 -20
- package/dist/schemas/v3.1/strict/openapi-document.d.ts +70 -0
- package/dist/schemas/v3.1/strict/openapi-document.d.ts.map +1 -1
- package/dist/schemas/v3.1/strict/openapi-document.js +126 -210
- package/dist/schemas/v3.1/strict/operation.js +16 -43
- package/dist/schemas/v3.1/strict/parameter.d.ts +6 -0
- package/dist/schemas/v3.1/strict/parameter.d.ts.map +1 -1
- package/dist/schemas/v3.1/strict/parameter.js +29 -35
- package/dist/schemas/v3.1/strict/path-item.js +36 -40
- package/dist/schemas/v3.1/strict/paths.js +8 -11
- package/dist/schemas/v3.1/strict/ref-definitions.js +76 -100
- package/dist/schemas/v3.1/strict/reference.js +18 -21
- package/dist/schemas/v3.1/strict/request-body.js +8 -16
- package/dist/schemas/v3.1/strict/response.js +12 -16
- package/dist/schemas/v3.1/strict/responses.js +13 -11
- package/dist/schemas/v3.1/strict/schema.js +149 -157
- package/dist/schemas/v3.1/strict/security-requirement.js +13 -12
- package/dist/schemas/v3.1/strict/security-scheme.js +29 -41
- package/dist/schemas/v3.1/strict/server-variable.js +9 -12
- package/dist/schemas/v3.1/strict/server.js +10 -13
- package/dist/schemas/v3.1/strict/tag.js +11 -20
- package/dist/schemas/v3.1/strict/type-guards.js +20 -20
- package/dist/schemas/v3.1/strict/xml.js +17 -16
- package/dist/schemas/workspace-specification/index.js +11 -23
- package/dist/schemas/workspace-specification/info.js +4 -8
- package/dist/schemas/workspace.d.ts +6 -0
- package/dist/schemas/workspace.d.ts.map +1 -1
- package/dist/schemas/workspace.js +25 -51
- package/dist/schemas.js +2 -6
- package/dist/server.js +286 -176
- package/dist/workspace-plugin.js +1 -1
- package/package.json +13 -19
- package/dist/client.js.map +0 -7
- package/dist/entities/auth/index.js.map +0 -7
- package/dist/entities/auth/schema.js.map +0 -7
- package/dist/entities/history/index.js.map +0 -7
- package/dist/entities/history/schema.js.map +0 -7
- package/dist/events/bus.js.map +0 -7
- package/dist/events/definitions/analytics.js.map +0 -7
- package/dist/events/definitions/auth.js.map +0 -7
- package/dist/events/definitions/common.js.map +0 -7
- package/dist/events/definitions/cookie.js.map +0 -7
- package/dist/events/definitions/document.js.map +0 -7
- package/dist/events/definitions/environment.js.map +0 -7
- package/dist/events/definitions/hooks.js.map +0 -7
- package/dist/events/definitions/index.js.map +0 -7
- package/dist/events/definitions/meta.js.map +0 -7
- package/dist/events/definitions/operation.js.map +0 -7
- package/dist/events/definitions/server.js.map +0 -7
- package/dist/events/definitions/tabs.js.map +0 -7
- package/dist/events/definitions/tag.js.map +0 -7
- package/dist/events/definitions/ui.js.map +0 -7
- package/dist/events/definitions/workspace.js.map +0 -7
- package/dist/events/index.js.map +0 -7
- package/dist/events/listeners.js.map +0 -7
- package/dist/events/old-definitions.js.map +0 -7
- package/dist/helpers/apply-selective-updates.d.ts +0 -19
- package/dist/helpers/apply-selective-updates.d.ts.map +0 -1
- package/dist/helpers/apply-selective-updates.js +0 -37
- package/dist/helpers/apply-selective-updates.js.map +0 -7
- package/dist/helpers/deep-clone.js.map +0 -7
- package/dist/helpers/detect-changes-proxy.js.map +0 -7
- package/dist/helpers/general.js.map +0 -7
- package/dist/helpers/generate-unique-value.js.map +0 -7
- package/dist/helpers/get-fetch.js.map +0 -7
- package/dist/helpers/get-resolved-ref.js.map +0 -7
- package/dist/helpers/is-non-optional-security-requirement.js.map +0 -7
- package/dist/helpers/merge-object.js.map +0 -7
- package/dist/helpers/overrides-proxy.js.map +0 -7
- package/dist/helpers/unpack-proxy.js.map +0 -7
- package/dist/mutators/auth.js.map +0 -7
- package/dist/mutators/cookie.js.map +0 -7
- package/dist/mutators/document.js.map +0 -7
- package/dist/mutators/environment.js.map +0 -7
- package/dist/mutators/helpers.js.map +0 -7
- package/dist/mutators/index.js.map +0 -7
- package/dist/mutators/operation/body.js.map +0 -7
- package/dist/mutators/operation/extensions.js.map +0 -7
- package/dist/mutators/operation/helpers/fetch-request-to-har.js.map +0 -7
- package/dist/mutators/operation/helpers/fetch-response-to-har.js.map +0 -7
- package/dist/mutators/operation/helpers/get-parameter-position.js.map +0 -7
- package/dist/mutators/operation/helpers/har-to-operation.js.map +0 -7
- package/dist/mutators/operation/helpers/sync-path-parameters.js.map +0 -7
- package/dist/mutators/operation/history.js.map +0 -7
- package/dist/mutators/operation/index.js.map +0 -7
- package/dist/mutators/operation/operation.js.map +0 -7
- package/dist/mutators/operation/parameters.js.map +0 -7
- package/dist/mutators/server.js.map +0 -7
- package/dist/mutators/tabs.js.map +0 -7
- package/dist/mutators/tag.js.map +0 -7
- package/dist/mutators/workspace.js.map +0 -7
- package/dist/navigation/get-navigation-options.js.map +0 -7
- package/dist/navigation/helpers/get-openapi-object.js.map +0 -7
- package/dist/navigation/helpers/get-operation-entries.js.map +0 -7
- package/dist/navigation/helpers/get-parent-entry.js.map +0 -7
- package/dist/navigation/helpers/get-tag-entries.js.map +0 -7
- package/dist/navigation/helpers/get-tag.js.map +0 -7
- package/dist/navigation/helpers/get-x-keys.js.map +0 -7
- package/dist/navigation/helpers/traverse-description.js.map +0 -7
- package/dist/navigation/helpers/traverse-document.js.map +0 -7
- package/dist/navigation/helpers/traverse-examples.js.map +0 -7
- package/dist/navigation/helpers/traverse-paths.js.map +0 -7
- package/dist/navigation/helpers/traverse-schemas.js.map +0 -7
- package/dist/navigation/helpers/traverse-tags.js.map +0 -7
- package/dist/navigation/helpers/traverse-webhooks.js.map +0 -7
- package/dist/navigation/helpers/update-order-ids.js.map +0 -7
- package/dist/navigation/helpers/utils.js.map +0 -7
- package/dist/navigation/index.js.map +0 -7
- package/dist/navigation/types.js.map +0 -7
- package/dist/persistence/index.js.map +0 -7
- package/dist/persistence/indexdb.js.map +0 -7
- package/dist/plugins/bundler/helpers.js.map +0 -7
- package/dist/plugins/bundler/index.js.map +0 -7
- package/dist/plugins/client/index.js.map +0 -7
- package/dist/plugins/client/persistence.js.map +0 -7
- package/dist/resolve.js.map +0 -7
- package/dist/schemas/compose.js.map +0 -7
- package/dist/schemas/extensions/document/x-internal.js.map +0 -7
- package/dist/schemas/extensions/document/x-scalar-environments.js.map +0 -7
- package/dist/schemas/extensions/document/x-scalar-icon.js.map +0 -7
- package/dist/schemas/extensions/document/x-scalar-ignore.js.map +0 -7
- package/dist/schemas/extensions/document/x-scalar-is-dirty.js.map +0 -7
- package/dist/schemas/extensions/document/x-scalar-original-document-hash.js.map +0 -7
- package/dist/schemas/extensions/document/x-scalar-registry-meta.js.map +0 -7
- package/dist/schemas/extensions/document/x-scalar-sdk-installation.js.map +0 -7
- package/dist/schemas/extensions/document/x-scalar-watch-mode.js.map +0 -7
- package/dist/schemas/extensions/document/x-tags.js.map +0 -7
- package/dist/schemas/extensions/example/x-disabled.js.map +0 -7
- package/dist/schemas/extensions/general/x-scalar-active-environment.js.map +0 -7
- package/dist/schemas/extensions/general/x-scalar-cookies.js.map +0 -7
- package/dist/schemas/extensions/general/x-scalar-order.js.map +0 -7
- package/dist/schemas/extensions/operation/index.js.map +0 -7
- package/dist/schemas/extensions/operation/x-badge.js.map +0 -7
- package/dist/schemas/extensions/operation/x-code-samples.js.map +0 -7
- package/dist/schemas/extensions/operation/x-draft-examples.js.map +0 -7
- package/dist/schemas/extensions/operation/x-post-response.js.map +0 -7
- package/dist/schemas/extensions/operation/x-scalar-disable-parameters.js.map +0 -7
- package/dist/schemas/extensions/operation/x-scalar-selected-content-type.js.map +0 -7
- package/dist/schemas/extensions/operation/x-scalar-stability.js.map +0 -7
- package/dist/schemas/extensions/parameter/x-global.js.map +0 -7
- package/dist/schemas/extensions/schema/x-additional-properties-name.js.map +0 -7
- package/dist/schemas/extensions/schema/x-enum-descriptions.js.map +0 -7
- package/dist/schemas/extensions/schema/x-enum-varnames.js.map +0 -7
- package/dist/schemas/extensions/schema/x-examples.js.map +0 -7
- package/dist/schemas/extensions/schema/x-variable.js.map +0 -7
- package/dist/schemas/extensions/security/index.js.map +0 -7
- package/dist/schemas/extensions/security/x-default-scopes.js.map +0 -7
- package/dist/schemas/extensions/security/x-scalar-credentials-location.js.map +0 -7
- package/dist/schemas/extensions/security/x-scalar-security-body.js.map +0 -7
- package/dist/schemas/extensions/security/x-scalar-security-query.js.map +0 -7
- package/dist/schemas/extensions/security/x-scalar-security-secrets.js.map +0 -7
- package/dist/schemas/extensions/security/x-tokenName.js.map +0 -7
- package/dist/schemas/extensions/security/x-use-pkce.js.map +0 -7
- package/dist/schemas/extensions/server/x-scalar-selected-server.js.map +0 -7
- package/dist/schemas/extensions/tag/index.js.map +0 -7
- package/dist/schemas/extensions/tag/x-display-name.js.map +0 -7
- package/dist/schemas/extensions/tag/x-tag-groups.js.map +0 -7
- package/dist/schemas/extensions/workspace/index.js.map +0 -7
- package/dist/schemas/extensions/workspace/x-scalar-active-proxy.js.map +0 -7
- package/dist/schemas/extensions/workspace/x-scalar-tabs.js.map +0 -7
- package/dist/schemas/extensions.js.map +0 -7
- package/dist/schemas/inmemory-workspace.js.map +0 -7
- package/dist/schemas/navigation.js.map +0 -7
- package/dist/schemas/reference-config/appearance.js.map +0 -7
- package/dist/schemas/reference-config/features.js.map +0 -7
- package/dist/schemas/reference-config/index.js.map +0 -7
- package/dist/schemas/reference-config/meta.js.map +0 -7
- package/dist/schemas/reference-config/routing.js.map +0 -7
- package/dist/schemas/reference-config/settings.js.map +0 -7
- package/dist/schemas/typebox-coerce.js.map +0 -7
- package/dist/schemas/v3.1/strict/callback.js.map +0 -7
- package/dist/schemas/v3.1/strict/components.js.map +0 -7
- package/dist/schemas/v3.1/strict/contact.js.map +0 -7
- package/dist/schemas/v3.1/strict/discriminator.js.map +0 -7
- package/dist/schemas/v3.1/strict/encoding.js.map +0 -7
- package/dist/schemas/v3.1/strict/example.js.map +0 -7
- package/dist/schemas/v3.1/strict/external-documentation.js.map +0 -7
- package/dist/schemas/v3.1/strict/header.js.map +0 -7
- package/dist/schemas/v3.1/strict/info.js.map +0 -7
- package/dist/schemas/v3.1/strict/license.js.map +0 -7
- package/dist/schemas/v3.1/strict/link.js.map +0 -7
- package/dist/schemas/v3.1/strict/media-type.js.map +0 -7
- package/dist/schemas/v3.1/strict/oauth-flow.js.map +0 -7
- package/dist/schemas/v3.1/strict/oauthflows.js.map +0 -7
- package/dist/schemas/v3.1/strict/openapi-document.js.map +0 -7
- package/dist/schemas/v3.1/strict/operation.js.map +0 -7
- package/dist/schemas/v3.1/strict/parameter.js.map +0 -7
- package/dist/schemas/v3.1/strict/path-item.js.map +0 -7
- package/dist/schemas/v3.1/strict/paths.js.map +0 -7
- package/dist/schemas/v3.1/strict/ref-definitions.js.map +0 -7
- package/dist/schemas/v3.1/strict/reference.js.map +0 -7
- package/dist/schemas/v3.1/strict/request-body.js.map +0 -7
- package/dist/schemas/v3.1/strict/response.js.map +0 -7
- package/dist/schemas/v3.1/strict/responses.js.map +0 -7
- package/dist/schemas/v3.1/strict/schema.js.map +0 -7
- package/dist/schemas/v3.1/strict/security-requirement.js.map +0 -7
- package/dist/schemas/v3.1/strict/security-scheme.js.map +0 -7
- package/dist/schemas/v3.1/strict/server-variable.js.map +0 -7
- package/dist/schemas/v3.1/strict/server.js.map +0 -7
- package/dist/schemas/v3.1/strict/tag.js.map +0 -7
- package/dist/schemas/v3.1/strict/type-guards.js.map +0 -7
- package/dist/schemas/v3.1/strict/xml.js.map +0 -7
- package/dist/schemas/workspace-specification/index.js.map +0 -7
- package/dist/schemas/workspace-specification/info.js.map +0 -7
- package/dist/schemas/workspace.js.map +0 -7
- package/dist/schemas.js.map +0 -7
- package/dist/server.js.map +0 -7
- package/dist/workspace-plugin.js.map +0 -7
|
@@ -1,62 +1,54 @@
|
|
|
1
|
-
import { Type } from
|
|
2
|
-
|
|
3
|
-
|
|
1
|
+
import { Type } from '@scalar/typebox';
|
|
2
|
+
/**
|
|
3
|
+
* Schema for individual badge configuration in x-badges extension.
|
|
4
|
+
* Badges are indicators that can be displayed in API documentation.
|
|
5
|
+
*/
|
|
6
|
+
export const XBadgeSchema = Type.Object({
|
|
4
7
|
/** The text that displays in the badge. This is required for all badges. */
|
|
5
8
|
name: Type.String({
|
|
6
|
-
|
|
7
|
-
|
|
9
|
+
description: 'The text that displays in the badge',
|
|
10
|
+
minLength: 1,
|
|
8
11
|
}),
|
|
9
12
|
/**
|
|
10
13
|
* The position of the badge in relation to the header.
|
|
11
14
|
* Defaults to 'after' if not specified.
|
|
12
15
|
*/
|
|
13
|
-
position: Type.Optional(
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
})
|
|
18
|
-
),
|
|
16
|
+
position: Type.Optional(Type.Union([Type.Literal('before'), Type.Literal('after')], {
|
|
17
|
+
description: 'The position of the badge in relation to the header',
|
|
18
|
+
default: 'after',
|
|
19
|
+
})),
|
|
19
20
|
/**
|
|
20
21
|
* The color of the badge. Can be defined in various formats such as color keywords,
|
|
21
22
|
* RGB, RGBA, HSL, HSLA, and Hexadecimal.
|
|
22
23
|
*/
|
|
23
|
-
color: Type.Optional(
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
* color: '#ffcc00'
|
|
54
|
-
```
|
|
55
|
-
*/
|
|
56
|
-
"x-badges": Type.Optional(Type.Array(XBadgeSchema))
|
|
24
|
+
color: Type.Optional(Type.String({
|
|
25
|
+
description: 'The color of the badge in various formats (keywords, RGB, RGBA, HSL, HSLA, Hexadecimal)',
|
|
26
|
+
pattern: '^(#([0-9A-Fa-f]{3}){1,2}|rgb\\(\\s*\\d+\\s*,\\s*\\d+\\s*,\\s*\\d+\\s*\\)|rgba\\(\\s*\\d+\\s*,\\s*\\d+\\s*,\\s*\\d+\\s*,\\s*[0-9.]*\\s*\\)|hsl\\(\\s*\\d+\\s*,\\s*\\d+%\\s*,\\s*\\d+%\\s*\\)|hsla\\(\\s*\\d+\\s*,\\s*\\d+%\\s*,\\s*\\d+%\\s*,\\s*[0-9.]*\\s*\\)|[a-zA-Z]+)$',
|
|
27
|
+
})),
|
|
28
|
+
}, {
|
|
29
|
+
description: 'Configuration for a single badge in the x-badges extension',
|
|
30
|
+
});
|
|
31
|
+
export const XBadgesSchema = Type.Object({
|
|
32
|
+
/**
|
|
33
|
+
* You can add badges to operations to use as indicators in documentation. Each operation can have multiple badges, and the displayed color is also configurable. The following example sets badges on the GET `/hello-world` operation:
|
|
34
|
+
*
|
|
35
|
+
* ```yaml
|
|
36
|
+
* openapi: 3.1.0
|
|
37
|
+
* info:
|
|
38
|
+
* title: x-badges
|
|
39
|
+
* version: 1.0.0
|
|
40
|
+
* paths:
|
|
41
|
+
* /hello-world:
|
|
42
|
+
* get:
|
|
43
|
+
* summary: Hello World
|
|
44
|
+
* x-badges:
|
|
45
|
+
* - name: 'Alpha'
|
|
46
|
+
* - name: 'Beta'
|
|
47
|
+
* position: before
|
|
48
|
+
* - name: 'Gamma'
|
|
49
|
+
* position: after
|
|
50
|
+
* color: '#ffcc00'
|
|
51
|
+
```
|
|
52
|
+
*/
|
|
53
|
+
'x-badges': Type.Optional(Type.Array(XBadgeSchema)),
|
|
57
54
|
});
|
|
58
|
-
export {
|
|
59
|
-
XBadgeSchema,
|
|
60
|
-
XBadgesSchema
|
|
61
|
-
};
|
|
62
|
-
//# sourceMappingURL=x-badge.js.map
|
|
@@ -1,15 +1,11 @@
|
|
|
1
|
-
import { Type } from
|
|
1
|
+
import { Type } from '@scalar/typebox';
|
|
2
2
|
const XCodeSampleSchema = Type.Object({
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
3
|
+
lang: Type.Optional(Type.String()),
|
|
4
|
+
label: Type.Optional(Type.String()),
|
|
5
|
+
source: Type.String(),
|
|
6
6
|
});
|
|
7
|
-
const XCodeSamplesSchema = Type.Object({
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
7
|
+
export const XCodeSamplesSchema = Type.Object({
|
|
8
|
+
'x-codeSamples': Type.Optional(Type.Array(XCodeSampleSchema)),
|
|
9
|
+
'x-code-samples': Type.Optional(Type.Array(XCodeSampleSchema)),
|
|
10
|
+
'x-custom-examples': Type.Optional(Type.Array(XCodeSampleSchema)),
|
|
11
11
|
});
|
|
12
|
-
export {
|
|
13
|
-
XCodeSamplesSchema
|
|
14
|
-
};
|
|
15
|
-
//# sourceMappingURL=x-code-samples.js.map
|
|
@@ -1,8 +1,4 @@
|
|
|
1
|
-
import { Type } from
|
|
2
|
-
const XDraftExamplesSchema = Type.Object({
|
|
3
|
-
|
|
1
|
+
import { Type } from '@scalar/typebox';
|
|
2
|
+
export const XDraftExamplesSchema = Type.Object({
|
|
3
|
+
'x-draft-examples': Type.Optional(Type.Array(Type.String())),
|
|
4
4
|
});
|
|
5
|
-
export {
|
|
6
|
-
XDraftExamplesSchema
|
|
7
|
-
};
|
|
8
|
-
//# sourceMappingURL=x-draft-examples.js.map
|
|
@@ -1,8 +1,19 @@
|
|
|
1
|
-
import { Type } from
|
|
2
|
-
|
|
3
|
-
|
|
1
|
+
import { Type } from '@scalar/typebox';
|
|
2
|
+
/**
|
|
3
|
+
* Post response scripts allow to execute arbitrary code after a response is received
|
|
4
|
+
*
|
|
5
|
+
* This is useful for:
|
|
6
|
+
* - Extracting data from the response, or
|
|
7
|
+
* - Testing the response
|
|
8
|
+
*
|
|
9
|
+
* @example
|
|
10
|
+
* ```yaml
|
|
11
|
+
* x-post-response: |
|
|
12
|
+
* pm.test("Status code is 200", () => {
|
|
13
|
+
* pm.response.to.have.status(200)
|
|
14
|
+
* })
|
|
15
|
+
* ```
|
|
16
|
+
*/
|
|
17
|
+
export const XPostResponseSchema = Type.Object({
|
|
18
|
+
'x-post-response': Type.Optional(Type.String()),
|
|
4
19
|
});
|
|
5
|
-
export {
|
|
6
|
-
XPostResponseSchema
|
|
7
|
-
};
|
|
8
|
-
//# sourceMappingURL=x-post-response.js.map
|
|
@@ -1,16 +1,60 @@
|
|
|
1
|
-
import { Type } from
|
|
1
|
+
import { Type } from '@scalar/typebox';
|
|
2
|
+
/**
|
|
3
|
+
* Schema for parameter disabled states within a single example.
|
|
4
|
+
* Maps parameter names (strings) to their disabled state (boolean).
|
|
5
|
+
*/
|
|
2
6
|
const ExampleParameterStateSchema = Type.Record(Type.String(), Type.Boolean());
|
|
7
|
+
/**
|
|
8
|
+
* Schema for all example parameter states across multiple examples.
|
|
9
|
+
* Maps example keys (strings) to their parameter disabled states.
|
|
10
|
+
*/
|
|
3
11
|
const ExamplesParameterStatesSchema = Type.Record(Type.String(), ExampleParameterStateSchema);
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
+
/**
|
|
13
|
+
* Custom OpenAPI extension to track which parameters are disabled across different contexts.
|
|
14
|
+
*
|
|
15
|
+
* This extension allows the API client to persist disabled states for different types of
|
|
16
|
+
* parameters (global cookies, global headers, default headers) across multiple examples.
|
|
17
|
+
*
|
|
18
|
+
* This is necessary because:
|
|
19
|
+
* - Different parameter types have different scopes and behaviors
|
|
20
|
+
* - Users need to disable specific parameters per example without affecting others
|
|
21
|
+
* - The disabled state must persist across sessions
|
|
22
|
+
* - Global parameters can be disabled independently of operation-specific ones
|
|
23
|
+
*
|
|
24
|
+
* Structure:
|
|
25
|
+
* - Top level: Parameter category ("global-cookies", "global-headers", "default-headers")
|
|
26
|
+
* - Second level: Example keys (like "default", "custom-example")
|
|
27
|
+
* - Third level: Parameter names (like "Content-Type", "Cookie")
|
|
28
|
+
* - Values: true = disabled, false = enabled
|
|
29
|
+
*
|
|
30
|
+
* @example
|
|
31
|
+
* ```json
|
|
32
|
+
* {
|
|
33
|
+
* "x-scalar-disable-parameters": {
|
|
34
|
+
* "global-cookies": {
|
|
35
|
+
* "default": {
|
|
36
|
+
* "session": true
|
|
37
|
+
* }
|
|
38
|
+
* },
|
|
39
|
+
* "global-headers": {
|
|
40
|
+
* "default": {
|
|
41
|
+
* "X-API-Key": false
|
|
42
|
+
* }
|
|
43
|
+
* },
|
|
44
|
+
* "default-headers": {
|
|
45
|
+
* "default": {
|
|
46
|
+
* "Content-Type": true,
|
|
47
|
+
* "Accept": false
|
|
48
|
+
* }
|
|
49
|
+
* }
|
|
50
|
+
* }
|
|
51
|
+
* }
|
|
52
|
+
* ```
|
|
53
|
+
*/
|
|
54
|
+
export const XScalarDisableParametersSchema = Type.Object({
|
|
55
|
+
'x-scalar-disable-parameters': Type.Optional(Type.Object({
|
|
56
|
+
'global-cookies': Type.Optional(ExamplesParameterStatesSchema),
|
|
57
|
+
'global-headers': Type.Optional(ExamplesParameterStatesSchema),
|
|
58
|
+
'default-headers': Type.Optional(ExamplesParameterStatesSchema),
|
|
59
|
+
})),
|
|
12
60
|
});
|
|
13
|
-
export {
|
|
14
|
-
XScalarDisableParametersSchema
|
|
15
|
-
};
|
|
16
|
-
//# sourceMappingURL=x-scalar-disable-parameters.js.map
|
|
@@ -1,8 +1,10 @@
|
|
|
1
|
-
import { Type } from
|
|
2
|
-
|
|
3
|
-
|
|
1
|
+
import { Type } from '@scalar/typebox';
|
|
2
|
+
/**
|
|
3
|
+
* Schema for the x-scalar-selected-content-type extension on an OpenAPI operation.
|
|
4
|
+
*
|
|
5
|
+
* The key represents the example name, and the value is the selected content type string.
|
|
6
|
+
* Used by Scalar to track which content type is selected for each example in request or response bodies.
|
|
7
|
+
*/
|
|
8
|
+
export const XScalarSelectedContentTypeSchema = Type.Object({
|
|
9
|
+
'x-scalar-selected-content-type': Type.Optional(Type.Record(Type.String(), Type.String())),
|
|
4
10
|
});
|
|
5
|
-
export {
|
|
6
|
-
XScalarSelectedContentTypeSchema
|
|
7
|
-
};
|
|
8
|
-
//# sourceMappingURL=x-scalar-selected-content-type.js.map
|
|
@@ -1,16 +1,17 @@
|
|
|
1
|
-
import { Type } from
|
|
2
|
-
const XScalarStabilityValues = {
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
1
|
+
import { Type } from '@scalar/typebox';
|
|
2
|
+
export const XScalarStabilityValues = {
|
|
3
|
+
Deprecated: 'deprecated',
|
|
4
|
+
Experimental: 'experimental',
|
|
5
|
+
Stable: 'stable',
|
|
6
6
|
};
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
7
|
+
/**
|
|
8
|
+
* An OpenAPI extension to indicate the stability of the operation
|
|
9
|
+
*
|
|
10
|
+
* @example
|
|
11
|
+
* ```yaml
|
|
12
|
+
* x-scalar-stability: deprecated
|
|
13
|
+
* ```
|
|
14
|
+
*/
|
|
15
|
+
export const XScalarStabilitySchema = Type.Object({
|
|
16
|
+
'x-scalar-stability': Type.Optional(Type.Union([Type.Literal('deprecated'), Type.Literal('experimental'), Type.Literal('stable')])),
|
|
11
17
|
});
|
|
12
|
-
export {
|
|
13
|
-
XScalarStabilitySchema,
|
|
14
|
-
XScalarStabilityValues
|
|
15
|
-
};
|
|
16
|
-
//# sourceMappingURL=x-scalar-stability.js.map
|
|
@@ -1,8 +1,13 @@
|
|
|
1
|
-
import { Type } from
|
|
2
|
-
|
|
3
|
-
|
|
1
|
+
import { Type } from '@scalar/typebox';
|
|
2
|
+
/**
|
|
3
|
+
* OpenAPI extension used by the api-client application to determine if a parameter is considered global in scope
|
|
4
|
+
* for the entire workspace. When set, this parameter will be injected into every request automatically.
|
|
5
|
+
*
|
|
6
|
+
* @example
|
|
7
|
+
* ```yaml
|
|
8
|
+
* x-global: true
|
|
9
|
+
* ```
|
|
10
|
+
*/
|
|
11
|
+
export const XGlobal = Type.Object({
|
|
12
|
+
'x-global': Type.Optional(Type.Boolean()),
|
|
4
13
|
});
|
|
5
|
-
export {
|
|
6
|
-
XGlobal
|
|
7
|
-
};
|
|
8
|
-
//# sourceMappingURL=x-global.js.map
|
|
@@ -1,8 +1,11 @@
|
|
|
1
|
-
import { Type } from
|
|
2
|
-
|
|
3
|
-
|
|
1
|
+
import { Type } from '@scalar/typebox';
|
|
2
|
+
/**
|
|
3
|
+
* x-additionalPropertiesName
|
|
4
|
+
*
|
|
5
|
+
* Custom attribute name for additionalProperties in a schema.
|
|
6
|
+
* This allows specifying a descriptive name for additional properties
|
|
7
|
+
* that may be present in an object.
|
|
8
|
+
*/
|
|
9
|
+
export const XAdditionalPropertiesNameSchema = Type.Object({
|
|
10
|
+
'x-additionalPropertiesName': Type.Optional(Type.String()),
|
|
4
11
|
});
|
|
5
|
-
export {
|
|
6
|
-
XAdditionalPropertiesNameSchema
|
|
7
|
-
};
|
|
8
|
-
//# sourceMappingURL=x-additional-properties-name.js.map
|
|
@@ -1,13 +1,18 @@
|
|
|
1
|
-
import { Type } from
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
1
|
+
import { Type } from '@scalar/typebox';
|
|
2
|
+
/**
|
|
3
|
+
* x-enumDescriptions
|
|
4
|
+
*
|
|
5
|
+
* Maps enum values to their descriptions. Each key should correspond to
|
|
6
|
+
* an enum value, and the value is the description for that enum value.
|
|
7
|
+
*
|
|
8
|
+
* Example:
|
|
9
|
+
* x-enumDescriptions:
|
|
10
|
+
* missing_features: "Missing features"
|
|
11
|
+
* too_expensive: "Too expensive"
|
|
12
|
+
* unused: "Unused"
|
|
13
|
+
* other: "Other"
|
|
14
|
+
*/
|
|
15
|
+
export const XEnumDescriptionsSchema = Type.Object({
|
|
16
|
+
'x-enumDescriptions': Type.Optional(Type.Union([Type.Record(Type.String(), Type.String()), Type.Array(Type.String())])),
|
|
17
|
+
'x-enum-descriptions': Type.Optional(Type.Union([Type.Record(Type.String(), Type.String()), Type.Array(Type.String())])),
|
|
9
18
|
});
|
|
10
|
-
export {
|
|
11
|
-
XEnumDescriptionsSchema
|
|
12
|
-
};
|
|
13
|
-
//# sourceMappingURL=x-enum-descriptions.js.map
|
|
@@ -1,9 +1,22 @@
|
|
|
1
|
-
import { Type } from
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
1
|
+
import { Type } from '@scalar/typebox';
|
|
2
|
+
/**
|
|
3
|
+
* x-enum-varnames
|
|
4
|
+
*
|
|
5
|
+
* Names the enum values, must be in the same order as the enum values.
|
|
6
|
+
*
|
|
7
|
+
* @example
|
|
8
|
+
* ```yaml
|
|
9
|
+
* enum:
|
|
10
|
+
* - moon
|
|
11
|
+
* - asteroid
|
|
12
|
+
* - comet
|
|
13
|
+
* x-enum-varnames:
|
|
14
|
+
* - Moon
|
|
15
|
+
* - Asteroid
|
|
16
|
+
* - Comet
|
|
17
|
+
* ```
|
|
18
|
+
*/
|
|
19
|
+
export const XEnumVarNamesSchema = Type.Object({
|
|
20
|
+
'x-enum-varnames': Type.Optional(Type.Array(Type.String())),
|
|
21
|
+
'x-enumNames': Type.Optional(Type.Array(Type.String())),
|
|
5
22
|
});
|
|
6
|
-
export {
|
|
7
|
-
XEnumVarNamesSchema
|
|
8
|
-
};
|
|
9
|
-
//# sourceMappingURL=x-enum-varnames.js.map
|
|
@@ -1,8 +1,4 @@
|
|
|
1
|
-
import { Type } from
|
|
2
|
-
const XExamplesSchema = Type.Object({
|
|
3
|
-
|
|
1
|
+
import { Type } from '@scalar/typebox';
|
|
2
|
+
export const XExamplesSchema = Type.Object({
|
|
3
|
+
'x-examples': Type.Optional(Type.Record(Type.String(), Type.Unknown())),
|
|
4
4
|
});
|
|
5
|
-
export {
|
|
6
|
-
XExamplesSchema
|
|
7
|
-
};
|
|
8
|
-
//# sourceMappingURL=x-examples.js.map
|
|
@@ -1,8 +1,4 @@
|
|
|
1
|
-
import { Type } from
|
|
2
|
-
const XVariableSchema = Type.Object({
|
|
3
|
-
|
|
1
|
+
import { Type } from '@scalar/typebox';
|
|
2
|
+
export const XVariableSchema = Type.Object({
|
|
3
|
+
'x-variable': Type.Optional(Type.String()),
|
|
4
4
|
});
|
|
5
|
-
export {
|
|
6
|
-
XVariableSchema
|
|
7
|
-
};
|
|
8
|
-
//# sourceMappingURL=x-variable.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
export {};
|
|
@@ -1,8 +1,17 @@
|
|
|
1
|
-
import { Type } from
|
|
2
|
-
|
|
3
|
-
|
|
1
|
+
import { Type } from '@scalar/typebox';
|
|
2
|
+
/**
|
|
3
|
+
* Default selected scopes for the oauth flow
|
|
4
|
+
*
|
|
5
|
+
* @example
|
|
6
|
+
* ```json
|
|
7
|
+
* {
|
|
8
|
+
* "x-default-scopes": [
|
|
9
|
+
* "profile",
|
|
10
|
+
* "email"
|
|
11
|
+
* ]
|
|
12
|
+
* }
|
|
13
|
+
* ```
|
|
14
|
+
*/
|
|
15
|
+
export const XDefaultScopesSchema = Type.Object({
|
|
16
|
+
'x-default-scopes': Type.Optional(Type.Array(Type.String())),
|
|
4
17
|
});
|
|
5
|
-
export {
|
|
6
|
-
XDefaultScopesSchema
|
|
7
|
-
};
|
|
8
|
-
//# sourceMappingURL=x-default-scopes.js.map
|
|
@@ -1,8 +1,17 @@
|
|
|
1
|
-
import { Type } from
|
|
2
|
-
|
|
3
|
-
|
|
1
|
+
import { Type } from '@scalar/typebox';
|
|
2
|
+
/**
|
|
3
|
+
* An OpenAPI extension to specify where OAuth2 credentials should be sent
|
|
4
|
+
*
|
|
5
|
+
* @example
|
|
6
|
+
* ```yaml
|
|
7
|
+
* x-scalar-credentials-location: header
|
|
8
|
+
* ```
|
|
9
|
+
*
|
|
10
|
+
* @example
|
|
11
|
+
* ```yaml
|
|
12
|
+
* x-scalar-credentials-location: body
|
|
13
|
+
* ```
|
|
14
|
+
*/
|
|
15
|
+
export const XScalarCredentialsLocationSchema = Type.Object({
|
|
16
|
+
'x-scalar-credentials-location': Type.Optional(Type.Union([Type.Literal('header'), Type.Literal('body')])),
|
|
4
17
|
});
|
|
5
|
-
export {
|
|
6
|
-
XScalarCredentialsLocationSchema
|
|
7
|
-
};
|
|
8
|
-
//# sourceMappingURL=x-scalar-credentials-location.js.map
|
|
@@ -1,8 +1,15 @@
|
|
|
1
|
-
import { Type } from
|
|
2
|
-
|
|
3
|
-
|
|
1
|
+
import { Type } from '@scalar/typebox';
|
|
2
|
+
/**
|
|
3
|
+
* An OpenAPI extension to set any additional body parameters for the OAuth token request
|
|
4
|
+
*
|
|
5
|
+
* @example
|
|
6
|
+
* ```yaml
|
|
7
|
+
* x-scalar-security-body: {
|
|
8
|
+
* audience: 'https://api.example.com',
|
|
9
|
+
* resource: 'user-profile'
|
|
10
|
+
* }
|
|
11
|
+
* ```
|
|
12
|
+
*/
|
|
13
|
+
export const XScalarSecurityBodySchema = Type.Object({
|
|
14
|
+
'x-scalar-security-body': Type.Optional(Type.Record(Type.String(), Type.String())),
|
|
4
15
|
});
|
|
5
|
-
export {
|
|
6
|
-
XScalarSecurityBodySchema
|
|
7
|
-
};
|
|
8
|
-
//# sourceMappingURL=x-scalar-security-body.js.map
|
|
@@ -1,8 +1,15 @@
|
|
|
1
|
-
import { Type } from
|
|
2
|
-
|
|
3
|
-
|
|
1
|
+
import { Type } from '@scalar/typebox';
|
|
2
|
+
/**
|
|
3
|
+
* An OpenAPI extension set any query parameters for the OAuth authorize request
|
|
4
|
+
*
|
|
5
|
+
* @example
|
|
6
|
+
* ```yaml
|
|
7
|
+
* x-scalar-security-query: {
|
|
8
|
+
* prompt: 'consent',
|
|
9
|
+
* audience: 'scalar'
|
|
10
|
+
* }
|
|
11
|
+
* ```
|
|
12
|
+
*/
|
|
13
|
+
export const XScalarSecurityQuerySchema = Type.Object({
|
|
14
|
+
'x-scalar-security-query': Type.Optional(Type.Record(Type.String(), Type.String())),
|
|
4
15
|
});
|
|
5
|
-
export {
|
|
6
|
-
XScalarSecurityQuerySchema
|
|
7
|
-
};
|
|
8
|
-
//# sourceMappingURL=x-scalar-security-query.js.map
|
|
@@ -1,37 +1,66 @@
|
|
|
1
|
-
import { Type } from
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
});
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
1
|
+
import { Type } from '@scalar/typebox';
|
|
2
|
+
/**
|
|
3
|
+
* A scalar secret token
|
|
4
|
+
*
|
|
5
|
+
* We should not export this when exporting the document
|
|
6
|
+
*/
|
|
7
|
+
export const XScalarSecretTokenSchema = Type.Object({
|
|
8
|
+
'x-scalar-secret-token': Type.String(),
|
|
9
|
+
});
|
|
10
|
+
/**
|
|
11
|
+
* OAuth refresh token
|
|
12
|
+
*
|
|
13
|
+
* We should not export this when exporting the document
|
|
14
|
+
*/
|
|
15
|
+
export const XScalarSecretRefreshTokenSchema = Type.Object({
|
|
16
|
+
'x-scalar-secret-refresh-token': Type.Optional(Type.String()),
|
|
17
|
+
});
|
|
18
|
+
/**
|
|
19
|
+
* OAuth auth url
|
|
20
|
+
*
|
|
21
|
+
* We should not export this when exporting the document
|
|
22
|
+
*/
|
|
23
|
+
export const XScalarAuthUrlSchema = Type.Object({
|
|
24
|
+
'x-scalar-secret-auth-url': Type.Optional(Type.String()),
|
|
25
|
+
});
|
|
26
|
+
/**
|
|
27
|
+
* OAuth token url
|
|
28
|
+
*
|
|
29
|
+
* We should not export this when exporting the document
|
|
30
|
+
*/
|
|
31
|
+
export const XScalarTokenUrlSchema = Type.Object({
|
|
32
|
+
'x-scalar-secret-token-url': Type.Optional(Type.String()),
|
|
33
|
+
});
|
|
34
|
+
/**
|
|
35
|
+
* Username and password for HTTP authentication
|
|
36
|
+
*
|
|
37
|
+
* We should not export this when exporting the document
|
|
38
|
+
*/
|
|
39
|
+
export const XScalarSecretHTTPSchema = Type.Object({
|
|
40
|
+
'x-scalar-secret-username': Type.String(),
|
|
41
|
+
'x-scalar-secret-password': Type.String(),
|
|
42
|
+
});
|
|
43
|
+
/**
|
|
44
|
+
* Oauth client secret
|
|
45
|
+
*
|
|
46
|
+
* We should not export this when exporting the document
|
|
47
|
+
*/
|
|
48
|
+
export const XScalarSecretClientSecretSchema = Type.Object({
|
|
49
|
+
'x-scalar-secret-client-secret': Type.String(),
|
|
50
|
+
});
|
|
51
|
+
/**
|
|
52
|
+
* Oauth client ID
|
|
53
|
+
*
|
|
54
|
+
* We should not export this when exporting the document
|
|
55
|
+
*/
|
|
56
|
+
export const XScalarSecretClientIdSchema = Type.Object({
|
|
57
|
+
'x-scalar-secret-client-id': Type.String(),
|
|
58
|
+
});
|
|
59
|
+
/**
|
|
60
|
+
* Oauth Redirect URI
|
|
61
|
+
*
|
|
62
|
+
* We should not export this when exporting the document
|
|
63
|
+
*/
|
|
64
|
+
export const XScalarSecretRedirectUriSchema = Type.Object({
|
|
65
|
+
'x-scalar-secret-redirect-uri': Type.String(),
|
|
66
|
+
});
|
|
@@ -1,8 +1,12 @@
|
|
|
1
|
-
import { Type } from
|
|
2
|
-
|
|
3
|
-
|
|
1
|
+
import { Type } from '@scalar/typebox';
|
|
2
|
+
/**
|
|
3
|
+
* An OpenAPI extension to specify a custom token name for OAuth2 flows
|
|
4
|
+
*
|
|
5
|
+
* @example
|
|
6
|
+
* ```yaml
|
|
7
|
+
* x-tokenName: 'custom_access_token'
|
|
8
|
+
* ```
|
|
9
|
+
*/
|
|
10
|
+
export const XTokenNameSchema = Type.Object({
|
|
11
|
+
'x-tokenName': Type.Optional(Type.String()),
|
|
4
12
|
});
|
|
5
|
-
export {
|
|
6
|
-
XTokenNameSchema
|
|
7
|
-
};
|
|
8
|
-
//# sourceMappingURL=x-tokenName.js.map
|