0 votes

request("https://" + username + ":" + password + "@api.twilio.com/2010-04-01/Accounts/" + username + "/Messages.json")

The above code in the HTTP request node gives me the following error:
1)
E 0:00:03.909 toint: Cannot represent (password)@api.twilio.com as integer, provided value is too big.
<C++ Error> Condition "integer > 2147483647 / 10" is true. Returned: sign == 1 ? 2147483647 : (-2147483647 - 1)
<C++ Source> core/ustring.cpp:1792 @ to
int()
HTTPRequest.gd:20 @ onButtonpressed()
2)
E 0:00:03.912 _parse
url: Condition "port < 1 || port > 65535" is true. Returned: ERRINVALIDPARAMETER
<C++ Source> scene/main/httprequest.cpp:81 @ _parseurl()
HTTPRequest.gd:20 @ onButton_pressed()

asked Apr 14 in Engine by God Of Theory (42 points)
edited Apr 14 by God Of Theory

Ive removed the username and password part and it successfully connected to the API,but it says I did not do authentication,so I used post method to pass in the authentication with the header as follow:

["username:password"]

but it still does not work.....It says the same thing...
Can anyone please explain how do I connect to twilio REST API with Godot with authentication?????

Please log in or register to answer this question.

Welcome to Godot Engine Q&A, where you can ask questions and receive answers from other members of the community.

Please make sure to read How to use this Q&A? before posting your first questions.