Full list of buzzwords, patterns and dependencies used in SDK.
- Bitrix24 REST API and Marketing Applications
- namespaces: Organize code into logical groups
- env variables: Access environment-specific configuration
- generators: Create iterators for large data sets efficiently
- interfaces: Define contracts for classes
- inheritance: Extend class functionality
- PSR-3: Logger Interface: Common interface for logging libraries.
- PSR-7: HTTP message interfaces: Common interfaces for representing HTTP messages as described in RFC 7230 and RFC 7231, and URIs for use with HTTP messages as described in RFC 3986.
- Fabric: Create objects without specifying exact class
- Observer: Implement publish-subscribe architecture
- Builder: Design pattern that lets you construct complex objects step by step
- Strategy: Behavioral design pattern that lets you define a family of algorithms, put each of them into a separate class, and make their objects interchangeable.
- The Twelve-Factor App: The twelve-factor app is a methodology for building software-as-a-service apps.
- composer: PHP dependency management tool
- make: Automate build processes
- env-files: Store configuration in the environment
- yaml: YAML is a data serialisation language designed to be directly writable and readable by humans.
- GitHub Actions: automate tasks throughout the software development lifecycle.
- ngrok: Share your local app without deploying
- PHP built-in web-server: This web server is designed to aid application development. It may also be useful for testing purposes or for application demonstrations that are run in controlled environments.
- cURL: Command line tool and library for transferring data with URLs
- phpunit: PHP testing framework
- phpstan: PHP static analysis tool
- rector: PHP automated refactoring tool
- monolog: Logging for PHP, supports severity levels from rfc5424
- libphonenumber for PHP: Library for parsing, formatting, storing and validating international phone numbers. This library is based on Google's libphonenumber.
- darsyn\IP: IP is an immutable value object for (both version 4 and 6) IP addresses.
- carbon: Simple PHP API extension for DateTime.
- moneyphp: PHP implementation of the Money pattern, as described in Patterns of Enterprise Application Architecture.
- moneyphp-percentage: Percentage (VAT) value object for moneyphp/money package.
- symfony/http-client: low-level HTTP client with support for both PHP stream wrappers and cURL. It provides utilities to consume APIs and supports synchronous and asynchronous operations.
- symfony/console: eases the creation of beautiful and testable command line interfaces.
- symfony/dotenv: parses .env files to make environment variables stored in them
accessible via
$_SERVERor$_ENV. - symfony/filesystem: provides platform-independent utilities for filesystem operations and for file/directory paths manipulation.
- symfony/mime: allows manipulating the MIME messages used to send emails and provides utilities related to MIME types.
- symfony/finder: finds files and directories based on different criteria (name, file size, modification time, etc.) via an intuitive fluent interface.
- symfony/http-client-contracts: a set of abstractions extracted out of the Symfony components.
- symfony/http-foundation: defines an object-oriented layer for the HTTP specification.
- symfony/event-dispatcher: provides tools that allow your application components to communicate with each other by dispatching events and listening to them.
- symfony/uid: provides utilities to work with unique identifiers (UIDs) such as UUIDs and ULIDs.
- use incoming webhooks.
- use OAuth2.0 for applications.
All methods list, this list build automatically.
In SDK all methods grouped by scope. If service still not implemented in SDK, You can directly call from SDK core:
declare(strict_types=1);
use Bitrix24\SDK\Services\ServiceBuilderFactory;
require_once 'vendor/autoload.php';
// init bitrix24-php-sdk service from webhook
$b24Service = ServiceBuilderFactory::createServiceBuilderFromWebhook('INSERT_HERE_YOUR_WEBHOOK_URL');
// call core if method not implemented in services
var_dump($b24Service->core->call('user.current')->getResponseData()->getResult());After that You can create new issue on GitHub – 🚀 SDK Feature Request, and we add new method support in services.
If you build application based on bitrix24-php-sdk You can use some domain contracts for interoperability.
They store in folder src/Application/Contracts.
Available contracts
- Bitrix24Accounts – store auth tokens and provides methods for work with Bitrix24 account.
- ApplicationInstallations – Store information about application installation, linked with Bitrix24 Account with auth tokens.
- ContactPersons – Store information about person who installed application.
- Bitrix24Partners – Store information about Bitrix24 Partner who supports client portal and install or configure application.
In SDK implemented exceptions hierarchy, they stored in Bitrix24\SDK\Core\Exceptions folder.
declare(strict_types=1);
use Bitrix24\SDK\Core\Exceptions\InvalidArgumentException;
use Bitrix24\SDK\Services\ServiceBuilderFactory;
require_once 'vendor/autoload.php';
try {
// init bitrix24-php-sdk service from webhook
$b24Service = ServiceBuilderFactory::createServiceBuilderFromWebhook('INSERT_HERE_YOUR_WEBHOOK_URL');
// call unknown method and throw exception
$b24Service->core->call('Unknown method');
} catch (InvalidArgumentException $exception) {
print(sprintf('ERROR IN CONFIGURATION OR CALL ARGS: %s', $exception->getMessage()) . PHP_EOL);
print($exception::class.PHP_EOL);
print($exception->getTraceAsString());
} catch (Throwable $throwable) {
print(sprintf('FATAL ERROR: %s', $throwable->getMessage()) . PHP_EOL);
print($throwable::class.PHP_EOL);
print($throwable->getTraceAsString());
}- Create file
/tests/.env.local- set env variable
BITRIX24_WEBHOOK - set env variable
DOCUMENTATION_DEFAULT_TARGET_BRANCH, default valueblob/master
- set env variable
- Call make file
make build-documentation- Commit updated file
/docs/EN/Services/bitrix24-php-sdk-methods.md