Skip to content

Releases: zayne-labs/callapi

@zayne-labs/callapi@1.12.0

06 Mar 14:51
3c2ceec

Choose a tag to compare

Minor Changes

  • 5bf8413: feat: ✨ add refetch functionality to error hooks

    feat(hooks): 🎣 add refetch function to error context options
    feat(refetch): 🔄 implement refetch manager with attempt limiting
    feat(types): 📝 add refetch types and interfaces
    test(refetch): 🧪 add comprehensive refetch test suite
    feat(constants): 📋 add refetchAttempts default value
    refactor(client): 🔧 integrate refetch into fetch client
    refactor(retry): 🛠️ update retry logic for refetch compatibility

@zayne-labs/callapi-plugins@5.0.0

06 Mar 14:51
3c2ceec

Choose a tag to compare

Patch Changes

  • Updated dependencies [5bf8413]
    • @zayne-labs/callapi@1.12.0

@zayne-labs/callapi@1.11.46

28 Jan 12:40
cd9de90

Choose a tag to compare

Patch Changes

  • 3033986: feat(types): ✨ add InferAllMainRoutes utility and improve type inference

    feat(types): 🏷️ introduce InferAllMainRoutes type utility for better route handling
    refactor(types): ♻️ rename InferMethodFromURL to ExtractMethodFromURL for clarity
    refactor(types): 🔧 improve InferAllMainRouteKeys using new utility type
    style(types): 💅 enhance InferMethodOption with stricter generic constraints

@zayne-labs/callapi-plugins@4.0.46

28 Jan 12:40
cd9de90

Choose a tag to compare

Patch Changes

  • Updated dependencies [3033986]
    • @zayne-labs/callapi@1.11.46

@zayne-labs/callapi-plugins@4.0.45

28 Jan 11:00

Choose a tag to compare

@zayne-labs/callapi-plugins

4.0.44

Patch Changes

  • Updated dependencies [be2f46d]
    • @zayne-labs/callapi@1.11.44

4.0.43

Patch Changes

  • Updated dependencies [8aaff38]
    • @zayne-labs/callapi@1.11.43

4.0.42

Patch Changes

  • Updated dependencies [87b0a08]
    • @zayne-labs/callapi@1.11.42

4.0.41

Patch Changes

  • Updated dependencies [f2a6d3f]
    • @zayne-labs/callapi@1.11.41

4.0.40

Patch Changes

  • Updated dependencies [87156c1]
    • @zayne-labs/callapi@1.11.40

4.0.39

Patch Changes

  • Updated dependencies [07419a2]
    • @zayne-labs/callapi@1.11.39

4.0.38

Patch Changes

  • Updated dependencies [a0a5e05]
    • @zayne-labs/callapi@1.11.38

4.0.37

Patch Changes

  • Updated dependencies [5de1d27]
    • @zayne-labs/callapi@1.11.37

4.0.36

Patch Changes

  • Updated dependencies [35e973b]
    • @zayne-labs/callapi@1.11.36

4.0.35

Patch Changes

  • Updated dependencies [278c29d]
    • @zayne-labs/callapi@1.11.35

4.0.34

Patch Changes

  • Updated dependencies [b8147ce]
    • @zayne-labs/callapi@1.11.34

4.0.33

Patch Changes

  • Updated dependencies [584565d]
    • @zayne-labs/callapi@1.11.33

4.0.31

Patch Changes

  • Updated dependencies [8b4fe33]
  • Updated dependencies [c3b60d0]
    • @zayne-labs/callapi@1.11.31

4.0.30

Patch Changes

  • Updated dependencies [026a76c]
    • @zayne-labs/callapi@1.11.30

4.0.29

Patch Changes

  • Updated dependencies [d49f07d]
  • Updated dependencies [75163e4]
    • @zayne-labs/callapi@1.11.29

4.0.28

Patch Changes

  • Updated dependencies [91a8114]
    • @zayne-labs/callapi@1.11.28

4.0.27

Patch Changes

  • Updated dependencies [ffc4873]
    • @zayne-labs/callapi@1.11.27

4.0.26

Patch Changes

  • Updated dependencies [6f5b3f9]
  • Updated dependencies [829431b]
    • @zayne-labs/callapi@1.11.26

4.0.25

Patch Changes

  • Updated dependencies [70487f8]
    • @zayne-labs/callapi@1.11.25

4.0.24

Patch Changes

  • Updated dependencies [8671045]
    • @zayne-labs/callapi@1.11.24

4.0.23

Patch Changes

  • Updated dependencies [78c1364]
    • @zayne-labs/callapi@1.11.23

4.0.22

Patch Changes

  • Updated dependencies [de2f92a]
    • @zayne-labs/callapi@1.11.22

4.0.21

Patch Changes

  • Updated dependencies [6782be6]
    • @zayne-labs/callapi@1.11.21

4.0.20

Patch Changes

  • Updated dependencies [8f2f684]
    • @zayne-labs/callapi@1.11.20

4.0.18

Patch Changes

  • Updated dependencies [165b969]
    • @zayne-labs/callapi@1.11.18

4.0.17

Patch Changes

  • Updated dependencies [ab889c8]
    • @zayne-labs/callapi@1.11.17

4.0.16

Patch Changes

  • Updated dependencies [dac80c9]
    • @zayne-labs/callapi@1.11.16

4.0.15

Patch Changes

  • Updated dependencies [5672cc7]
    • @zayne-labs/callapi@1.11.15

4.0.12

Patch Changes

  • Updated dependencies [6958f4f]
    • @zayne-labs/callapi@1.11.12

4.0.9

Patch Changes

  • Updated dependencies [89c1cef]
    • @zayne-labs/callapi@1.11.9

4.0.8

Patch Changes

  • Updated dependencies [f64dae5]
    • @zayne-labs/callapi@1.11.8

4.0.7

Patch Changes

  • Updated dependencies [1bcf35f]
    • @zayne-labs/callapi@1.11.7

4.0.6

Patch Changes

  • Updated dependencies [d5c0a35]
    • @zayne-labs/callapi@1.11.6

4.0.5

Patch Changes

  • Updated dependencies [63ecf19]
    • @zayne-labs/callapi@1.11.5

4.0.4

Patch Changes

  • Updated dependencies [8c31997]
    • @zayne-labs/callapi@1.11.4

4.0.3

Patch Changes

  • Updated dependencies [70ebf9e]
    • @zayne-labs/callapi@1.11.3

4.0.2

Patch Changes

  • Updated dependencies [8006bfc]
    • @zayne-labs/callapi@1.11.2

4.0.1

Patch Changes

  • Updated dependencies [f0b9575]
    • @zayne-labs/callapi@1.11.1

4.0.0

Patch Changes

  • Updated dependencies [3860cb7]
    • @zayne-labs/callapi@1.11.0

3.1.8

Patch Changes

  • Updated dependencies [ee21de9]
    • @zayne-labs/callapi@1.10.6

3.1.7

Patch Changes

  • Updated dependencies [8437089]
    • @zayne-labs/callapi@1.10.5

3.1.6

Patch Changes

  • Updated dependencies [1cd3367]
    • @zayne-labs/callapi@1.10.4

3.1.2

Patch Changes

  • edf52fb: feat(validation): add issueCause to ValidationError and improve schema validation

    • Add issueCause field to ValidationError to track validation failure source
    • Refactor schema validation to use full schema context
    • Update logger plugin to support basic and verbose modes
    • Fix package.json exports configuration
    • Update tests to include new issueCause field
  • Updated dependencies [edf52fb]

    • @zayne-labs/callapi@1.10.3

3.1.0

Minor Changes

  • 1b53dd1: feat(logger): enhance logger plugin with granular control

    Add ability to control logging for specific events individually by making the enabled option accept either a boolean or an object with event-specific flags. Also added new onValidationError hook and bumped version to 1.1.0.

    chore: update dependencies across multiple packages

3.0.2

Patch Changes

  • Updated dependencies [c69f3d6]
    • @zayne-labs/callapi@1.10.2

3.0.1

Patch Changes

  • Updated dependencies [605af9d]
    • @zayne-labs/callapi@1.10.1

3.0.0

Patch Changes

  • Updated dependencies [e78a454]
    • @zayne-labs/callapi@1.10.0

2.0.9

Patch Changes

  • Updated dependencies [d393723]
    • @zayne-labs/callapi@1.9.12

2.0.8

Patch Changes

  • Updated dependencies [4a9fcdf]
    • @zayne-labs/callapi@1.9.11

2.0.7

Patch Changes

  • Updated dependencies [40c8a4e]
    • @zayne-labs/callapi@1.9.10

2.0.6

Patch Changes

  • Updated dependencies [fc435f4]
    • @zayne-labs/callapi@1.9.9

2.0.5

Patch Changes

  • Updated dependencies [b47396f]
    • @zayne-labs/callapi@1.9.7

2.0.4

Patch Changes

  • Updated dependencies [c2f7fea]
    • @zayne-labs/callapi@1.9.6

2.0.3

Patch Changes

  • Updated dependencies [5c6900d]
    • @zayne-labs/callapi@1.9.4

2.0.2

Patch Changes

  • Updated dependencies [7d4765f]
    • @zayne-labs/callapi@1.9.3

2.0.1

Patch Changes

  • Updated dependencies [991ac01]
    • @zayne-labs/callapi@1.9.2

2.0.0

Patch Changes

  • Updated dependencies [9627f3e]
    • @zayne-labs/callapi@1.9.0

1.0.10

Patch Changes

  • Updated dependencies [00c0d7f]
    • @zayne-labs/callapi@1.8.22

1.0.9

Patch Changes

  • Updated dependencies [9f3b938]
    • @zayne-labs/callapi@1.8.21

1.0.8

Patch Changes

  • Updated dependencies [1de63d3]
    • @zayne-labs/callapi@1.8.20

1.0.7

Patch Changes

  • Updated dependencies [6e259a6]
    • @zayne-labs/callapi@1.8.18

1.0.6

Patch Changes

  • Updated dependencies [ee7659d]
    • @zayne-labs/callapi@1.8.17

1.0.5

Patch Changes

  • Updated dependencies [03f69ce]
    • @zayne-labs/callapi@1.8.15

1.0.4

Patch Changes

  • Updated dependencies [360b0b7]
    • @zayne-labs/callapi@1.8.12

1.0.3

Patch Changes

  • Updated dependencies [4864919]
    • @zayne-labs/callapi@1.8.10

1.0.2

Patch Changes

  • Updated dependencies [9d8f72d]
    • @zayne-labs/callapi@1.8.3

1.0.1

Patch Changes

  • Updated dependencies [3a150ba]
    • @zayne-labs/callapi@1.8.2

1.0.0

Patch Changes

  • Updated dependencies [7da7707]
    • @zayne-labs/callapi@1.8.0

0.0.3

Patch Changes

  • Updated dependencies [eb629cf]
    • @zayne-labs/callapi@1.7.18

0.0.2

Patch Changes

  • Updated dependencies [434dec2]
    • @zayne-labs/callapi@1.7.15

0.0.1

Patch Changes

  • ce8ba66: ➕ feat(logger): add consola integration for improved logging capabilities
  • Updated dependencies [ce8ba66]
    • @zayne-labs/callapi@1.7.14

@zayne-labs/callapi@1.11.45

27 Jan 21:18

Choose a tag to compare

@zayne-labs/callapi

1.11.44

Patch Changes

  • be2f46d: refactor(types): improve type inference for defineBaseConfig

    Update defineBaseConfig to properly infer return type when using function configuration, ensuring deep writeable properties are correctly applied to the function's return value.

1.11.43

Patch Changes

  • 8aaff38: feat: add defineInstanceConfig helper

1.11.42

Patch Changes

  • 87b0a08: feat(callapi): add fetchApi result mode and improve result handling
    • Implement new 'fetchApi' result mode that returns raw Response object
    • Skip data parsing and validation when resultMode is 'fetchApi'
    • Update type definitions and rename ThrowOnErrorUnion to ThrowOnErrorBoolean
    • Add comprehensive tests for all result modes
    • Improve documentation for result mode options

1.11.41

Patch Changes

  • f2a6d3f: feat(validation): add schema validation for toFormData and toQueryString
    fix(dedupe): correct duplicate request error message
    perf(common): optimize URLSearchParams usage and remove polyfills
    refactor(types): improve response parser and conditional types
    docs(meta): update documentation structure and content

1.11.40

Patch Changes

  • 87156c1: refactor(callapi)!: replace forcefullyCalculateStreamSize with request-only option 💥
    refactor(callapi): consolidate option validation logic ♻️
    refactor(callapi): rename updatedOptions to updatedConfig in retry/dedupe ♻️
    test(callapi): suppress invalid URL console errors in setup 🧪
    chore(callapi): update types and remove unused exports 🧹

1.11.39

Patch Changes

  • 07419a2: chore(release): prepare release with breaking refactors and doc updates

    refactor(callapi)!: simplify retry and dedupe configuration by removing nested options 💥
    refactor(callapi): rename updatedOptions to updatedConfig and improve error handling ♻️
    feat(docs): migrate to Vercel and enhance SEO with structured data 🚀
    build(deps): update @zayne-labs toolkit dependencies to 0.12.22 ⬆️
    chore(ci): fix incorrect eslint command and apply automated fixes 🔧

1.11.38

Patch Changes

  • a0a5e05: feat(callapi): export context type helpers

    chore: update dependencies and refactor code organization

    • Update pnpm version in CI workflows to 10.28.0
    • Update various package dependencies including @zayne-labs packages
    • Refactor import statements and code organization across multiple files
    • Simplify prettier config files using zayne helper
    • Remove unused bundle analyzer from next config

1.11.37

Patch Changes

  • 5de1d27: feat(url): ✨ improve URL handling with method extraction and validation enhancements

    🚀 Enhanced URL processing with improved method extraction from URLs
    🔧 Refactored validation system for better schema handling and route key resolution
    🧪 Added comprehensive utility function tests and URL integration tests
    ⚡️ Improved error handling and URL normalization logic
    📦 Updated package dependencies and workflow configurations
    🎨 Enhanced type definitions with better conditional types and helpers

    feat(validation): 🎯 enhance schema resolution and route key handling

    • Improved getResolvedSchema function with better context passing

    • Enhanced getCurrentRouteSchemaKeyAndMainInitURL with prefix/baseURL handling

    • Added removeLeadingSlash utility for consistent path processing

    • Refactored method extraction to use proper route key methods validation

      test(utils): 🧪 add comprehensive utility function tests

    • Added extensive tests for type guards, common utilities, and configuration splitting

    • Implemented URL integration tests for fetch client functionality

    • Enhanced test coverage for body processing, header handling, and error scenarios

      fix(url): 🔧 improve URL normalization and method extraction

    • Fixed extractMethodFromURL to properly validate route key methods

    • Enhanced normalizeURL with configurable options for relative URL handling

    • Improved error messages for invalid URL scenarios

    • Added atSymbol constant for consistent method prefix handling

1.11.36

Patch Changes

  • 35e973b: feat(plugins): ✨ enhance plugin system with improved TypeScript support and extra options inference

    feat(types): 🏷️ add PluginMiddlewares type and improve plugin type definitions
    feat(plugins): 🔧 improve InferPluginExtraOptions utility type to also accept passing typeof schema directly for convenience
    docs(plugins): 📚 update plugin documentation with enhanced TypeScript examples
    test(plugins): ✅ update plugin tests to reflect new type changes

1.11.35

Patch Changes

  • 278c29d: feat(url): add slash when joining baseURL with relative paths 🔗
    fix(url): validate full URL with URL.canParse and log helpful hint 🧯
    feat(utils): infer Content-Type from body; respect explicit header 🧠
    feat(utils): support x-www-form-urlencoded via toQueryString when header set 🧾
    refactor(guards): rename isSerializable → isSerializableObject ♻️
    refactor(client): pass resolved headers to getBody for correct serialization 🔧
    feat(types): merge prefix/baseURL with route keys including @METHOD/… 🧩
    refactor(validation): rename disableValidationOutputApplication → disableRuntimeValidationTransform ✨
    test(url|utils|validation): update expectations and cases to new behavior ✅
    chore(deps): bump vitest and zod; refresh lockfile ⬆️
    chore(pkg): apply minor package.json updates across workspace 🧹
    break(validation): rename schema config flag; user code must update 🚨

1.11.34

Patch Changes

  • b8147ce: fix(url): handle url normalization differently for protocol URLs

    Modify normalizeURL to preserve protocol URLs by not adding a leading slash when the URL contains "http". Add tests to verify proper handling of both protocol and non-protocol URLs.

1.11.33

Patch Changes

  • 584565d: refactor(callapi): improve auth typing and inference ♻️

    refactor(callapi): rename Auth to AuthOption and refine auth types (Bearer, Token, Basic, Custom) ♻️
    feat(callapi): add InferAuthOption to support schema-based auth typing ✨
    fix(callapi): update usages of Auth to AuthOption in hooks and common types 🔧
    docs: update authorization documentation to reflect new types 📚
    test: update auth tests to match new type definitions ✅
    chore: update dependencies and lockfile 📦

1.11.31

Patch Changes

  • 8b4fe33: refactor(callapi): improve type naming and validation handling

    • rename CallApiSuccessOrErrorVariant to CallApiResultSuccessOrErrorVariant for consistency
    • simplify ResultModeMap type structure and remove redundant types
    • enhance schema validation with support for per-field disable flags
    • streamline request options validation and header resolution
    • update tests to reflect changes in type names and validation behavior
  • c3b60d0: refactor: Improve type preview by wrapping withoutResponse with Prettify utility type

1.11.30

Patch Changes

  • 026a76c: refactor(callapi): improve type inference and global declarations ♻️

    fix(callapi): move ReadableStream global declaration to reset.d.ts to prevent tsdown for always bundling it 🚚

    feat(callapi): use NoInferUnMasked helper for over NoInfer for better tooltips ✨

    fix(callapi, types): add NoInfer usage to sharedOptions type to prevent middlewares and hooks from inferring the data and error as unknown🔧

1.11.29

Patch Changes

  • d49f07d: fix(callapi): Fix snd refactor types

    • refactor(types): Rename GetCallApiResult to InferCallApiResult
    • refactor(core): Improve SharedExtraOptions to support context overriding
    • fix(stream): Add default generic to ReadableStream augmentation
    • docs(middlewares): Fix caching plugin usage and enable twoslash
    • ci(workflows): Update pnpm version to 10.24.0
    • chore(deps): Update lockfile
  • 75163e4: refactor(types): rename InferredPluginOptions to InferredExtraOptions for consistency

    docs: update plugin and client type references in documentation
    fix: downgrade prettier to 3.6.2 due to compatibility issues
    style: reorganize imports in layout.shared.tsx

1.11.28

Patch Changes

  • 91a8114: refactor(callapi): further improve type simplification in a few core areas
    • Add GetMergedCallApiContext type for better context merging
    • Simplify Hooks interface by removing redundant generic params
    • Update Middlewares interface to support context types
    • Remove type-preserving overload from toFormData utility
    • Reorganize imports in test files

1.11.27

Patch Changes

  • ffc4873: refactor(core): ♻️ Standardize context types and generics
    • refactor(types): Introduce DefaultCallApiContext and update default generic parameters across config types
    • refactor(hooks): Update hook context types to be generic and accept TCallApiContext
    • refactor(types): Rename InferExtendSchemaConfigContext to GetExtendSchemaConfigContext
    • refactor(types): Move InferParamsFromRoute to conditional-types.ts
    • refactor(core): Remove types/index.ts and update src/index.ts exports
    • chore(deps): Update lockfile

1.11.26

Patch Changes

  • 6f5b3f9: feat: add null and undefined to allowed values

  • 829431b: refactor(callapi): rename CallApiEnv to CallApiContext and related types

    Rename CallApiEnv to CallApiContext to better reflect its purpose as a context provider rather than environment configuration. Update all related types and functions to use the new naming convention, including createFetchClientWithEnv becoming createFetchClientWithContext. This change improves code clarity and maintainability.

1.11.25

Patch Changes

  • 7...
Read more

@zayne-labs/callapi@1.11.44

23 Jan 22:16
0ee0ddb

Choose a tag to compare

Patch Changes

  • be2f46d: refactor(types): improve type inference for defineBaseConfig

    Update defineBaseConfig to properly infer return type when using function configuration, ensuring deep writeable properties are correctly applied to the function's return value.

@zayne-labs/callapi-plugins@4.0.44

23 Jan 22:16
0ee0ddb

Choose a tag to compare

Patch Changes

  • Updated dependencies [be2f46d]
    • @zayne-labs/callapi@1.11.44

@zayne-labs/callapi@1.11.43

12 Jan 19:52
41a2b17

Choose a tag to compare

Patch Changes

  • 8aaff38: feat: add defineInstanceConfig helper

@zayne-labs/callapi-plugins@4.0.43

12 Jan 19:52
41a2b17

Choose a tag to compare

Patch Changes

  • Updated dependencies [8aaff38]
    • @zayne-labs/callapi@1.11.43