tombabolewski/openiai

Open IAI API PHP wrapper library

dev-master 2020-04-14 01:29 UTC

This package is auto-updated.

Last update: 2024-04-14 10:55:46 UTC


README

Version: 0.1.3

This library is yet unfinished. Use it only at your own risk. Feel free to contribute.

Summary

Open IAI API PHP wrapper library.

This is a Laravel library that lets you easily connect to IdoSell Shop API and make requests. It aims to cover the whole API (all gates and methods, which are automatically looked for).

Requirements

  • PHP 7.2
  • Laravel 5.8
  • ext-json
  • ext-soap

Installation

Simply use Composer to install this package, either by executing CLI command in your project directory:

composer require tombabolewski/openiai

or by adding the following line to your composer.json file in require section:

"require" : {
  "tombabolewski/openiai" : "^0.1.3"
}

Next, you should add the Service Provider to your config/app.php file. Just add the following line to the providers array, preferably at the end:

'providers' => [
    // (...)
    Tombabolewski/Openiai/OpeniaiServiceProvider::class,
],

If you would like, you can also add an alias to the aliases array like that:

'aliases' => [
    // (...)
    'Openiai' => Tombabolewski/Openiai/Client::class
],

Usage

Section under construction ;]

Example:

//Create openiai client instance
$client = app()->make('Openiai');

//Get all products
$products = $client->Products->get();