Download the PHP package shetabit/extractor without Composer

On this page you can find all versions of the php package shetabit/extractor. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package extractor

Laravel Extractor

Communicate with remote servers or microservices in an easy way.

All requests and responses can be cached and manipulated on runtime using middlewares.

Donate me if you like this package :sunglasses: :bowtie:

List of contents

Install

Via Composer

If you are using Laravel 5.5 or higher then you don't need to add the provider and alias.

In your config/app.php file add below lines.

How to use

Send requests

you can send requests to remote API using Request class, see the below example:

as you see, you can work with remote API in an easy way.

the Request has more methods to add fields, headers and etc.

Send concurrent requests

you can send concurrent requests like the below

Event listeners

you can set success and error listener for each requests seperately. here is another example that uses onSuccess and onError listeners.

Middlewares

How to create

Middlewares can be created by running the below command

The former command will create a middleware named test in app\Http\RemoteRequests\Middlewares path.

You can add a middleware to request like the below:

Multiple middlewares can be used by calling middleware method multiple times:

Each middleware has a handle method that can be used to handle requests and responses.

The following middleware would perform some task before the request is handled by the application:

However, this middleware would perform its task after the request is handled by the application:

Global middlewares

You can use Request::withGlobalMiddlewares to add global middlewares. global middlewares will be binded to all requests.

in each request, you can unbind global middlewares, if you need them just use withoutMiddleware like the below:

Cache

you can cache responses according to requests.

Notice: TTL (Time To Live) is the same as Laravel cache.

Conditional configs

Sometimes you need to add some configs when a condition happens, in this kind of situations you can use the when method to add conditional configs.

Client

You can encapsulate any request that exists between the current microservice and the remote microservice within a Client.

Create clients

Clients can be created using a simple command

Clients will saved in app/Http/RemoteRequests/Clients by default.

lets create and example, imagine you have and remote Api (or microservice) and need to login into it.

then, your Login micro-client can be similar to below codes:

Run a client

you can run the Login micro-client like the below (we have Login client example at the top)

as you see, client starts to work as you call the run method, fetches and returns a response.

On progress features

Change log

Please see CHANGELOG for more information on what has changed recently.

Contributing

Please see CONDUCT for details.

Security

If you discover any security related issues, please email [email protected] instead of using the issue tracker.

Credits

License

The MIT License (MIT). Please see License File for more information.


All versions of extractor with dependencies

PHP Build Version
Package Version
Requires php Version >=7.2
illuminate/broadcasting Version 5.8.*|6.*|7.*|8.*|9.*|10.*
illuminate/support Version 5.8.*|6.*|7.*|8.*|9.*|10.*
guzzlehttp/guzzle Version 6.2.*|7.*
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package shetabit/extractor contains the following files

Loading the files please wait ....