Hello!
I'm having trouble putting together the code to connect to a database and control a query.
I created this code through some queries but I have an error when complicating code 4029.
void Check()
{
string uri = "END_POINT_API";
char post[100];
char result1[100];
string headers;
string APIKEY = "";
string LICENCEKEY = "";
int res;
string signal = "?api_key=" + APIKEY + "&license_key=" + LICENSEKEY;
StringToCharArray(signal, post);
// Construct the request headers
headers = "Content-Type: application/json"; // Set the correct header format
// Reset last error
ResetLastError();
// Post data to REST API
res = WebRequest(
"POST",
uri,
headers, // Pass headers as a string
10, // Timeout in seconds
post,
result1, // Store the response in result1
headers // Response headers (optional)
);
// Check errors
if(res == -1)
{
int error_code = GetLastError();
string error_msg = ErrorDescription(error_code);
Print("Error in Webquest. Error Code ",error_code," Error ",error_msg);
if(error_code==4060)
{
MessageBox("Add address '"+uri+"' in Expert Advisors tab of the Options window", "Error", MB_ICONINFORMATION);
}
else
{
// Successful
Print("REST client's POST: ", signal);
Print("Server response: ", CharArrayToString(result1, 0, -1));
}
}
}
//+------------------------------------------------------------------+
Below is the documentation of the API in which I want to query and with the result I will search for some information to validate the license of my products.

It is important to mention that I inserted my end-point in the metatrader 4 options, ruling out that this is why the connection problem occurred.

Похожие заказы
Sniper Strategy EA -Presicion Forex Trading Bot for MT4 and MT5 Sniper Strategy EA is a fully automated Expert Advisor that executes high-probability forex trades using EMA 50/200 trend detection, RSI 14 momentum filtering, and automatic Support and Resistance zone identification. This bot does not chase price — it waits for price to come to key levels and confirms with multiple indicators before entering, just like
There is a programming god without EA here. I want to find someone to make an EA to operate gold and silver. There is a model, but it can't run. So I want to find someone to make professional improvements to make my EA run. If you are interested, you can WECHAT: 15113958263. Please note EA when adding friends
Project Overview I am looking for a high-level Algorithmic Trader / Developer to build a sophisticated, fully automated scalping system for the Nasdaq-100 Future (NQ) . The system must integrate institutional order flow logic with market structure analysis. The core logic must be written in Python , acting as a central hub that bridges ATAS (as the primary data source for Order Flow) and MetaTrader 5 (as the
have the Beatrix Inventor Expert Advisor (EA) that was profitable in the past but has been losing money recently. I need an experienced EA developer/optimizer to study the trade history (especially Stop Loss hits, drawdown periods, SL/TP behavior, win/loss ratio, etc.) and recommend + implement specific tweaks so it becomes consistently profitable again. Your job: 1. Deep analysis of why the EA is no longer
I want a wordpress plugin where our traders can enter their mt5 demo account details to check their equity base trailing drawdown. Once the result is loaded, it will indicate if they breach the account by exceeding certain drawdown % and also indicate how many scalping orders were taken. The program should be able to perform 100 task per minute
Looking for an experienced MQL5 developer to design and develop a custom Expert Advisor (EA) for MetaTrader 5. The purpose of this EA is not just automated trading, but also to help me better structure, test, and refine my personal trading strategy