Comunidade
NÃO CONSIGO OBTER O ID CIDADE, TOKEN NÃO AUTORIZADO
Olá eu estou com um problema que quando puxo o CEP
https://dev.rte.com.br/reference/unittocity_getcitybyzipcode colocando o header ele diz que não estou autorizado. Eu gero o token aqui
https://dev.rte.com.br/reference/post_token-1
ele me retorna o valor
{
"access_token": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJuYW1laWQiOiIyMDM0NCIsInVuaXF1ZV9uYW1lIjoiRVZBUE9FU1RFIFNPTCBFTSBDTElNQVRJWkFDT0VTIExUREEiLCJodHRwOi8vc2NoZW1hcy5ydGUuY29tLmJyL2lkZW50aXR5L2NsYWltcy9jb21wYW55aWQiOiIxIiwiaHR0cDovL3NjaGVtYXMucnRlLmNvbS5ici9pZGVudGl0eS9jbGFpbXMvdXNlcmNvbXBhbnlpZCI6IjM0MDU1IiwiaHR0cDovL3NjaGVtYXMucnRlLmNvbS5ici9pZGVudGl0eS9jbGFpbXMvaXN1c2VybWFzdGVyIjoiTiIsImh0dHA6Ly9zY2hlbWFzLnJ0ZS5jb20uYnIvaWRlbnRpdHkvY2xhaW1zL2F1dGh0eXBlIjoiREVWIiwibmJmIjoxNzMwNzM1OTYwLCJleHAiOjE3MzA3NjQ3NjAsImlhdCI6MTczMDczNTk2MCwiaXNzIjoicnRlZnJhbWV3b3JrIiwiYXVkIjoiOEUxRDMwQjctMTE4NC00OTFFLUJEMkYtQjkwMDdCQ0M0NjBGIn0.Jo42SkbNCNxfCtZuF4bIJO5Zedh02RrtVbBp8hRLnXU",
"token_type": "bearer",
"userId": "20344",
"expires_in": "28800",
"name": "EVAPOESTE SOL EM CLIMATIZACOES LTDA",
"companyId": "1",
"userCompanyId": "34055",
"isMaster": "N",
".issued": "Mon, 04 Nov 2024 15:59:20 GMT",
".expires": "Mon, 04 Nov 2024 23:59:20 GMT"
}
pego essa informação access_token e coloco assim dentro do header
Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJuYW1laWQiOiIyMDM0NCIsInVuaXF1ZV9uYW1lIjoiRVZBUE9FU1RFIFNPTCBFTSBDTElNQVRJWkFDT0VTIExUREEiLCJodHRwOi8vc2NoZW1hcy5ydGUuY29tLmJyL2lkZW50aXR5L2NsYWltcy9jb21wYW55aWQiOiIxIiwiaHR0cDovL3NjaGVtYXMucnRlLmNvbS5ici9pZGVudGl0eS9jbGFpbXMvdXNlcmNvbXBhbnlpZCI6IjM0MDU1IiwiaHR0cDovL3NjaGVtYXMucnRlLmNvbS5ici9pZGVudGl0eS9jbGFpbXMvaXN1c2VybWFzdGVyIjoiTiIsImh0dHA6Ly9zY2hlbWFzLnJ0ZS5jb20uYnIvaWRlbnRpdHkvY2xhaW1zL2F1dGh0eXBlIjoiREVWIiwibmJmIjoxNzMwNzM1OTYwLCJleHAiOjE3MzA3NjQ3NjAsImlhdCI6MTczMDczNTk2MCwiaXNzIjoicnRlZnJhbWV3b3JrIiwiYXVkIjoiOEUxRDMwQjctMTE4NC00OTFFLUJEMkYtQjkwMDdCQ0M0NjBGIn0.Jo42SkbNCNxfCtZuF4bIJO5Zedh02RrtVbBp8hRLnXU
e ele não funciona.
ele da o seguinte erro
{
"Message": "Authorization has been denied for this request."
}
consegue me ajudar?