mrstebo/ekm-php

Our new API allows partners to build significantly better integrations with the EKM platform. To try out the below endpoints, or for full up to date representations of the request / response models, please see the [swagger page](https://api.ekm.net/swagger/index.html). (We display examples here,

0.0.4 2021-12-22 16:10 UTC

This package is auto-updated.

Last update: 2024-09-22 21:52:23 UTC


README

Our new API allows partners to build significantly better integrations with the EKM platform.

To try out the below endpoints, or for full up to date representations of the request / response models, please see the swagger page. (We display examples here, but the swagger page is guaranteed to show the complete model.)

To keep up to date with the latest updates, please see our RSS feed or the partner dashboard.

For more information, please visit https://ekm.com.

Installation & Usage

Requirements

PHP 7.3 and later. Should also work with PHP 8.0 but has not been tested.

Composer

To install the bindings via Composer, add the following to composer.json:

{
  "repositories": [
    {
      "type": "vcs",
      "url": "https://github.com/mrstebo/ekm-php.git"
    }
  ],
  "require": {
    "mrstebo/ekm-php": "*@dev"
  }
}

Then run composer install

Manual Installation

Download the files and include autoload.php:

<?php
require_once('/path/to/ekm-php/vendor/autoload.php');

Getting Started

Please follow the installation procedure and then run the following:

<?php
require_once(__DIR__ . '/vendor/autoload.php');



// Configure OAuth2 access token for authorization: Bearer
$config = EkmPHP\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');


$apiInstance = new EkmPHP\Api\CategoriesApi(
    // 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(),
    $config
);
$v1AddCategory = new \EkmPHP\Models\V1AddCategory(); // \EkmPHP\Models\V1AddCategory

try {
    $result = $apiInstance->categoriesCreate($v1AddCategory);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling CategoriesApi->categoriesCreate: ', $e->getMessage(), PHP_EOL;
}

API Endpoints

All URIs are relative to https://api.ekm.net

Models

Authorization

Bearer

  • Type: OAuth
  • Flow: accessCode
  • Authorization URL: https://api.ekm.net/connect/authorize
  • Scopes:
    • openid: Access a shops identity token.
    • profile: Read a user's details. (name, email, etc)
    • tempest.internal.orders.read: Internal - Read a shop's orders.
    • tempest.customers.read: Read a shop's customers.
    • tempest.customers.write: Modify a shop's customers.
    • tempest.Guests.read: Read a shop's Guests.
    • tempest.Guests.write: Modify a shop's Guests.
    • tempest.orders.read: Read a shop's orders.
    • tempest.orders.write: Modify a shop's orders.
    • tempest.orders.customers.notes.read: Read a shop's order customer notes.
    • tempest.orders.customers.notes.write: Modify a shop's order customer notes.
    • tempest.products.read: Read a shop's products.
    • tempest.products.write: Modify a shop's products.
    • tempest.categories.read: Read a shop's categories.
    • tempest.categories.write: Modify a shop's categories.
    • tempest.settings.orderstatuses.read: Read a shop's order statuses.
    • tempest.settings.domains.read: Read a shop's domains.
    • tempest.settings.accountdetails.read: Read a shop's account details.
    • tempest.settings.tax.read: Read a shop's tax settings.
    • tempest.settings.tax.write: Write a shop's tax settings.
    • tempest.settings.currency.read: Read a shop's currency settings.
    • tempest.cartsessions.read: Read a shop's cart sessions.
    • tempest.cartsessions.write: Modify a shop's cart sessions.
    • tempest.cart.read: Read a shop's cart
    • tempest.cart.write: Modify a shop's cart.

Tests

To run the tests, use:

composer install
vendor/bin/phpunit

Author

api-support@ekm.com

About this package

This PHP package is automatically generated by the OpenAPI Generator project:

  • API version: Latest
    • Package version: 0.0.4
  • Build package: org.openapitools.codegen.languages.PhpClientCodegen