Ask Your Question
0

Quantum API's using curl

asked 2013-12-24 04:04:17 -0500

RHK gravatar image

updated 2013-12-24 08:45:20 -0500

larsks gravatar image

I am trying to update the network name using curl,

curl -s http://10.0.1.3:9696/v2/networks/network_id -X PUT -H "X-Auth-Project-Id: kaveri" -H "Accept: application/json" -H "X-Auth-Token: $token_id" -d '<network name="test_network"/>' | python -mjson.tool 

Extra data: line 1 column 4 - line 5 column 4 (char 4 - 52)

How to fix this issue. If i want to create, update, delete (networks, subnets, ports) using curl what was the process? Was there any document?

edit retag flag offensive close merge delete

1 answer

Sort by ยป oldest newest most voted
2

answered 2013-12-24 08:46:18 -0500

larsks gravatar image

Remove the pipe to `python -mjson.tool`. What does the actual output from `curl` look like? I suspect you're getting an error rather than a JSON response and this is why `json.tool` is producing an error message.

edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Get to know Ask OpenStack

Resources for moderators

Question Tools

1 follower

Stats

Asked: 2013-12-24 04:04:17 -0500

Seen: 144 times

Last updated: Dec 24 '13