Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
save out json to files.
// chomd +x dumpSwaggerJson.sh
curl -X GET https://virtserver.swaggerhub.com/osman/emerald/1.0.0/channels -H "access-control-allow-origin: *" -H "accept: application/json" -H "content-type: application/json" > channels.json
curl -X GET https://virtserver.swaggerhub.com/osman/emerald/1.0.0/channels/channelContent?channelid=1092 -H "access-control-allow-origin: *" -H "accept: application/json" -H "content-type: application/json" > channel1092.json
curl -X GET https://virtserver.swaggerhub.com/osman/emerald/1.0.0/channels/channelContent?channelid=1701 -H "access-control-allow-origin: *" -H "accept: application/json" -H "content-type: application/json" > channel1701.json
curl -X GET https://virtserver.swaggerhub.com/osman/emerald/1.0.0/channels/channelContent?channelid=1408 -H "access-control-allow-origin: *" -H "accept: application/json" -H "content-type: application/json" > channel1408.json
curl -X GET https://virtserver.swaggerhub.com/osman/emerald/1.0.0/channels/channelContent?channelid=1078 -H "access-control-allow-origin: *" -H "accept: application/json" -H "content-type: application/json" > channel1078.json
curl -X GET https://virtserver.swaggerhub.com/osman/emerald/1.0.0/channels/channelContent?channelid=1155 -H "access-control-allow-origin: *" -H "accept: application/json" -H "content-type: application/json" > channel1155.json
curl -X GET https://virtserver.swaggerhub.com/osman/emerald/1.0.0/video/associatedContent?video_id=1180 -H "access-control-allow-origin: *" -H "accept: application/json" -H "content-type: application/json" > associatedContent1105.json
//shows
curl -X GET https://virtserver.swaggerhub.com/osman/emerald/1.0.0/shows -H "access-control-allow-origin: *" -H "accept: application/json" -H "content-type: application/json" > shows.json
// shows/related
curl -X GET https://virtserver.swaggerhub.com/osman/emerald/1.0.0/shows/related?show_id=1111 -H "access-control-allow-origin: *" -H "accept: application/json" -H "content-type: application/json" > relatedShows1111.json
// superstars/related
curl -X GET https://virtserver.swaggerhub.com/osman/emerald/1.0.0/superstars/related?superstar_id=1 -H "access-control-allow-origin: *" -H "accept: application/json" -H "content-type: application/json" > superstars1.json
@wwe-johndpope

This comment has been minimized.

Copy link
Owner Author

commented Apr 5, 2017

Beware of filesize ~ 0kb / rate limit imposed

screen shot 2017-04-05 at 3 40 26 pm

@wwe-johndpope

This comment has been minimized.

Copy link
Owner Author

commented Apr 5, 2017

from swagger - we can inspect the curl here
just add to above script.

screen shot 2017-04-05 at 3 42 35 pm

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.