narnoo / php-sdk
A PHP-SDK for Narnoo API
Installs: 17
Dependents: 0
Suggesters: 0
Security: 0
Stars: 0
Watchers: 2
Forks: 1
Open Issues: 2
Type:package
Requires
- guzzlehttp/guzzle: ^6.3
This package is not auto-updated.
Last update: 2024-10-08 06:47:08 UTC
README
The narnoo-php-sdk is a library to interact with Narnoo's RESTFUL API. It performs all the heavy coding work so PHP developers can quickly make calls to our API.
Detailed information about using this API will be added to this page and the repo Wiki.
Work in progress using the latest API
Get started with the PHP SDK
Installation
Install our library with composer
composer require narnoo/php-sdk
Authentication
You can find your business API keys from within your business's Narnoo.com account. Only businesses with an approved plan have access to their API keys.
Once you have your API keys then you can authenticate your API calls and return your bearer token.
<?php include "vendor/autoload.php"; use Narnoo\Authenticate\Authenticate; $authen = new Authenticate(); $key = 'xxxxxxxxxxxx'; $secret = 'xxxxxxxxxxxx'; $token = $authen->getToken($key,$secret); //For testing purposes we print out the response. However, you would save this taken to your database for future calls. echo "<pre>"; print_r($token); echo "</pre>"; ?>
Example Calls
These examples will be updated as we go!
Connect
- Find operators to follow
- Search for operators to follow
- Follow an operator
- List operators being followed
- Unfollow an operator
- Bookable operators
Listing
Products
Booking
- Get bookable products
- Get bookable product details
- Get the booking products reservation details
- Get product availability
- Create a booking reservation