Skip to content

Instantly share code, notes, and snippets.

@athiththan11
Created September 1, 2019 06:14
Show Gist options
  • Save athiththan11/96ef52ab35dea69562119183cd2d3bda to your computer and use it in GitHub Desktop.
Save athiththan11/96ef52ab35dea69562119183cd2d3bda to your computer and use it in GitHub Desktop.
EI CURL Commands for WSO2 Trilogy Medium
@hostname = https://localhost:8243/dev-management
@username = athiththan11
### Get Developer
# @name getDeveloper
curl -k -X GET {{hostname}}/devs/{{username}} \
-H "Content-Type: application/json"
### Get Repos of a Developer
# @name getRepos
curl -k -X GET {{hostname}}/devs/{{username}}/repos \
-H "Content-Type: application/json"
### Delete a Developer
# @name deleteDeveloper
curl -k -X DELETE {{hostname}}/devs/{{username}} \
-H "Content-Type: application/json"
### Create a Developer
# @name addDeveloper
curl -k -X POST {{hostname}}/devs \
-d '{ "username": "athiththan11", "name": "Athiththan", "email": "athiththan11@test.com" }' \
-H "Content-Type: application/json"
### Create a Repo
# @name addRepo
curl -k -X POST {{hostname}}/repos \
-d '{ "name": "repodews", "username": "athiththan11", "forks": 0 }' \
-H "Content-Type: application/json"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment