A set of wrapper classes that make using <a href="https://thebotplace.com">The Bot Place</a> API easier — licensing, customers and job-delivery checks for MT5 bots.<br/> The same <code>CTbpBase</code> / <code>CTbpCustomers</code> / <code>CTbpJobs</code> surface is implemented three times: MQL5, C++ and Python, each using the native HTTP/JSON stack of its ecosystem.
</p>
---
## Main Features
- **Three parallel implementations, one API shape**: MQL5 (`Src/MQL5`) uses `WebRequest` + [JsonParserByLeo](https://forge.mql5.io/nique_372/JsonParserByLeo)'s `CJsonParser`; C++ (`Src/C++`) uses libcurl through a small `CHttpClient` wrapper + [simdjson](https://github.com/simdjson/simdjson); Python (`Src/Py`) uses `requests` + its built-in `.json()`. Method names, parameters and behavior match across all three.
- **`CTbpBase`**: holds the api-key and timeout, exposes `GetAllClients()` and the last parsed JSON response (`GetLastJson()` / `m_json`, depending on language).
- **`CTbpCustomers`**: license and customer checks — `GetCustomersSotfware()`, `UserHasSoftware()` (with additional-data binding, e.g. account login), `UserHastSoftwareNoaAdditionalData()` (resale-friendly, no additional-data check), `UserHastSoftwareTelegram()`, `FirstDemoDowlandSoftware()`.
- **`CTbpJobs`**: `GetJobSoftwareAccess()` and `CheckJobDeliveryAccess()`, for validating access to marketplace job deliveries.
- **`ITbpAdditionalData`**: small interface to plug in whatever "additional data" your license check binds to (account login, machine id, etc). MQL5 ships a ready `CAddtionalDataTbpAccountLoggin` that resolves to `AccountInfoInteger(ACCOUNT_LOGIN)`.
- **Wraps every documented endpoint** from [thebotplace.com/documentation](https://thebotplace.com/documentation): job delivery access, all customers, customers of a software, user-has-software (with/without additional data, and the Telegram variant), and first demo download.
├── Src/ # MQL5, C++ and Py implementations (one folder per language)
├── CppEx/ # Standalone C++ usage example
└── Workflows/ # MQL5 test scripts and CI workflow entry (EA.mq5)
```
---
## Requirements
See [dependencies.json](./dependencies.json) for the full list.
- MetaTrader 5, build 5430+ (MQL5) — depends on [JsonParserByLeo](https://forge.mql5.io/nique_372/JsonParserByLeo) and [MQLArticles](https://forge.mql5.io/nique_372/MQLArticles) (`CLoggerBase`)
- C++17+ — depends on [CppBases](https://forge.mql5.io/nique_372/CppBases) (`CLoggerBase`), libcurl and [simdjson](https://github.com/simdjson/simdjson) (see `vcpkg.json`)
- Python >= 3.10.9 — depends on `tsn_utils` (`CLoggerBase`) and `requests` (see `requirements.txt`)
- WebRequest / outbound HTTPS access to `europe-west2-thebotplace.cloudfunctions.net` must be allowed (MT5: add to the WebRequest whitelist)
Requires the `tsndep` package, available on [PyPI](https://pypi.org/project/tsndep). It automatically installs the MQL5 dependencies and runs the Python/C++ hooks declared in `dependencies.json` (`pip install -r requirements.txt`, `vcpkg install`).
### Python package (standalone)
The Python implementation is also published as its own package, without needing `tsndep` or the rest of the repo:
**1. Get your api-key** from [The Bot Place](https://thebotplace.com) and your software id from your bot's dashboard.
**2. Include/import the wrapper for your language** (see usage examples above).
**3. Call the endpoint you need** — results come back either as a return value (`bool`/`out` params) or in the last parsed JSON document, depending on the call (see inline comments in each `Customers`/`Jobs` file — every method states where its result lives).
---
## License
**[Read Full License](./LICENSE)**
By downloading or using this repository, you accept the license terms.