-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
added postman collection for application api testing and demo
- Loading branch information
1 parent
3a988c1
commit a0f5e79
Showing
1 changed file
with
99 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,99 @@ | ||
{ | ||
"info": { | ||
"_postman_id": "9470b311-46f1-47b7-aa30-1bec07890777", | ||
"name": "TC for Java", | ||
"schema": "https://schema.getpostman.com/json/collection/v2.1.0/collection.json" | ||
}, | ||
"item": [ | ||
{ | ||
"name": "Create a product", | ||
"request": { | ||
"method": "POST", | ||
"header": [ | ||
{ | ||
"key": "Content-Type", | ||
"value": "application/json", | ||
"type": "text" | ||
} | ||
], | ||
"body": { | ||
"mode": "raw", | ||
"raw": "{\n\"code\": \"P201\",\n\"name\": \"Product P201\",\n\"description\": \"Product P201 description\",\n\"price\": 24.0\n}", | ||
"options": { | ||
"raw": {} | ||
} | ||
}, | ||
"url": { | ||
"raw": "http://localhost:8080/api/products", | ||
"protocol": "http", | ||
"host": [ | ||
"localhost" | ||
], | ||
"port": "8080", | ||
"path": [ | ||
"api", | ||
"products" | ||
] | ||
} | ||
}, | ||
"response": [] | ||
}, | ||
{ | ||
"name": "Upload Product Image", | ||
"request": { | ||
"method": "POST", | ||
"header": [], | ||
"body": { | ||
"mode": "formdata", | ||
"formdata": [ | ||
{ | ||
"key": "file", | ||
"type": "file", | ||
"src": "/Users/user/image.png" | ||
} | ||
], | ||
"options": { | ||
"formdata": {} | ||
} | ||
}, | ||
"url": { | ||
"raw": "http://localhost:8080/api/products/P101/image", | ||
"protocol": "http", | ||
"host": [ | ||
"localhost" | ||
], | ||
"port": "8080", | ||
"path": [ | ||
"api", | ||
"products", | ||
"P101", | ||
"image" | ||
] | ||
} | ||
}, | ||
"response": [] | ||
}, | ||
{ | ||
"name": "Get a product by code", | ||
"request": { | ||
"method": "GET", | ||
"header": [], | ||
"url": { | ||
"raw": "http://localhost:8080/api/products/P201", | ||
"protocol": "http", | ||
"host": [ | ||
"localhost" | ||
], | ||
"port": "8080", | ||
"path": [ | ||
"api", | ||
"products", | ||
"P201" | ||
] | ||
} | ||
}, | ||
"response": [] | ||
} | ||
], | ||
"protocolProfileBehavior": {} | ||
} |