fortresswire / fw-sdk-php
FortressWire SDK for PHP - Use FortressWire in your PHP project
Requires
- php: >=7.4
- guzzlehttp/guzzle: ^7.2
This package is not auto-updated.
Last update: 2025-03-15 09:02:27 UTC
README
Disclaimer: This is a wip
The FortressWire SDK for PHP makes it easy for developers to interact with FortressWre from their PHP code. You can get started by installing the SDK through Composer.
Getting Started
-
Minimum requirements - To run the SDK, your system will need to have a minimum PHP version of 7.4 with the cURL extension.
-
Install the SDK - Using Composer is the recommended way to install the FortressWire SDK for PHP. The SDK is available via Packagist under the
fortresswire/fw-sdk-php
package. If Composer is installed globally on your system, you can run the following in the base directory of your project to add the SDK as a dependency:
composer require fortresswire/fw-sdk-php
Quick Examples
Creating a Watchdog client
require './vendor/autoload.php'; use FortressWire\Watchdog\WatchdogClient; $client = new WatchdogClient([ 'version' => '1', 'region' => 'af-south-1', 'key' => $_ENV['WATCHDOG_KEY'], ]);
Creating Watchdog events
... use FortressWire\Watchdog\WatchdogEvents; $logger = new WatchdogEvents($client); $logger->create('debug - low', 'Account registration failed.', [ 'first_name' => 'Donald', 'last_name' => 'Pakkies' ]);
Creating a MoanaDB client
require './vendor/autoload.php'; use FortressWire\Moana\MoanaClient; $client = new MoanaClient([ 'version' => '1', 'region' => 'af-south-1', 'key' => $_ENV['MOANA_KEY'], ]);
Creating a MoanaDB record
... use FortressWire\Moana\Document; $document = new Document($client); $document->table('users')->create([ 'first_name' => 'Donald', 'last_name' => 'Pakkies', ]);
License
The MIT License (MIT). Please see License File for more information.