Skip to content

Releases: razor-informatics/ri-notifier-php

Release v3.0.0

Choose a tag to compare

@mureithimaina mureithimaina released this 30 Sep 15:05

This release bumps the minimum PHP requirement to PHP 8.3, adds support for Guzzle 8, and introduces comprehensive coverage for Notifier v2.7.0 APIs alongside overall codebase modernisation.


Breaking Changes

  • Minimum PHP Version: Modernised minimum required PHP version to 8.3 (PHP 8.1 is EOL; PHP 8.2 reaches EOL on 31 Dec 2026).
  • Strict Gateway Typing: Notifier::gateway() now type-hints the $gateway parameter as string.

New Features & Enhancements

Notifier v2.7.0 API Support

  • Message Priority: Message::send() now accepts an optional priority parameter (accepts a MessagePriority enum case or an int).
  • Bulk Messaging: Added Message::sendMany() (aliased as bulk()) supporting the v2/message/send endpoint to send messages across multiple phone numbers, contacts, and labels, or dispatch personalised messages. Returns response data containing message, summary, and failed.
  • Contact Management: Introduced Notifier::contacts() (Contact) supporting list, create, fetch, update, and delete operations.
  • Label Management: Introduced Notifier::labels() (Label) supporting list, create, fetch, update/rename, and delete operations.
  • Pagination & Blank Responses: List endpoints now include pagination links and meta. HTTP 204 No Content responses are handled as successful empty payloads.
  • New Gateways: Added constants for Roam Tech (Constants::GATEWAY_ROAM_TECH / 'roam') and Razor SMS (Constants::GATEWAY_RAZOR_SMS / 'razor-sms').

Dependency & Codebase Modernisation

  • Guzzle 8 Support: Updated dependency constraint to allow guzzlehttp/guzzle: ^7.10 || ^8.2.
  • Type Safety & Modern Syntax: Modernised the entire codebase with strict types (declare(strict_types=1)), typed class constants, readonly promoted properties, native ResponseInterface typing, and match expressions for error message handling.

Bug Fixes & Refinements

  • Improved Error Messaging: Standardised error handling for 402, 404, and 422 HTTP status codes to surface the server's error message directly, with validation errors populated into $data['errors'] keyed by field.
  • Request Headers: Removed the default global Content-Type: multipart/form-data header; each API request now explicitly manages its own payload content type.

Full Changelog: v0.2.0...v0.3.0

v0.2.0

Choose a tag to compare

@mureithimaina mureithimaina released this 05 May 07:06

Add mpesa hash decode functionality

  • Introduce decode method in DeHash class for hash decoding.
  • Update README.md with an example demonstrating decode functionality.
  • Add decoder method to Notifier for instantiating DeHash.

v0.1.4

Choose a tag to compare

@mureithimaina mureithimaina released this 23 Apr 16:27
  • M-Pesa / Airel Money hash lookup
  • Update to base php from 7.1 to 8.1

Full Changelog: v0.1.4...v0.1.4

v0.1.3

Choose a tag to compare

@mureithimaina mureithimaina released this 21 Mar 10:52

Added gateways
Available gateways are

  • Notifier (project balance)
  • Celcom Africa
  • Emreign
  • Africa’s Talking
  • Onfon Media
  • Web SMS

v0.1.2

Choose a tag to compare

@mureithimaina mureithimaina released this 21 Sep 08:18

Major bug fix for PHP 7.1

Full Changelog: v0.1.1...v0.1.2

v0.1.1

Choose a tag to compare

@mureithimaina mureithimaina released this 23 Jan 15:34
  1. Add constants.
  2. Error handling.

v0.1.0

Choose a tag to compare

@mureithimaina mureithimaina released this 18 Aug 16:09

first official release