Questions tagged [http-request-parameters]

The parameters that are mapped to the servlet request when they are parsed from the http request.

The parameters that are mapped to the servlet request when they are parsed from the http request. These parameters represent a query string when a method GET is used and a body of the request if a method POST is used.

276 questions
0
votes
1 answer

Java Spring - How to take in RequestParam, and remove from url?

Sometimes I will want to pass in an identifier to my website through the url, but I don't want to display this to the user. Is there a simple way to take in a request param but not display it to the user when loading the page? This is a general idea…
JR3652
  • 435
  • 1
  • 4
  • 13
0
votes
1 answer

Is there a better way to construct a controller with multiple parameters the might not be required?

I'm making a simple spring boot application and i have to get a list of objects, which i filter by parameters that aren't required. So basically the user can send the parameters, but doesn't have to. Best solution that i found is the use of…
aratata
  • 1,147
  • 1
  • 6
  • 22
0
votes
2 answers

java pass string web request to non string @RequestParam

I am working on a react application that has a java backend. The react frontend sends a URL request to a java web service controller, and within that webservice controller, the variable types are defined. Since a URL request is a string I’m having…
0
votes
1 answer

passing request params in twitter call back url

I am working on a CustomerEngagement solution that is integrated with twitter. Looking for suggestion with implementation. I have configured multiple twitter-apps with a call back URL for each twitter-app (same callback URL), pointing to the same…
0
votes
1 answer

Limit the number of the same request param in spring

I have the GET request like /api/v1/data?name=aaa&name=bbb&name=cccc&name=dd&name.... I want to limit the number of 'name' param, it must be no more than 100 (configurable in properties file) Here is my controller public Data…
Loc Le
  • 537
  • 1
  • 8
  • 21
0
votes
1 answer

Can I pass an object as one of the parameters when I do the get request?

I have an parameter values like this: user = {id: 1, name="tester", age="23"} Can I pass the entire object as one of parameters in HTTP.GET request? If yes, how can I test it in my postman?
fancylynn
  • 139
  • 1
  • 12
0
votes
1 answer

How do I exchange a OAuth 2.0 authorization code for an access token?

I need to interact with an HMRC (UK Inland revenue) REST API. They've given me example code in Java can anyone help me to translate it into C#? I'm assuming I have to add the Client ID, Client Secret, Re-Direct Uri & Authorisation code to an…
0
votes
1 answer

Rest API end Point

Why can't I use TreeMap after @RequestParam ? It works when I use Map Example: @RequestMapping(value = "customers/new", method = RequestMethod.POST, consumes = MediaType.APPLICATION_JSON_VALUE) public…
James Kristen
  • 75
  • 1
  • 3
  • 12
0
votes
1 answer

Passing a map in GET, JAVA

How do i Pass a Map of Key Value pairs to a GET REST API, Here is the call to the resource .. I am getting a method not allowed String queryMap= String.format("{'softwareversion':'%s','peril':'%s','analysistype':'%s', 'region':'%s'}", "HD18",…
user3897533
  • 417
  • 1
  • 8
  • 24
0
votes
2 answers

Spring 2nd RequestParam always ignored

I might need your help to understand why my Java Spring code is not working. I have a HTTP Get Method, in which I'd like to pass two request parameters. While the first parameter is passed perfectly fine, the second one is always null or…
amaridev
  • 31
  • 4
0
votes
2 answers

Add custom GET Parameter logic to restful class in Ruby on Rails

I have a UsersController and RegistrationsController to handle user signups with Devise in rails. I am adding code for affiliate sign ups, in order to map users to affiliates using a custom HTTP GET parameter called "a". So for example, I want my…
bluebit
  • 2,987
  • 7
  • 34
  • 42
0
votes
0 answers

Apache Camel - how to pass query parameter into velocity template

I've got camel (2.16.4) routes described in Spring DSL like this ... ... Typical request is like…
WeGa
  • 801
  • 4
  • 10
  • 24
0
votes
1 answer

How to search for multiply(batch) params in Spring boot?

I would like to batch search for entities like that: GET api/stuff?ids=123+456+789+101112+... I have found out that it is possible to get the request param like that: @RequestMapping(method = RequestMethod.GET, value = "/stuff") public String…
GaborH
  • 689
  • 2
  • 11
  • 24
0
votes
1 answer

Access file system through query string or params

I have been given a task of reproducing the issue/testing the unauthorized access to file system through request.param and query string. For instance i have something like this. request.querystring("blah"); How could somebody pass "../../../b1/b2"…
0
votes
2 answers

Etat HTTP 400 - Required String parameter 'color' is not present in spring mvc controller?

First the modal of team Update where Team is an entity in my spring mvc application Then The controller method and the updateTeam method implementation: Here is the code: