PHPackages                             utrust/utrust - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [API Development](/categories/api)
4. /
5. utrust/utrust

ActiveLibrary[API Development](/categories/api)

utrust/utrust
=============

Utrust API library

v1.1.0(2y ago)684.8k↑85.1%4[2 issues](https://github.com/utrustdev/utrust-php/issues)[2 PRs](https://github.com/utrustdev/utrust-php/pulls)GPL-3.0-or-laterPHPPHP &gt;=5.3.0CI failing

Since Dec 9Pushed 1y ago9 watchersCompare

[ Source](https://github.com/utrustdev/utrust-php)[ Packagist](https://packagist.org/packages/utrust/utrust)[ RSS](/packages/utrust-utrust/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (2)Dependencies (3)Versions (13)Used By (0)

xMoney Crypto PHP
=================

[](#xmoney-crypto-php)

[![Test Suite](https://github.com/utrustdev/utrust-php/workflows/Test%20Suite/badge.svg)](https://github.com/utrustdev/utrust-php/workflows/Test%20Suite/badge.svg)

The official PHP library for the [xMoney Crypto API](https://docs.crypto.xmoney.com/).

Minimum Requirements
--------------------

[](#minimum-requirements)

- PHP version 5.4 or above.

Install
-------

[](#install)

Install with composer:

```
composer require utrust/utrust

```

Usage
-----

[](#usage)

### API Client

[](#api-client)

Creating a new Order:

```
use Utrust\ApiClient;

$utrustApi = new ApiClient('API_KEY');

$orderData = [...];
$customerData = [...];

$response = $utrustApi->createOrder($orderData, $customerData);
echo $response->attributes->redirect_url;
```

Check the full example [here](https://github.com/utrustdev/utrust-php/blob/master/examples/create_simple_order.php).

### Validations

[](#validations)

The `Validator` class can be used to check your data array before passing it to the API Client. It will throw an exception with the errors array if the validations don't pass, otherwise it will return `true`:

```
$orderIsValid = Validator::order($orderData);
$customerIsValid = Validator::customer($customerData);

if ($orderIsValid && $customerIsValid) {
    // create the order here
}
```

### Webhooks

[](#webhooks)

The `Webhook\Event` class can be used to verify an incoming event via Webhook. It will throw an exception if the event has an invalid format or invalid signature:

```
$event = new Event($payload);
$event->validateSignature($webhooksSecret);
```

Check the `examples/` directory for further details.

Contribute
----------

[](#contribute)

This library was written and is maintained by the Utrust development team. We have now opened it to the world so that the community using this library may have the chance of shaping its development.

You can contribute by simply letting us know your suggestions or any problems that you find [by opening an issue on GitHub](https://github.com/utrustdev/utrust-php/issues/new).

You can also fork the repository on GitHub and open a pull request for the `master` branch with your missing features and/or bug fixes. Please make sure the new code follows the same style and conventions as already written code. Our team is eager to welcome new contributors into the mix 😊.

### Tests

[](#tests)

When contributing with new changes, please make an effort to provide the respective tests. This is especially important when fixing any problems, as it will prevent other contributors from accidentally reintroducing the issue in the future.

Before submitting a pull request with your changes, please make sure every test passes:

```
composer test

```

When in doubt whether you caused a test to fail, check the build for `master` in [CircleCI](https://circleci.com/gh/utrustdev/utrust-php).

### Lint

[](#lint)

This project uses [PHPCodeSniffer](https://github.com/squizlabs/PHP_CodeSniffer) with PSR-2 coding stardard.

Before contributing your changes, make sure it passes on the linter:

```
composer lint

```

When in doubt whether you introduced a linter error, check the build for `master` in [CircleCI](https://circleci.com/gh/utrustdev/utrust-php).

Publish
-------

[](#publish)

We are publishing the library to [Packagist](https://packagist.org/packages/utrust/utrust). We are using [semantic versioning](https://semver.org) to keep track of package changes. To publish a new package version run the following commands:

```
git tag v1.0.0
git push origin v1.0.0

```

License
-------

[](#license)

xMoney Crypto PHP is maintained with 💜 by the xMoney development team, and is available to the public under the GNU GPLv3 license. Please see [LICENSE](https://github.com/utrustdev/utrust-php/blob/master/LICENSE) for further details.

© Utrust 2024

###  Health Score

37

—

LowBetter than 83% of packages

Maintenance22

Infrequent updates — may be unmaintained

Popularity38

Limited adoption so far

Community18

Small or concentrated contributor base

Maturity59

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 68.2% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~172 days

Recently: every ~290 days

Total

9

Last Release

973d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/851e70a28482da0592cb981d5e7474ee99e26506aa758fd794b047196465863b?d=identicon)[utrust](/maintainers/utrust)

---

Top Contributors

[![danielmcoelho](https://avatars.githubusercontent.com/u/1558992?v=4)](https://github.com/danielmcoelho "danielmcoelho (15 commits)")[![GraceKiarie](https://avatars.githubusercontent.com/u/51403734?v=4)](https://github.com/GraceKiarie "GraceKiarie (4 commits)")[![cswiers](https://avatars.githubusercontent.com/u/61017681?v=4)](https://github.com/cswiers "cswiers (1 commits)")[![fadhili-ed](https://avatars.githubusercontent.com/u/47425400?v=4)](https://github.com/fadhili-ed "fadhili-ed (1 commits)")[![jpmgoncalves](https://avatars.githubusercontent.com/u/2551393?v=4)](https://github.com/jpmgoncalves "jpmgoncalves (1 commits)")

###  Code Quality

TestsPHPUnit

Code StylePHP\_CodeSniffer

### Embed Badge

![Health badge](/badges/utrust-utrust/health.svg)

```
[![Health](https://phpackages.com/badges/utrust-utrust/health.svg)](https://phpackages.com/packages/utrust-utrust)
```

###  Alternatives

[twilio/sdk

A PHP wrapper for Twilio's API

1.6k92.9M272](/packages/twilio-sdk)[facebook/php-business-sdk

PHP SDK for Facebook Business

90821.9M34](/packages/facebook-php-business-sdk)[google/common-protos

Google API Common Protos for PHP

173103.7M50](/packages/google-common-protos)[hubspot/api-client

Hubspot API client

23914.2M16](/packages/hubspot-api-client)[botman/driver-telegram

Telegram driver for BotMan

92437.3k6](/packages/botman-driver-telegram)[turtledesign/royalmail-php

PHP module for interfacing with the Royal Mail shipping api : http://www.royalmail.com/corporate/services/shipping-api

2016.6k](/packages/turtledesign-royalmail-php)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
