Евгений Ю. Лозный 2dbe18f268 Pull request #62: Release/3.14.0
Merge in SDK/yookassa-sdk-php from release/v3.14.0 to master

* commit '260d13f8909ed7cd169146217b731fe69970420a':
  Добавлен прием платежей через Alfa Pay. Добавлен новый тип ошибки RuleViolationError Добавлены нулевые привязки по СБП Добавлена причина отмены возвратов `payment_expired`
2026-06-29 17:50:37 +03:00

The YooKassa API PHP Client Library

Latest Stable Version Total Downloads Monthly Downloads License

Russian | English

This product is used for managing payments under The YooKassa API. For usage by those who implemented YooKassa using the API method.

⚠️ Update the YooMoney SDK before January 1

Starting from January 1, 2026, the standard VAT rate in Russia will be increased from 20% to 22%.

If you work with the standard rate, update the YooMoney SDK so that receipts are generated correctly.

If you don't update, the receipts will be sent with the 20% rate which may result in questions and fines from the Federal Tax Service, as well as manual correction of transactions.

Requirements

PHP 8.0 (or later version) with the libcurl library

Installation

Under console using Composer

  1. Install Composer, a package manager.
  2. In the console, run the following command:
composer require yoomoney/yookassa-sdk-php

Do the following for the composer.json file of your project:

  1. Add a string "yoomoney/yookassa-sdk-php": "^3.0" to the list of dependencies of your project in the composer.json file:
...
   "require": {
        "php": ">=8.0",
        "yoomoney/yookassa-sdk-php": "^3.0"
...
  1. Refresh the project's dependencies. In the console, navigate to the catalog with composer.json and run the following command:
composer update
  1. Adjust your project's code to activate automated uploading of files for our product:
require __DIR__ . '/vendor/autoload.php';

Commencing work

  1. Import required classes:
use YooKassa\Client;
  1. Create a sample of a client object, then set the store's identifier and secret key (you can get them under your YooKassa's Merchant Profile). Issuing a secret key
$client = new Client();
$client->setAuth('shopId', 'secretKey');
  1. Call the required API method.

    More details in our documentation for the YooKassa API

    More details in our documentation for the YooKassa SDK

Examples of using the API SDK

What's new in SDK version 3.x

YooKassa SDK Settings

Working with payments

Working with refunds

Working with receipts

Working with safe deals

Working with payouts

Working with self-employed

Working with personal data

Working with the list of Fast Payment Service participants

Working with invoices

Working with payment methods

S
Description
No description provided
Readme 15 MiB
Languages
PHP 100%