expertorder / push-api
PHP Push-API for ExpertOrder generated by OpenAPI
dev-main
2023-11-26 11:42 UTC
Requires
- php: ^7.2.5 || ^8.0
- ext-json: *
- guzzlehttp/guzzle: ^7.8
- guzzlehttp/psr7: ^2.6
This package is auto-updated.
Last update: 2024-11-26 14:03:28 UTC
README
API zur Übermittlung der Bestellungen an das ExpertOrder Kassensoftware.
<p style="font-size:1.5rem;">
Verwenden Sie die folgenden Daten zu Testzwecken:
PUT: https://osp.expertorder.de/testPush
API_KEY: 9615d48a-cc88-4c3e-8e43-102047366a71
For more information, please visit https://expertorder.de/support/.
Installation & Usage
Requirements
PHP 7.4 and later. Should also work with PHP 8.0.
Composer
To install the bindings via Composer, add the following to composer.json
:
{ "repositories": [ { "type": "vcs", "url": "https://github.com/GIT_USER_ID/GIT_REPO_ID.git" } ], "require": { "GIT_USER_ID/GIT_REPO_ID": "*@dev" } }
Then run composer install
Manual Installation
Download the files and include autoload.php
:
<?php require_once('/path/to/OpenAPIClient-php/vendor/autoload.php');
Getting Started
Please follow the installation procedure and then run the following:
<?php require_once(__DIR__ . '/vendor/autoload.php'); $apiInstance = new OpenAPI\Client\Api\BestellungBermittlungApi( // If you want use custom http client, pass your client which implements `GuzzleHttp\ClientInterface`. // This is optional, `GuzzleHttp\Client` will be used as default. new GuzzleHttp\Client() ); $api_key = 'api_key_example'; // string | Diese Api-Key identifiziert an welche ExpertOrder die Bestellung weiter geleitet werden soll. $order = {"version":1,"broker":"TestShop.de","fromMobile":false,"clientIp":"192.168.1.2","id":"20221121114617984","oldid":"20221121114617988","ordertime":"2022-11-21T11:46:17.988Z","deliverytime":"2022-11-21T11:46:17.988Z","customerinfo":"Quittung nicht vergessen","orderprice":20.5,"orderdiscount":0.0,"bonuscard":"","notification":false,"deliverycost":0.0,"tip":0.0,"customer":{"phone":"01700000001","email":"test@test.de","companyname":"RevoutIT","departmentname":"ExpertOrder","name":"Revout","street":"Ing.-Honnef-Str. 13","zip":"21509","location":"Glinde","addressinfo":"1.OG"},"payment":{"type":1,"provider":"","transactionid":"","prepaid":0.0},"items":[{"count":1,"name":"Menü 1","price":17.0,"items":[{"count":1,"name":"Sommer-Salat standard","price":0.0,"items":[{"count":1,"name":"French Dressing","price":0.0,"items":[]},{"count":1,"name":"Brötchen zum Salat standard","price":0.0,"items":[]}]},{"count":1,"name":"Pizza Vegetaria small","price":0.0,"items":[]},{"count":1,"name":"Warme Pfannkuchen","price":0.0,"items":[{"count":1,"name":"mit heißen Kirschen und Vanille-Sauce","price":0.0,"items":[]}]}]},{"count":1,"name":"Coca Cola 1l","price":3.5,"items":[]}]}; // \OpenAPI\Client\Model\Order try { $apiInstance->pushPut($api_key, $order); } catch (Exception $e) { echo 'Exception when calling BestellungBermittlungApi->pushPut: ', $e->getMessage(), PHP_EOL; }
API Endpoints
All URIs are relative to https://osp.expertorder.de
Models
Authorization
Endpoints do not require authorization.
Tests
To run the tests, use:
composer install vendor/bin/phpunit
Author
About this package
This PHP package is automatically generated by the OpenAPI Generator project:
- API version:
1.0.2
- Build package:
org.openapitools.codegen.languages.PhpClientCodegen