mggflow/msvc-api

Send requests to laravel microservice

Installs: 1

Dependents: 0

Suggesters: 0

Security: 0

Stars: 0

Watchers: 1

Forks: 0

Open Issues: 0

pkg:composer/mggflow/msvc-api

v1.0.0 2021-10-30 10:44 UTC

This package is auto-updated.

Last update: 2025-10-12 23:37:18 UTC


README

About

This package makes wrapping to fast and easy send requests to laravel microservice API from Server side code.

Usage

To install:

composer require mggflow/msvc-api

Example:

use MGGFLOW\Microservices\Api;
 
$msvcName = "msvc_name";
$apiUrl = "https://url.to/api";
// Create instance of API.
$api = new Api($msvcName, $apiUrl);
// Send request to action "hello" of microservice with param "name".
$resp = $api->hello(["name" => "John"])->send();
// Returns json decoded response or false.
var_dump($resp);