ASG
IBM
Zystems
Cressida
Icon
Netflexity
 
  MQSeries.net
Search  Search       Tech Exchange      Education      Certifications      Library      Info Center      SupportPacs      LinkedIn  Search  Search                                                                   FAQ  FAQ   Usergroups  Usergroups
 
Register  ::  Log in Log in to check your private messages
 
RSS Feed - WebSphere MQ Support RSS Feed - Message Broker Support

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » REST Api Error

Post new topic  Reply to topic
 REST Api Error « View previous topic :: View next topic » 
Author Message
wmbfrz
PostPosted: Wed Feb 24, 2016 4:56 am    Post subject: Reply with quote

Apprentice

Joined: 08 Jan 2010
Posts: 28

Hi,
I am using SoapUI for sending a POST request to my REST API and i copied the url from my Integration server. I am getting the error "BIP6311E: REST API ''SearchServiceTrial4'' does not support method ''POST'' for URL ''http://localhost:7804/travelrefapp/searchflight;roundTrip=false;departingAirport=Mumbai;departureDate=2016-05-04''. "
Back to top
View user's profile Send private message
Vitor
PostPosted: Wed Feb 24, 2016 5:36 am    Post subject: Reply with quote

Grand High Poobah

Joined: 11 Nov 2005
Posts: 26093
Location: Texas, USA

wmbfrz wrote:
I am getting the error "BIP6311E: REST API ''SearchServiceTrial4'' does not support method ''POST'' for URL ''http://localhost:7804/travelrefapp/searchflight;roundTrip=false;departingAirport=Mumbai;departureDate=2016-05-04''. "


Well that seems clear enough. Whatever "SearchServiceTrial4" is (and I'm quietly confident that's user code not the IIB software), it doesn't support a POST method.

Include that support (or change where you've accidentally supported GET not POST) and try again.
_________________
Honesty is the best policy.
Insanity is the best defence.
Back to top
View user's profile Send private message
stoney
PostPosted: Wed Feb 24, 2016 5:46 am    Post subject: Reply with quote

Centurion

Joined: 03 Apr 2013
Posts: 140

Does the error message say 405 Method Not Allowed, or 404 Not Found?
If it says 405 Method Not Allowed, then the URL is right but the HTTP method wrong - maybe it should be GET instead of POST.
If it says 404 Not Found, then the URL is wrong and you need to check it.

Is your URL meant to have semicolon separated key value pairs? Is it possible that they're meant to be supplied as a query string, ie:

Code:
http://localhost:7804/travelrefapp/searchflight?roundTrip=false&departingAirport=Mumbai&departureDate=2016-05-04
Back to top
View user's profile Send private message
wmbfrz
PostPosted: Wed Feb 24, 2016 5:52 am    Post subject: Reply with quote

Apprentice

Joined: 08 Jan 2010
Posts: 28

Vitor wrote:
wmbfrz wrote:
I am getting the error "BIP6311E: REST API ''SearchServiceTrial4'' does not support method ''POST'' for URL ''http://localhost:7804/travelrefapp/searchflight;roundTrip=false;departingAirport=Mumbai;departureDate=2016-05-04''. "


Well that seems clear enough. Whatever "SearchServiceTrial4" is (and I'm quietly confident that's user code not the IIB software), it doesn't support a POST method.

Include that support (or change where you've accidentally supported GET not POST) and try again.


I wrote a Swagger doc using editor.swagger.io and created an REST API in IIB10. The swagger is valid and it has POST operations as method
Back to top
View user's profile Send private message
wmbfrz
PostPosted: Wed Feb 24, 2016 5:56 am    Post subject: Reply with quote

Apprentice

Joined: 08 Jan 2010
Posts: 28

stoney wrote:
Does the error message say 405 Method Not Allowed, or 404 Not Found?
If it says 405 Method Not Allowed, then the URL is right but the HTTP method wrong - maybe it should be GET instead of POST.
If it says 404 Not Found, then the URL is wrong and you need to check it.

Is your URL meant to have semicolon separated key value pairs? Is it possible that they're meant to be supplied as a query string, ie:

Code:
http://localhost:7804/travelrefapp/searchflight?roundTrip=false&departingAirport=Mumbai&departureDate=2016-05-04


thnxs for the reply. Its 404. My application is suppose to receive a json request. I defined my REST API to send the POST parameters in body. I guess i am mistaking in generating the POST req in SOAPUI. i entered the parameters with style as matrix and level as METHOD (also tried with level = resource).
Back to top
View user's profile Send private message
fjb_saper
PostPosted: Wed Feb 24, 2016 5:59 am    Post subject: Reply with quote

Grand High Poobah

Joined: 18 Nov 2003
Posts: 20756
Location: LI,NY

wmbfrz wrote:
I defined my REST API to send the POST parameters in body.

What other options does SOAPUI offer you?
_________________
MQ & Broker admin
Back to top
View user's profile Send private message Send e-mail
wmbfrz
PostPosted: Wed Feb 24, 2016 6:09 am    Post subject: Reply with quote

Apprentice

Joined: 08 Jan 2010
Posts: 28

fjb_saper wrote:
wmbfrz wrote:
I defined my REST API to send the POST parameters in body.

What other options does SOAPUI offer you?


for styles: query, header, plain, matrix, template
for level: resource, method
Back to top
View user's profile Send private message
fjb_saper
PostPosted: Wed Feb 24, 2016 9:16 am    Post subject: Reply with quote

Grand High Poobah

Joined: 18 Nov 2003
Posts: 20756
Location: LI,NY

wmbfrz wrote:
fjb_saper wrote:
wmbfrz wrote:
I defined my REST API to send the POST parameters in body.

What other options does SOAPUI offer you?


for styles: query, header, plain, matrix, template
for level: resource, method

I meant for sending the parameters!
_________________
MQ & Broker admin
Back to top
View user's profile Send private message Send e-mail
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » REST Api Error
Jump to:  



You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
Protected by Anti-Spam ACP
 
 


Theme by Dustin Baccetti
Powered by phpBB © 2001, 2002 phpBB Group

Copyright © MQSeries.net. All rights reserved.