Contributions
How to Parse/Split HTTP Response Header and transfer to property
I am obtaining the following response to a HTTP Request in SOAP UI TTP/1.1 201 CreatedX-Content-Type-Options: nosniff X-XSS-Protection: 1; mode=blockCache-Control: no-cache, no-store, max-age=0, must-revalidatePragma: no-cacheExpires: 0X-Frame-Options: DENYLocation: /api/authorization_servers/5362c2c46362f0e7f33379e8 Content-Type: application/jsonTransfer-Encoding: chunked I would like to get the value of5362c2c46362f0e7f33379e8in theLocationResponse Header and transfer it to a Project property called "token". Can someone tell me how I am going to do that? I am able to get the entire/api/authorization_servers/5362c2c46362f0e7f33379e8into a variable through Groovy script in this way: def headerValue = testRunner.testCase.getTestStepByName("Register Authorization Server").httpRequest.response.responseHeaders["Location"] I have tried Split method, but it did not work with SOAPUI5.2 and Pro versions. I am not able to proceed any further. Any help is greatly appreciated!726Views0likes0CommentsHow to Parse HTTP Response Header and transfer to property
I am obtaining the following response to a HTTP Request in SOAP UI TTP/1.1 201 CreatedX-Content-Type-Options: nosniff X-XSS-Protection: 1; mode=blockCache-Control: no-cache, no-store, max-age=0, must-revalidatePragma: no-cacheExpires: 0X-Frame-Options: DENYLocation: /api/authorization_servers/5362c2c46362f0e7f33379e8 Content-Type: application/jsonTransfer-Encoding: chunked I would like to get the value of5362c2c46362f0e7f33379e8in theLocationResponse Header and transfer it to a Project property called "token". Can someone tell me how I am going to do that? I am able to get the entire/api/authorization_servers/5362c2c46362f0e7f33379e8into a variable through Groovy script in this way: def headerValue = testRunner.testCase.getTestStepByName("Register Authorization Server").httpRequest.response.responseHeaders["Location"] I have tried Split method, but it did not work with SOAPUI5.2 and Pro versions. I am not able to proceed any further. Any help is greatly appreciated!Solved3.3KViews0likes1Comment