Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/jtelesforoantonio/laravel-guzzle-api
Laravel with Guzzle to consuming web services
https://github.com/jtelesforoantonio/laravel-guzzle-api
guzzle laravel laravel-api laravel-framework laravel-guzzle laravel-package
Last synced: about 2 months ago
JSON representation
Laravel with Guzzle to consuming web services
- Host: GitHub
- URL: https://github.com/jtelesforoantonio/laravel-guzzle-api
- Owner: jtelesforoantonio
- License: mit
- Created: 2019-10-21T20:47:45.000Z (about 5 years ago)
- Default Branch: master
- Last Pushed: 2019-10-21T21:15:25.000Z (about 5 years ago)
- Last Synced: 2024-07-30T18:57:36.543Z (5 months ago)
- Topics: guzzle, laravel, laravel-api, laravel-framework, laravel-guzzle, laravel-package
- Language: PHP
- Size: 3.91 KB
- Stars: 1
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
## Laravel Guzzle API
[![Total Downloads](https://poser.pugx.org/jtelesforoantonio/laravel-guzzle-api/downloads)](https://packagist.org/packages/jtelesforoantonio/laravel-guzzle-api)
[![License](https://poser.pugx.org/jtelesforoantonio/laravel-guzzle-api/license)](https://packagist.org/packages/jtelesforoantonio/laravel-guzzle-api)This package provides a quickly integration of [Guzzle](https://github.com/guzzle/guzzle) and [Guzzle Services](https://github.com/guzzle/guzzle-services)
with Laravel to consuming web services.## Installation
Install the package with Composer.
```shell
composer require jtelesforoantonio/laravel-guzzle-api
```Laravel 5.5+ uses Package Auto Discovery and you don't need to add the Service Provider manually.
## Usage
Once installed you need to run the following command to publish the config file
this file is the core to create the client and to integrate with web services.
```shell
php artisan vendor:publish --tag=laravel-guzzle-api-config
```
To call yours requests use the Facade.
```php
use JTelesforoAntonio\LaravelGuzzleApi\Api;$response = Api::myRequest();
```Or using the helper function.
```php
$response = api()->myRequest();
```