Download the PHP package exodus4d/pathfinder_esi without Composer

On this page you can find all versions of the php package exodus4d/pathfinder_esi. 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 pathfinder_esi

Web API client for EVE-Online - ESI API

This Web API client library is used by Pathfinder and handles all ESI API requests.
Additional APIs can easily be added and can be used side by side with their own configuration. Included clients:

This Web client is build on Guzzle and makes much use of the build in Middleware concept in Guzzle.

Installation:

Use Composer for installation. In composer.json require section add:

Pathfinder: This web API client lib is automatically installed through Composer along with all other required dependencies for the Pathfinder project. (→ see composer.json).

A newer version of Pathfinder may require a newer version of this repository as well. So running composer install after a Pathfinder update will upgrade/install a newer ESI client. Check Pathfinder release notes for further information.

Use Client:

1. Init client:

2. Send requests

Concept

Guzzle Middlewares :

Middlewares classes are small functions that hook into the "request → response" chain in Guzzle.

Guzzle HandlerStack :

This flowchart shows all Middlewares used by ESI.php API client. Each request to ESI API invokes all Middlewares in the following order:

Before request

GuzzleJsonMiddlewareGuzzleLogMiddlewareGuzzleCacheMiddlewareGuzzleCcpLogMiddlewareGuzzleRetryMiddlewareGuzzleCcpErrorLimitMiddleware

After response (→ reverse order!)

GuzzleCcpErrorLimitMiddlewareGuzzleRetryMiddlewareGuzzleCcpLogMiddlewareGuzzleCacheMiddlewareGuzzleLogMiddlewareGuzzleJsonMiddleware

Default Middlewares:

JSON

Requests with expected JSON encoded response data have GuzzleJsonMiddleware in HandlerStack.
This adds Accept: application/json Header to request and response body gets wrapped into JsonStream.

$client->setAcceptType('json');

Caching

A client instance should be set up with a PSR-6 compatible cache pool where persistent data can be stored. Valid response data can be cached by its Cache-Expire HTTP Header. GuzzleCacheMiddleware also handle Etag Headers. Other Middlewares can also access the cache pool for their needs. E.g. GuzzleLogMiddleware can throttle error logging by using the cache pool for error counts,…

→ See: $client->setCachePool();

Hint: Check out www.php-cache.com for PSR-6 compatible cache pools.

Logging

Errors (or other events) during (~before) a request can be logged (e.g. connect errors, or 4xx/5xx responses).
The primary Middleware for logging is GuzzleLogMiddleware
Other Middlewares also have access to the global new log callback and implement their own logs.

$client->setNewLog();

Retry

Requests result in an expected error (timeouts, cURL connect errors,… ) will be retried [default: 2 times → configurable!]. Check out GuzzleRetryMiddleware for more information.

CCP ESI exclusive Middlewares:

Each web client has its own stack of Middlewares. These Middlewares are exclusive for requests to CCP´s ESI API:

GuzzleCcpLogMiddleware

Requests to endpoints that return a warning HTTP Header for deprecated /or legacy marked endpoints get logged into separate log files.

GuzzleCcpErrorLimitMiddleware

Failed ESI requests (4xx/5xx status code) implement the concept of "Error Rate Limiting" (→ blog: ESI error rate limiting). In case a request failed multiple times in a period, this Middleware keeps track of logging this and pre-block requests (e.g. for a user) an endpoint before CCP actual does.

Content Encoding

The default configuration for "decode-content" is true → decode "gzip" or "deflate" responses.
Most APIs will only send compressed response data if Accept-Encoding HTTP Header found in request. A string value will add this Header and response data gets decoded.

$client->setDecodeContent('gzip, deflate');

Bug report

Issues can be tracked here: https://github.com/exodus4d/pathfinder/issues

Development

If you are a developer you might have both repositories (exodus4d/pathfinder, exodus4d/pathfinder_esi ) checked out locally.

In this case you probably want to test changes in your local exodus4d/pathfinder_esi repo using your local exodus4d/pathfinder installation.

  1. Clone/Checkout both repositories local next to each other
  2. Make your changes in your pathfinder_esi repo and commit changes (no push!)
  3. Switch to your pathfinder repo
  4. Run Composer with composer-dev.json, which installs pathfinder_esi from your local repository.
    • Unix: $set COMPOSER=composer-dev.json && composer update
    • Windows (PowerShell): $env:COMPOSER="composer-dev.json"; composer update --no-suggest

All versions of pathfinder_esi with dependencies

PHP Build Version
Package Version
Requires php-64bit Version >=7.2
ext-json Version *
guzzlehttp/guzzle Version 6.5.*
caseyamcl/guzzle_retry_middleware Version 2.3.*
cache/void-adapter Version 1.0.*
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 exodus4d/pathfinder_esi contains the following files

Loading the files please wait ....