Hi,
It seems that you invoked getMessageContent API using either method
POST or PUT rather than GET.
If PUT/POST is required to use, you need to specify operation
parameters in a message body. Something like
curl --user admin -X POST -d '{"messageId":1}'
http://localhost:8080/api/latest/queue/default/default/TempQueue148d546b-ee1d-4d6d-ba60-f5964f4a5aa2/getMessageContent
You can only set operation parameters as a query string with GET method.
curl --user admin -X GET
http://localhost:8080/api/latest/queue/default/default/TempQueue148d546b-ee1d-4d6d-ba60-f5964f4a5aa2/getMessageContent?messageId=1
As for message id values, you can get message ids by invoking
operation /api/latest/<vhn name>/<vh name>/<queue
name>/getMessageInfo.
Kind Regards,
Alex
On Wed, 10 Feb 2021 at 08:45, bltw15 <[email protected]> wrote:
>
> I'm trying to retrieve message content from the queue, but can't seem to get
> it right. What is an example of using getMessageContent, and where can I
> find the messageId?
>
> http://localhost:8080/api/latest/queue/default/default/TempQueue148d546b-ee1d-4d6d-ba60-f5964f4a5aa2/getMessageContent?messageId=1
>
> return:
> "errorMessage" : "Cannot parse body"
>
> http://localhost:8080/api/latest/queue/default/default/TempQueue148d546b-ee1d-4d6d-ba60-f5964f4a5aa2
> return:
> {
> "id": "e358e151-a8ec-48cc-a7b2-de33d67a0e0e",
> "name": "TempQueue148d546b-ee1d-4d6d-ba60-f5964f4a5aa2",
> "type": "standard",
>
> ...
>
>
>
>
> --
> Sent from: http://qpid.2158936.n2.nabble.com/Apache-Qpid-users-f2158936.html
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [email protected]
> For additional commands, e-mail: [email protected]
>
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]