@kubb/adapter-oas 5.0.0-beta.22 → 5.0.0-beta.23

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/dist/index.cjs CHANGED
@@ -2031,14 +2031,17 @@ function createInputStream({ schemas, parseSchema, parseOperation, baseOas, pars
2031
2031
  //#endregion
2032
2032
  //#region src/adapter.ts
2033
2033
  /**
2034
- * Stable string identifier for the OAS adapter used in Kubb's adapter registry.
2034
+ * Canonical adapter name for `@kubb/adapter-oas`. Used for driver lookups.
2035
2035
  */
2036
2036
  const adapterOasName = "oas";
2037
2037
  /**
2038
- * Creates the default OpenAPI / Swagger adapter for Kubb.
2038
+ * Default Kubb adapter for OpenAPI 2.0, 3.0, and 3.1 specifications. Reads the
2039
+ * file at `input.path`, validates it, resolves the base URL, and converts every
2040
+ * schema and operation into the universal AST that every downstream plugin
2041
+ * consumes.
2039
2042
  *
2040
- * Parses the spec, optionally validates it, resolves the base URL, and converts
2041
- * everything into an `InputNode` that downstream plugins consume.
2043
+ * Configure once on `defineConfig`. The adapter's choices (date representation,
2044
+ * integer width, server URL) apply to every plugin in the build.
2042
2045
  *
2043
2046
  * @example
2044
2047
  * ```ts
@@ -2047,8 +2050,13 @@ const adapterOasName = "oas";
2047
2050
  * import { pluginTs } from '@kubb/plugin-ts'
2048
2051
  *
2049
2052
  * export default defineConfig({
2050
- * adapter: adapterOas({ dateType: 'date', serverIndex: 0 }),
2051
- * input: { path: './openapi.yaml' },
2053
+ * input: { path: './petStore.yaml' },
2054
+ * output: { path: './src/gen' },
2055
+ * adapter: adapterOas({
2056
+ * serverIndex: 0,
2057
+ * discriminator: 'inherit',
2058
+ * dateType: 'date',
2059
+ * }),
2052
2060
  * plugins: [pluginTs()],
2053
2061
  * })
2054
2062
  * ```