Hello,
I have been trying in vain to break up the POST request for several hours. Do you have any idea what I'm wrong?
Python (works, I just changed the key)
B4A:
ResponseError. Reason: Not Found, Response: {"message":"Endpoint\/language\/translate\/v2 does not exist"}
I have been trying in vain to break up the POST request for several hours. Do you have any idea what I'm wrong?
Python (works, I just changed the key)
Python:
url = "https://google-translate1.p.rapidapi.com/language/translate/v2"
payload = "source=cs&q=Dobr%C3%BD%20den!&target=en"
headers = {
'x-rapidapi-host': "google-translate1.p.rapidapi.com",
'x-rapidapi-key': "0f2ff54355msh60ff6bcb8a67568p195f88jsn849412bdec67",
'accept-encoding': "application/gzip",
'content-type': "application/x-www-form-urlencoded"
}
response = requests.request("POST", url, data=payload, headers=headers)
B4A:
HttpJop:
Dim j As HttpJob
j.Initialize("", Me) 'name is empty as it is no longer needed
j.download2("https://google-translate1.p.rapidapi.com/language/translate/v2", Array As String("data","source=cs&q=Dobr%C3%BD%20den!&target=en"))
j.GetRequest.SetHeader("x-rapidapi-key","0f2ff54355msh60ff6bcb8a67568p195f88jsn849412bdec67")
j.GetRequest.SetHeader("x-rapidapi-host","google-translate1.p.rapidapi.com")
j.GetRequest.SetHeader("accept-encoding", "application/gzip")
j.GetRequest.SetHeader("content-type", "application/x-www-form-urlencoded")
ResponseError. Reason: Not Found, Response: {"message":"Endpoint\/language\/translate\/v2 does not exist"}