Created
November 27, 2017 19:49
-
-
Save edgars/daafb6ac6fbee51425252fb1eea1bfb3 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@http:resourceConfig { | |
methods:["GET"], | |
path:"/marcas/{tipoVeiculo}" | |
} | |
resource marcas (http:Request req, http:Response res, string tipoVeiculo) { | |
// https://fipe.parallelum.com.br/api/v1/{carros}/marcas {motos, caminhoes, carros} | |
http:Response clientResponse = {}; | |
clientResponse, err = httpConnector.get("/"+ tipoVeiculo +"/marcas", {}); | |
println("GET request: Marca Veiculos "); | |
res.forward(clientResponse); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment