Revision history [back]

click to hide/show revision 1
initial version

How to create subscriptions for queue in CLI

How do I add a subcription to a queue in Zaqar

A queue named sample queue is created with a 201 response. While Post a subscription to the queue I'm facing a Bad Request body error.

I have tired the following,

curl -i -X POST http://IP/v2/queues/samplequeue/subscriptions -H "Content-type: application/json" -d '{'subscriber': 'mailto:fake@123.com', 'options': {'MessagingKeyMessagin': 'MessagingValueMessag'}, 'ttl': 361284}' -H "Client-ID: de305d54-75b4-431b-adb2-eb6b9e546014" -H "X-Auth-Token: fa23084ada85469cad4951ae4b2e51ca"

Response:

HTTP/1.0 400 Bad Request

Date: Thu, 28 Apr 2016 06:19:29 GMT

Server: WSGIServer/0.1 Python/2.7.6

content-length: 95

content-type: application/json

{ "title": "Invalid request body",

"description": "Request body could not be parsed."

}

Suggest where I'm going wrong :) Thanks in advance.

How to create subscriptions for queue in CLI

How do I add a subcription to a queue in Zaqar

A queue named sample queue is created with a 201 response. While Post I try to post a subscription to the queue I'm facing a Bad Request body error.

I have tired the following,

curl -i -X POST http://IP/v2/queues/samplequeue/subscriptions -H "Content-type: application/json" -d '{'subscriber': 'mailto:fake@123.com', 'options': {'MessagingKeyMessagin': 'MessagingValueMessag'}, 'ttl': 361284}' -H "Client-ID: de305d54-75b4-431b-adb2-eb6b9e546014" -H "X-Auth-Token: fa23084ada85469cad4951ae4b2e51ca"

Response:

HTTP/1.0 400 Bad Request

Date: Thu, 28 Apr 2016 06:19:29 GMT

Server: WSGIServer/0.1 Python/2.7.6

content-length: 95

content-type: application/json

{ "title": "Invalid request body",

"description": "Request body could not be parsed."

}

Suggest where I'm going wrong :) Thanks in advance.

How to create subscriptions for queue in CLI

How do I add a subcription to a queue in Zaqar

A queue named sample queue is created with a 201 response. While I try to post a subscription to the queue I'm facing a Bad Request body error.

I have tired the following,

curl -i -X POST http://IP/v2/queues/samplequeue/subscriptions -H "Content-type: application/json" -d '{'subscriber': 'mailto:fake@123.com', 'options': {'MessagingKeyMessagin': 'MessagingValueMessag'}, 'ttl': 361284}' -H "Client-ID: de305d54-75b4-431b-adb2-eb6b9e546014" -H "X-Auth-Token: fa23084ada85469cad4951ae4b2e51ca"

Response:

HTTP/1.0 400 Bad Request

Date: Thu, 28 Apr 2016 06:19:29 GMT

Server: WSGIServer/0.1 Python/2.7.6

content-length: 95

content-type: application/json

{ "title": "Invalid request body",

"description": "Request body could not be parsed."

}

Suggest where I'm going wrong :) Thanks in advance.