项目作者: smalot

项目描述 :
PHP Wrapper for Kong API Gateway - Microservices Management Layer, delivering high performance and reliability.
高级语言: PHP
项目地址: git://github.com/smalot/kong-api.git
创建时间: 2017-09-20T09:00:20Z
项目社区:https://github.com/smalot/kong-api

开源协议:MIT License

下载


Kong

PHP Wrapper for Kong API Gateway - Microservices Management Layer, delivering high performance and reliability.

Build Status
Current Version
composer.lock

Total Downloads
Monthly Downloads
Daily Downloads

Compatibility

Currently supported Kong version: 0.11.

Supported services:

  • Api
  • Certificate
  • Consumer
  • Plugin
  • Sni
  • Target
  • Upstream

Requires at least PHP 5.6.

Install

This library can be installed with composer:

  1. composer require smalot/kong-api

Usage

  1. $factory = new \Smalot\Kong\ServiceFactory();
  2. /** @var \Smalot\Kong\Services\Api $service */
  3. $service = $factory->get('api');
  4. $response = $service->create(
  5. [
  6. 'name' => $name,
  7. 'uris' => '/ping',
  8. 'upstream_url' => 'http://ping/',
  9. ]
  10. );
  11. $api = $response->json();
  12. var_dump($api);