fix alias folder ordering and request bodies in Postman collection
This commit is contained in:
@@ -3844,6 +3844,43 @@
|
|||||||
}
|
}
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"name": "Create Customer - admin 201",
|
||||||
|
"request": {
|
||||||
|
"method": "POST",
|
||||||
|
"url": "{{baseUrl}}/api/v1/customers",
|
||||||
|
"header": [
|
||||||
|
{
|
||||||
|
"key": "Content-Type",
|
||||||
|
"value": "application/json"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"key": "Authorization",
|
||||||
|
"value": "Bearer {{adminToken}}",
|
||||||
|
"type": "text"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"body": {
|
||||||
|
"mode": "raw",
|
||||||
|
"raw": "{\n \"firstName\": \"Alias\",\n \"lastName\": \"Customer\",\n \"fullName\": \"Alias Customer\",\n \"email\": \"alias.customer.{{}}@example.com\",\n \"phone\": \"555-200-3000\",\n \"role\": \"CUSTOMER\",\n \"active\": true\n}"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"event": [
|
||||||
|
{
|
||||||
|
"listen": "test",
|
||||||
|
"script": {
|
||||||
|
"type": "text/javascript",
|
||||||
|
"exec": [
|
||||||
|
"pm.test('Status code is 201', function () {",
|
||||||
|
" pm.response.to.have.status(201);",
|
||||||
|
"});",
|
||||||
|
"var jsonData = pm.response.json();",
|
||||||
|
"if (jsonData.id !== undefined) pm.collectionVariables.set('customerId', jsonData.id);"
|
||||||
|
]
|
||||||
|
}
|
||||||
|
}
|
||||||
|
]
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"name": "Get Customer - staff 200",
|
"name": "Get Customer - staff 200",
|
||||||
"request": {
|
"request": {
|
||||||
@@ -3906,41 +3943,6 @@
|
|||||||
}
|
}
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
{
|
|
||||||
"name": "Create Customer - admin 201",
|
|
||||||
"request": {
|
|
||||||
"method": "POST",
|
|
||||||
"url": "{{baseUrl}}/api/v1/customers",
|
|
||||||
"header": [
|
|
||||||
{
|
|
||||||
"key": "Content-Type",
|
|
||||||
"value": "application/json"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"key": "Authorization",
|
|
||||||
"value": "Bearer {{adminToken}}",
|
|
||||||
"type": "text"
|
|
||||||
}
|
|
||||||
],
|
|
||||||
"body": {
|
|
||||||
"mode": "raw",
|
|
||||||
"raw": "{\n \"firstName\": \"Alias\",\n \"lastName\": \"Customer\",\n \"email\": \"alias.cust@example.com\",\n \"password\": \"Test1234!\",\n \"role\": \"CUSTOMER\"\n}"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"event": [
|
|
||||||
{
|
|
||||||
"listen": "test",
|
|
||||||
"script": {
|
|
||||||
"type": "text/javascript",
|
|
||||||
"exec": [
|
|
||||||
"pm.test('Status code is 201', function () {",
|
|
||||||
" pm.response.to.have.status(201);",
|
|
||||||
"});"
|
|
||||||
]
|
|
||||||
}
|
|
||||||
}
|
|
||||||
]
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"name": "Update Customer - admin 200",
|
"name": "Update Customer - admin 200",
|
||||||
"request": {
|
"request": {
|
||||||
@@ -3959,7 +3961,7 @@
|
|||||||
],
|
],
|
||||||
"body": {
|
"body": {
|
||||||
"mode": "raw",
|
"mode": "raw",
|
||||||
"raw": "{\n \"firstName\": \"AliasUpdated\"\n}"
|
"raw": "{\n \"firstName\": \"Alias\",\n \"lastName\": \"CustomerUpdated\",\n \"fullName\": \"Alias CustomerUpdated\",\n \"email\": \"alias.customer.updated.{{}}@example.com\",\n \"phone\": \"555-200-3001\",\n \"role\": \"CUSTOMER\",\n \"active\": true\n}"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"event": [
|
"event": [
|
||||||
@@ -4621,6 +4623,43 @@
|
|||||||
}
|
}
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"name": "Create Employee - admin 201",
|
||||||
|
"request": {
|
||||||
|
"method": "POST",
|
||||||
|
"url": "{{baseUrl}}/api/v1/employees",
|
||||||
|
"header": [
|
||||||
|
{
|
||||||
|
"key": "Content-Type",
|
||||||
|
"value": "application/json"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"key": "Authorization",
|
||||||
|
"value": "Bearer {{adminToken}}",
|
||||||
|
"type": "text"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"body": {
|
||||||
|
"mode": "raw",
|
||||||
|
"raw": "{\n \"username\": \"aliasemployee{{}}\",\n \"password\": \"Test1234!\",\n \"firstName\": \"Alias\",\n \"lastName\": \"Employee\",\n \"fullName\": \"Alias Employee\",\n \"email\": \"alias.employee.{{}}@petshop.com\",\n \"phone\": \"403-555-0300\",\n \"role\": \"STAFF\",\n \"staffRole\": \"GROOMER\",\n \"primaryStoreId\": 1,\n \"active\": true\n}"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"event": [
|
||||||
|
{
|
||||||
|
"listen": "test",
|
||||||
|
"script": {
|
||||||
|
"type": "text/javascript",
|
||||||
|
"exec": [
|
||||||
|
"pm.test('Status code is 201', function () {",
|
||||||
|
" pm.response.to.have.status(201);",
|
||||||
|
"});",
|
||||||
|
"var jsonData = pm.response.json();",
|
||||||
|
"if (jsonData.id !== undefined) pm.collectionVariables.set('employeeId', jsonData.id);"
|
||||||
|
]
|
||||||
|
}
|
||||||
|
}
|
||||||
|
]
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"name": "Get Employee - admin 200",
|
"name": "Get Employee - admin 200",
|
||||||
"request": {
|
"request": {
|
||||||
@@ -4652,41 +4691,6 @@
|
|||||||
}
|
}
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
{
|
|
||||||
"name": "Create Employee - admin 201",
|
|
||||||
"request": {
|
|
||||||
"method": "POST",
|
|
||||||
"url": "{{baseUrl}}/api/v1/employees",
|
|
||||||
"header": [
|
|
||||||
{
|
|
||||||
"key": "Content-Type",
|
|
||||||
"value": "application/json"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"key": "Authorization",
|
|
||||||
"value": "Bearer {{adminToken}}",
|
|
||||||
"type": "text"
|
|
||||||
}
|
|
||||||
],
|
|
||||||
"body": {
|
|
||||||
"mode": "raw",
|
|
||||||
"raw": "{\n \"firstName\": \"Alias\",\n \"lastName\": \"Employee\",\n \"email\": \"alias.staff@example.com\",\n \"password\": \"Test1234!\",\n \"role\": \"STAFF\"\n}"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"event": [
|
|
||||||
{
|
|
||||||
"listen": "test",
|
|
||||||
"script": {
|
|
||||||
"type": "text/javascript",
|
|
||||||
"exec": [
|
|
||||||
"pm.test('Status code is 201', function () {",
|
|
||||||
" pm.response.to.have.status(201);",
|
|
||||||
"});"
|
|
||||||
]
|
|
||||||
}
|
|
||||||
}
|
|
||||||
]
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"name": "Update Employee - admin 200",
|
"name": "Update Employee - admin 200",
|
||||||
"request": {
|
"request": {
|
||||||
@@ -4705,7 +4709,7 @@
|
|||||||
],
|
],
|
||||||
"body": {
|
"body": {
|
||||||
"mode": "raw",
|
"mode": "raw",
|
||||||
"raw": "{\n \"firstName\": \"AliasUpdated\"\n}"
|
"raw": "{\n \"firstName\": \"Alias\",\n \"lastName\": \"EmployeeUpdated\",\n \"fullName\": \"Alias EmployeeUpdated\",\n \"email\": \"alias.employee.updated.{{}}@petshop.com\",\n \"phone\": \"403-555-0301\",\n \"role\": \"STAFF\",\n \"staffRole\": \"VET\",\n \"primaryStoreId\": 1,\n \"active\": true\n}"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"event": [
|
"event": [
|
||||||
|
|||||||
Reference in New Issue
Block a user