How bbik52/crest works
@bitrix/crest is a small PHP SDK for calling Bitrix24 REST APIs through inbound webhooks or OAuth-backed local and public applications. The main workflow is a PHP entry point invoking CRest, which loads configuration, sends REST requests, and manages authorization settings; installation and server checks are separate entry points. The README also documents batch calls and encoding support. Internal responsibilities share src/crest.php; unsampled implementation details and their connections are not expanded.
Main entry points: crest.php CRest client · checkserver.php Server check · index.php Example request · install.php App installation
Components 13
PHP entry points
- Example request
src/index.php - App installation
src/install.php - Server check
src/checkserver.php
REST SDK
- CRest client
src/crest.php - REST calls
src/crest.php - OAuth handling
src/crest.php - Batch requests
src/crest.php - Encoding conversion
src/crest.php - Runtime diagnostics
src/crest.php
Configuration and state
- SDK settings
src/settings.php - Auth settings storage
src/crest.php
Other components
- Application caller
- Bitrix24 REST and OAuth
Connections 13
- Application caller → Example request: opens example
README.md - Example request → CRest client: invokes client
src/index.php - App installation → CRest client: invokes install
src/install.php - Server check → CRest client: loads client
src/checkserver.php - CRest client → SDK settings: loads config
src/crest.php - CRest client → REST calls: dispatches request
src/crest.php - REST calls → Bitrix24 REST and OAuth: sends REST request
src/crest.php - OAuth handling → Bitrix24 REST and OAuth: requests OAuth token
src/crest.php - CRest client → Auth settings storage: reads and writes
src/crest.php - REST calls → OAuth handling: refreshes on error
src/crest.php - CRest client → Batch requests: supports batching
src/crest.php - REST calls → Encoding conversion: converts data
src/crest.php - Server check → Runtime diagnostics: runs checks
src/checkserver.php