peso / frankfurter-service
Frankfurter.dev data provider for Peso
Installs: 1
Dependents: 0
Suggesters: 0
Security: 0
Stars: 0
Watchers: 0
Forks: 0
Open Issues: 0
pkg:composer/peso/frankfurter-service
Requires
- php: ^8.2
- peso/core: ^1.1
- psr/http-client: ^1
- psr/http-factory: ^1
- psr/simple-cache: ^1 || ^2 || ^3
Requires (Dev)
- guzzlehttp/guzzle: ^7.10
- php-http/discovery: ^1.20
- php-http/mock-client: ^1.6.1
- phpunit/phpunit: ^11.5.46
- psalm/phar: ^6.14
- psy/psysh: >=0.12.18
- sandfox.dev/code-standard: ^1.2025.09.17
- squizlabs/php_codesniffer: >=4.0.1
- symfony/cache: ^7.4.1
This package is auto-updated.
Last update: 2025-12-18 06:52:22 UTC
README
This is an exchange data provider for Peso that retrieves data from Frankfurter.dev.
Installation
composer require peso/frankfurter-service
Install the service with all recommended dependencies:
composer install peso/frankfurter-service php-http/discovery guzzlehttp/guzzle symfony/cache
Example
<?php use Peso\Peso\CurrencyConverter; use Peso\Services\FrankfurterService; use Symfony\Component\Cache\Adapter\FilesystemAdapter; use Symfony\Component\Cache\Psr16Cache; $cache = new Psr16Cache(new FilesystemAdapter(directory: __DIR__ . '/cache')); $service = new FrankfurterService(cache: $cache); $converter = new CurrencyConverter($service); // 10664.00 as of 2025-12-18 echo $converter->convert('12500', 'USD', 'EUR', 2), PHP_EOL;
Documentation
Read the full documentation here: https://phpeso.org/v1.x/services/frankfurter.html
Support
Please file issues on our main repo at GitHub: https://github.com/phpeso/frankfurter-service/issues
License
The library is available as open source under the terms of the MIT License.