From a713f38ebd33c06da416edb73602b6c755c29aed Mon Sep 17 00:00:00 2001 From: Mohammed Elhaouari Date: Tue, 24 Feb 2026 01:59:05 +0100 Subject: [PATCH] Add wati response base class --- .gitignore | 2 +- README.md | 4 ++++ changelog.md | 12 ++++++++++-- src/WatiResponse.php | 10 ++++++++++ 4 files changed, 25 insertions(+), 3 deletions(-) create mode 100644 src/WatiResponse.php diff --git a/.gitignore b/.gitignore index a950b14..461ae7e 100755 --- a/.gitignore +++ b/.gitignore @@ -10,4 +10,4 @@ vendor .php-cs-fixer.cache .phpunit.cache composer.lock -test-request.php +playground.php diff --git a/README.md b/README.md index 809a976..362ebec 100644 --- a/README.md +++ b/README.md @@ -9,6 +9,10 @@ A PHP HTTP Client for the [Wati.io](https://wati.io) WhatsApp API. Provides a simple, fluent API to interact with Wati's REST API. +## Related Packages + +For a higher-level, feature-rich integration, consider using [wati-sdk](https://github.com/phpjuice/wati-sdk). It provides ready-to-use request classes, response DTOs, and additional convenience features built on top of this HTTP client. + ## Installation This package requires PHP 8.3 or higher. diff --git a/changelog.md b/changelog.md index d8f9217..ac7b251 100644 --- a/changelog.md +++ b/changelog.md @@ -2,7 +2,15 @@ All notable changes to `phpjuice/wati-http-client` will be documented in this file. -## 1.0.1 - 2026-02-20 +## 1.0.3 + +- Add `WatiResponse` - Base response class + +## 1.0.2 + +- Add pint formatting rules + +## 1.0.1 - Custom exceptions for error handling: - `WatiException` - Base exception @@ -14,6 +22,6 @@ All notable changes to `phpjuice/wati-http-client` will be documented in this fi - Proper tenant ID handling in URLs with trailing slash preservation - Request path normalization for correct URI resolution with base URLs containing paths -## 1.0.0 - 2026-02-20 +## 1.0.0 - Initial release of Wati HTTP Client (PHP 8.3+ support) diff --git a/src/WatiResponse.php b/src/WatiResponse.php new file mode 100644 index 0000000..bb7766e --- /dev/null +++ b/src/WatiResponse.php @@ -0,0 +1,10 @@ +