21.02.2023, 13:10
the problem was the quotes in the token and that esios had two servers to make test.
The way is as follow:
The way is as follow:
Code:
token='xxxxxxxxxxxxxx'
body, code, hdrs, stat = https.request ({ --Llamada HTTP formada por URL+metodo+cabecera
url = url;
method = 'GET';
headers = {
['Accept'] = 'application/json; application/vnd.esios-api-v1+json';
['Content-Type'] = 'application/json';
['x-api-key'] = token;
};
source = ltn12.source.string(payload);
sink = ltn12.sink.table(response_body);
})