chatway / mt4-micro-php-client
v1.0.3
2022-10-03 11:30 UTC
Requires
- php: >=5.5
- ext-curl: *
- ext-json: *
- ext-mbstring: *
- guzzlehttp/guzzle: ^7.0.1
Requires (Dev)
- friendsofphp/php-cs-fixer: ~2.12
- phpunit/phpunit: ^4.8
- squizlabs/php_codesniffer: ~2.6
This package is auto-updated.
Last update: 2024-05-30 00:42:23 UTC
README
Mt4 microservice. Call /init/ to get token, which is required in other methods.
This PHP package is automatically generated by the Swagger Codegen project:
- API version: 1.0
- Build package: io.swagger.codegen.languages.PhpClientCodegen
Requirements
PHP 5.5 and later
Installation & Usage
Composer
To install the bindings via Composer, add the following to composer.json
:
{
"repositories": [
{
"type": "git",
"url": "https://github.com//.git"
}
],
"require": {
"/": "*@dev"
}
}
Then run composer install
Manual Installation
Download the files and include autoload.php
:
require_once('/path/to/SwaggerClient-php/vendor/autoload.php');
Tests
To run the unit tests:
composer install
./vendor/bin/phpunit
Getting Started
Please follow the installation procedure and then run the following:
<?php require_once(__DIR__ . '/vendor/autoload.php'); $apiInstance = new Swagger\Client\Api\GroupsApi( // If you want use custom http client, pass your client which implements `GuzzleHttp\ClientInterface`. // This is optional, `GuzzleHttp\Client` will be used as default. new GuzzleHttp\Client() ); $token = "token_example"; // string | $accept = "accept_example"; // string | try { $apiInstance->groupsGet($token, $accept); } catch (Exception $e) { echo 'Exception when calling GroupsApi->groupsGet: ', $e->getMessage(), PHP_EOL; } ?>
Documentation for API Endpoints
All URIs are relative to https://apps.noorcm.com:6502/v1
Class | Method | HTTP request | Description |
---|---|---|---|
GroupsApi | groupsGet | GET /groups | Get list of groups |
InitApi | initGet | GET /init | Init manager |
SymbolsApi | symbolsGet | GET /symbols | Get list of market symbols |
TradesApi | tradesByUserLoginGet | GET /trades/{user_login} | Get list of trade tickets |
TradesApi | usersReportPost | POST /users/report | Get list of user trades |
UserApi | 5069Get | GET /5069 | Get user margin |
UserApi | userAddPost | POST /user/add | Create user |
UserApi | userByUserLoginDelete | DELETE /user/{user_login} | Delete user |
UserApi | userByUserLoginGet | GET /user/{user_login} | Get user by user login |
UserApi | userDepositPost | POST /user/deposit | Deposit account |
UserApi | userResetPwdPost | POST /user/reset_pwd | Reset password |
UserApi | userUpdatePost | POST /user/update | Update user |
UserApi | userWithdrawPost | POST /user/withdraw | Withdraw account |
UsersApi | usersGet | GET /users | Get list of users |
Documentation For Models
- CreateuserRequest
- Depositaccount
- DepositaccountRequest
- GetlistofusertradesRequest
- ResetpasswordRequest
- UpdateuserRequest
- WithdrawaccountRequest
Documentation For Authorization
All endpoints do not require authorization.