- Home
- Comunidad
- Programación
- Using API myfxbook from MQL
Edit Your Comment
Using API myfxbook from MQL
Miembro desde Jan 31, 2013
posts 1
Jun 08, 2015 at 15:00
Miembro desde Jan 31, 2013
posts 1
Hi!
Help please how correctly to make login from MQL to myfxbook through WebRequest.
// .........................
string headers;
char post [], result [];
StringToCharArray ("[email protected]&password=123456", post); // Must specify string length; otherwise array has terminating null character in it
int res = WebRequest ("POST", "https://www.myfxbook.com/api/login.json", "", NULL, 10000, post, ArraySize (post), result, headers);
Print ("Status code:", res, ", error:", GetLastError ());
Print ("Server response:", CharArrayToString (result));
// ..............................
Result:
Status code: -1, error: 5203
Server response: send request failed [2148074278]
WebRequest to sites https://www.myfxbook.com and https://www.myfxbook.com/ in MT4 allowed
Thank you.
Help please how correctly to make login from MQL to myfxbook through WebRequest.
// .........................
string headers;
char post [], result [];
StringToCharArray ("[email protected]&password=123456", post); // Must specify string length; otherwise array has terminating null character in it
int res = WebRequest ("POST", "https://www.myfxbook.com/api/login.json", "", NULL, 10000, post, ArraySize (post), result, headers);
Print ("Status code:", res, ", error:", GetLastError ());
Print ("Server response:", CharArrayToString (result));
// ..............................
Result:
Status code: -1, error: 5203
Server response: send request failed [2148074278]
WebRequest to sites https://www.myfxbook.com and https://www.myfxbook.com/ in MT4 allowed
Thank you.
Miembro desde Aug 27, 2015
posts 1
Miembro desde Mar 14, 2014
posts 1
Mar 18, 2016 at 07:10
Miembro desde Mar 14, 2014
posts 1
int result = WebRequest("GET", "https://www.myfxbook.com/api/login.json", NULL, NULL, Timeout, post, 0, result, resultHeaders);
*El uso comercial y el spam no serán tolerados y pueden resultar en el cierre de la cuenta.
Consejo: Al publicar una imagen o una URL de YouTube, ésta se integrará automáticamente en su mensaje!
Consejo: Escriba el signo @ para completar automáticamente un nombre de usuario que participa en esta discusión.