Contributions
Re: How to set the Request Header for a REST service
Thank you both for your comments. I found the RAW panelto bequite useful while testing. I've now managed to setup and test the two REST services with a JSON Request, returning aJSON Response.7 years agoPlace ReadyAPI QuestionsReadyAPI Questions9.7KViews0likes0CommentsRe: How to set the Request Header for a REST service
Having read through some further ReadyAPI Documentation, I see that the text area below the Media Type (application/json) dropdown is called the "Content Editor". Is this where the json request body arguments should be set? I.e. rather thanas request parameters under theParameter editor? HEADERS = {'apitoken': XXXX} resp = requests.post( url= 'https://xxxx.xxxxxxx.com/rest/xxxx/search' data={'name': nameArg, 'country': countryArg}, headers=HEADERS ) I.e. for the JSON example I am trying to simulate/test (above) in ReadyAPI, should I be entering the following under the "Content Editor", instead of adding them as request parameters? {'name': NameArg, 'country': CountryArg}7 years agoPlace ReadyAPI QuestionsReadyAPI Questions9.8KViews0likes3CommentsRe: How to set the Request Header for a REST service
Many thanks for the clarification around the header.Just curious about the otherhorizontal panels such as "Auth", given that you have mentioned the Horizontal Request panel only applies to individual requests. Does that mean Authentication configured through that tab would only apply to a individual request, and that you could have different authentication configurations for different requests within a individual REST service project in ReadyAPI? This next question isn't really around the header, but as it's related toone of the REST service API methods I'm attempting to test, I'm raising it under this topic. This is the JSON request code snippet which I've been givento try& simulate/setup in ReadyAPI. ******************************* HEADERS = {'apitoken': XXXX} resp = requests.post( url= 'https://xxxx.xxxxxxx.com/rest/xxxx/search' data={'name': nameArg, 'country': countryArg}, headers=HEADERS ) ******************************* Wouldyou be able to confirm ifthis is the correct way to set it up in ReadyAPI?A JSON (not XML) request and response would be required here.The associatedscreenshot is attached. Method = POST Endpoint = https://xxxx.xxxxxxx.com Resource = /rest/xxxx/search Vertical Request Parameters tab line items: Name: name, Value: nameArg, Style: QUERY, Level: METHOD Name: country, Value: countryArg, Style: QUERY, Level: METHOD Name: apitoken, Value: XXXX, Style: HEADER, Level: RESOURCE MediaType = application/json7 years agoPlace ReadyAPI QuestionsReadyAPI Questions9.8KViews0likes4CommentsHow to set the Request Header for a REST service
I need some clarity onhow to correctly set request header attributesin ReadyAPI - SOAP UI Pro, and am hoping someone on this forum is able to help. As I am very new to the ReadyAPI tool, I was looking at the ReadyAPI documentation. I see that there is a REST Parameter Style called "HEADER" which can be selected when adding/setting parameters under theREQUEST parameters table (vertical tab) for the service. But in addition to this there is also a "Headers Panel" at the bottom of the screen (horizontal tab just after the Auth tab) where you appear to be able to add header values as key/value pairs. Can someone clarify what the difference is between these two, andwhich should be used to set request header attributes? The REST service I am attempting to test, requires a fixed apitoken value to be set in the header, and it's currently unclear to me how this should be set in the ReadyAPI interface. Any assistance would be appreciated.7 years agoPlace ReadyAPI QuestionsReadyAPI Questions9.9KViews0likes6Comments