Parameters passed to a web service - Asp . Net MVC

Asked

Viewed 42 times

1

My problem is this, I’m making an app in Xamarin Forms and I have to send two parameters to a web service developed in Asp . Net MVC, in case I would like to know how to send these parameters(two strings) via URL just to test and see if the WEB Service is returning the expected result. For example: http://meuwebservice.com/api/controleChamado/"???????????", I want to know what I can put in place of the questions. I thank those who can help.

Sincerely yours,

  • Hi Diego, thanks for answering. So I set the action to receive two string parameters, param1 and param2. I have another action that takes only one parameter and I pass it normal, as you said : http://url/api/parameter/action name and the server returns me the search. However, I don’t know how to pass two parameters at once, example : http://url/api/minhaaction/"parametro1&parametro2". In case I have to configure the application to receive these concatenated parameters? thank you again.

  • You can use the attribute Route, if it’s a pattern, it can also define as global route or still pass the parameters in the url itself, it would be something like http://endereco.com/api/controleChamado?id=2&idPai=15&outroparam=valor...

No answers

Browser other questions tagged

You are not signed in. Login or sign up in order to post.