From afb7aff6f03994a8a3ae9dc8b4df9a6f48d4e177 Mon Sep 17 00:00:00 2001 From: Rom Date: Sun, 3 Nov 2024 11:46:20 +0200 Subject: [PATCH] add changelog --- packages/api/CHANGELOG.MD | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 packages/api/CHANGELOG.MD diff --git a/packages/api/CHANGELOG.MD b/packages/api/CHANGELOG.MD new file mode 100644 index 0000000..aae4671 --- /dev/null +++ b/packages/api/CHANGELOG.MD @@ -0,0 +1,19 @@ +# Changelog + +## [6.0.0] + +### ⚠️ Breaking Changes + +- **ApiClient data format changed**: The `ApiClient` class constructor now expects variables in JSON format instead of params. +- **Method name change**: To call the client, use `request` instead of `query`. + +### Added + +- **`rawRequest` method**: Allows fetching data in the old format, returning `data`, `errors`, `extensions`... +- **Versions validation**: The client now validates the version of the API it’s interacting with. +- **Enhanced request configuration**: The `ApiClient` class now accepts a `requestConfig` object, allowing for additional customization options. +- **`ClientError` type for error handling**: Introduced the `ClientError` type, providing a structured format for handling errors consistently within the `ApiClient`. + +### Fixed + +- **GraphQL library dependency**: Resolved an issue where the GraphQL library was sometimes required as a dependency; this is now included by default.