All URIs are relative to https://localhost/api/v3/onepanel
Method | HTTP request | Description |
---|---|---|
getTransfersMock | GET /provider/debug/transfers_mock | Get transfers mock status |
modifyTransfersMock | PATCH /provider/debug/transfers_mock | Modify transfers mock |
TransfersMock getTransfersMock()
Get transfers mock status
Returns information whether transfers mocking is enabled.
var Onepanel = require('onepanel');
var defaultClient = Onepanel.ApiClient.instance;
// Configure API key authorization: api_key1
var api_key1 = defaultClient.authentications['api_key1'];
api_key1.apiKey = 'YOUR API KEY';
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//api_key1.apiKeyPrefix = 'Token';
// Configure API key authorization: api_key2
var api_key2 = defaultClient.authentications['api_key2'];
api_key2.apiKey = 'YOUR API KEY';
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//api_key2.apiKeyPrefix = 'Token';
// Configure HTTP basic authorization: basic
var basic = defaultClient.authentications['basic'];
basic.username = 'YOUR USERNAME';
basic.password = 'YOUR PASSWORD';
var apiInstance = new Onepanel.DebugApi();
var callback = function(error, data, response) {
if (error) {
console.error(error);
} else {
console.log('API called successfully. Returned data: ' + data);
}
};
apiInstance.getTransfersMock(callback);
This endpoint does not need any parameter.
- Content-Type: Not defined
- Accept: application/json
modifyTransfersMock(transfersMock)
Modify transfers mock
Toggle transfers mock. When enabled, all transfers finish successfully without actually transferring data. WARNING: this is a debugging feature disrupting normal Oneprovider operation.
var Onepanel = require('onepanel');
var defaultClient = Onepanel.ApiClient.instance;
// Configure API key authorization: api_key1
var api_key1 = defaultClient.authentications['api_key1'];
api_key1.apiKey = 'YOUR API KEY';
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//api_key1.apiKeyPrefix = 'Token';
// Configure API key authorization: api_key2
var api_key2 = defaultClient.authentications['api_key2'];
api_key2.apiKey = 'YOUR API KEY';
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//api_key2.apiKeyPrefix = 'Token';
// Configure HTTP basic authorization: basic
var basic = defaultClient.authentications['basic'];
basic.username = 'YOUR USERNAME';
basic.password = 'YOUR PASSWORD';
var apiInstance = new Onepanel.DebugApi();
var transfersMock = new Onepanel.TransfersMock(); // TransfersMock | New value for the mock setting.
var callback = function(error, data, response) {
if (error) {
console.error(error);
} else {
console.log('API called successfully.');
}
};
apiInstance.modifyTransfersMock(transfersMock, callback);
Name | Type | Description | Notes |
---|---|---|---|
transfersMock | TransfersMock | New value for the mock setting. |
null (empty response body)
- Content-Type: application/json
- Accept: Not defined