Commit 3cd736cb by zhangjingdong

修改postman导出脚本的版本

parent dd9f3656
No preview for this file type
No preview for this file type
{
{
......@@ -16,13 +16,7 @@
},
{
"key": "access-Token",
"value": "3858fd852d0c4c5594cda2bdaeb81fa2",
"enabled": true,
"type": "text"
},
{
"key": "refreshToken",
"value": "ae13c8566980480eb465b50de490cbb9",
"value": "be4c6160f25c4085b6c4c61fa7803a7a",
"enabled": true,
"type": "text"
},
......@@ -34,6 +28,6 @@
}
],
"_postman_variable_scope": "environment",
"_postman_exported_at": "2018-11-21T01:46:31.227Z",
"_postman_exported_at": "2018-11-27T03:29:41.309Z",
"_postman_exported_using": "Postman/6.1.4"
}
\ No newline at end of file
{
{
{
"id": "a02d4b69-e0ad-4bd2-b06b-0d83e9ea1035",
"name": "活动",
"description": null,
"auth": null,
"events": null,
"variables": null,
"order": [
"62246627-c76c-4e83-99c5-eae45302f950",
"f59a8d39-c737-4eff-88ab-d6e620cfd980",
"e182c84d-8ec1-417e-af6b-486d78786781",
"430603ba-54a4-4c7b-9a11-a9af5156dfc3",
"9e0a4a32-f71a-4265-8665-59eb1600627b",
"a8d0d72d-6481-4571-a4f0-0e81faa20b1a",
"580a1db9-448e-452b-8588-fdae50dcc960",
"dd4da32a-1895-4c26-9b33-1a1d3d8bc54e",
"851d8cc6-4609-490a-b7ba-e3400244b043"
],
"folders_order": [],
"folders": [],
"requests": [
"info": {
"_postman_id": "a02d4b69-e0ad-4bd2-b06b-0d83e9ea1035",
"name": "活动",
"schema": "https://schema.getpostman.com/json/collection/v2.0.0/collection.json"
},
"item": [
{
"id": "430603ba-54a4-4c7b-9a11-a9af5156dfc3",
"name": "app用户活动报名",
"url": "{{gateway-user}}/app/new/activity/enroll\n",
"description": "",
"data": [],
"dataMode": "raw",
"headerData": [
{
"key": "access-Token",
"value": "{{access-Token}}",
"description": "",
"enabled": true
},
{
"key": "Content-Type",
"value": "application/json"
}
],
"method": "POST",
"pathVariableData": [],
"queryParams": [],
"auth": null,
"events": [
"name": "用户登录",
"event": [
{
"listen": "test",
"script": {
"id": "f008e296-82a3-4d20-a473-7c2827a257eb",
"id": "a9c52209-1773-48db-86df-106c6ee71da4",
"type": "text/javascript",
"exec": [
"// console.log(\"----------------responseBody--------------\"+responseBody);",
"var jsonData = JSON.parse(responseBody);",
"if(jsonData.code === \"0\")",
"// console.log(\"----------------jsonData.data.accessToken--------------\"+jsonData.data.accessToken);",
"",
"if(jsonData.data !== null || jsonData.data !==\"\")",
"{",
" tests[\"code\"] = true;",
" tests[\"accessToken\"] = true;",
" postman.setEnvironmentVariable(\"access-Token\",jsonData.data.accessToken);",
" ",
"}",
"else{",
"else",
"{",
" console.log(\"接口返回错误:\"+jsonData.msg);",
" tests[\"code\"]=false;",
" tests[\"accessToken\"]=false;",
"}",
""
]
}
},
{
"listen": "prerequest",
"script": {
"id": "b4215bcf-fbff-4e3d-9f19-538d7af903ee",
"type": "text/javascript",
"exec": [
""
]
}
}
],
"folder": null,
"rawModeData": "{\n \"activityId\":196,\n \"enrollStatus\": \"CONFIRM\",\n\n \"townId\": 1\n}",
"headers": "access-Token: {{access-Token}}\nContent-Type: application/json\n",
"pathVariables": {}
"request": {
"method": "POST",
"header": [
{
"key": "Content-Type",
"value": "application/json"
}
],
"body": {
"mode": "raw",
"raw": "{\n \"userPhone\": {{user_phone}},\n \"userPassword\": \"123456\",\n \"equipment\": \"c5d93c486a95d658\",\n \"channelId\": 1\n}"
},
"url": "{{gateway-user}}/app/login"
},
"response": []
},
{
"id": "580a1db9-448e-452b-8588-fdae50dcc960",
"name": "app端获取活动详情",
"url": "{{gateway-user}}/app/new/activity/get/comment/info/{{activityId}}",
"description": "",
"data": null,
"dataMode": "params",
"headerData": [
{
"key": "access-Token",
"value": "{{access-Token}}",
"description": "",
"enabled": true
}
],
"method": "GET",
"pathVariableData": [],
"queryParams": [],
"auth": null,
"events": [
"name": "app根据小镇获取活动列表",
"event": [
{
"listen": "test",
"script": {
"id": "2fd3ff6b-1da2-4b16-bf00-480169689fe1",
"id": "3c9905dc-9e88-48dc-81d6-52361e995629",
"type": "text/javascript",
"exec": [
"var jsonData = JSON.parse(responseBody);",
......@@ -108,93 +83,96 @@
}
}
],
"folder": null,
"headers": "access-Token: {{access-Token}}\n",
"pathVariables": {}
"request": {
"method": "POST",
"header": [
{
"key": "access-token",
"value": "{{access-Token}}"
},
{
"key": "Content-Type",
"value": "application/json"
}
],
"body": {
"mode": "raw",
"raw": "{\n \"blockType\": \"ENTERPRISE\",\n \"townId\": 1\n}"
},
"url": "{{gateway-user}}/app/activity/town/user"
},
"response": []
},
{
"id": "62246627-c76c-4e83-99c5-eae45302f950",
"name": "用户登录",
"url": "{{gateway-user}}/app/login",
"description": null,
"data": [],
"dataMode": "raw",
"headerData": [
{
"key": "Content-Type",
"value": "application/json"
}
],
"method": "POST",
"pathVariableData": [],
"queryParams": [],
"auth": null,
"events": [
"name": "app获取某用户报名活动列表",
"event": [
{
"listen": "test",
"script": {
"id": "a9c52209-1773-48db-86df-106c6ee71da4",
"id": "74323a15-c4af-40e0-8e6e-1bd188b95239",
"type": "text/javascript",
"exec": [
"// console.log(\"----------------responseBody--------------\"+responseBody);",
"var jsonData = JSON.parse(responseBody);",
"// console.log(\"----------------jsonData.data.accessToken--------------\"+jsonData.data.accessToken);",
"",
"if(jsonData.data !== null || jsonData.data !==\"\")",
"if(jsonData.code === \"0\")",
"{",
" tests[\"accessToken\"] = true;",
" postman.setEnvironmentVariable(\"access-Token\",jsonData.data.accessToken);",
" ",
" tests[\"code\"] = true;",
"}",
"else",
"{",
"else{",
" console.log(\"接口返回错误:\"+jsonData.msg);",
" tests[\"accessToken\"]=false;",
" tests[\"code\"]=false;",
"}",
""
]
}
},
{
"listen": "prerequest",
"script": {
"id": "b4215bcf-fbff-4e3d-9f19-538d7af903ee",
"type": "text/javascript",
"exec": [
""
]
}
}
],
"folder": null,
"rawModeData": "{\n \"userPhone\": {{user_phone}},\n \"userPassword\": \"123456\",\n \"equipment\": \"c5d93c486a95d658\",\n \"channelId\": 1\n}",
"headers": "Content-Type: application/json\n",
"pathVariables": {}
"request": {
"method": "POST",
"header": [
{
"key": "access-token",
"value": "{{access-Token}}"
},
{
"key": "Content-Type",
"value": "application/json"
}
],
"body": {
"mode": "raw",
"raw": "{\n \"blockType\": \"ENTERPRISE\"\n}"
},
"url": {
"raw": "{{gateway-user}}/app/activity/user?p=1&c=2",
"host": [
"{{gateway-user}}"
],
"path": [
"app",
"activity",
"user"
],
"query": [
{
"key": "p",
"value": "1"
},
{
"key": "c",
"value": "2"
}
]
}
},
"response": []
},
{
"id": "851d8cc6-4609-490a-b7ba-e3400244b043",
"name": "获取置顶活动",
"url": "{{gateway-user}}/app/new/activity/get/top/one/1/ENTERPRISE",
"description": "",
"data": null,
"dataMode": "params",
"headerData": [
{
"key": "access-Token",
"value": "{{access-Token}}",
"description": "",
"enabled": true
}
],
"method": "GET",
"pathVariableData": [],
"queryParams": [],
"auth": null,
"events": [
"name": "app用户活动报名",
"event": [
{
"listen": "test",
"script": {
"id": "bb090dcf-2104-4a22-8b39-b8220af62c9a",
"id": "f008e296-82a3-4d20-a473-7c2827a257eb",
"type": "text/javascript",
"exec": [
"var jsonData = JSON.parse(responseBody);",
......@@ -211,34 +189,29 @@
}
}
],
"folder": null,
"headers": "access-Token: {{access-Token}}\n",
"pathVariables": {}
"request": {
"method": "POST",
"header": [
{
"key": "access-Token",
"value": "{{access-Token}}"
},
{
"key": "Content-Type",
"value": "application/json"
}
],
"body": {
"mode": "raw",
"raw": "{\n \"activityId\":196,\n \"enrollStatus\": \"CONFIRM\",\n\n \"townId\": 1\n}"
},
"url": "{{gateway-user}}/app/new/activity/enroll"
},
"response": []
},
{
"id": "9e0a4a32-f71a-4265-8665-59eb1600627b",
"name": "app活动评论",
"url": "{{gateway-user}}/app/new/activity/comment",
"description": "",
"data": [],
"dataMode": "raw",
"headerData": [
{
"key": "access-Token",
"value": "{{access-Token}}",
"description": "",
"enabled": true
},
{
"key": "Content-Type",
"value": "application/json"
}
],
"method": "POST",
"pathVariableData": [],
"queryParams": [],
"auth": null,
"events": [
"event": [
{
"listen": "test",
"script": {
......@@ -259,24 +232,29 @@
}
}
],
"folder": null,
"rawModeData": "{\n \"activityId\": {{activityId}},\n \"commentType\": \"ACTIVITY\",\n \"commentStatus\": \"COMMENT\",\n \"comment\": \"hahhaahhahahahahahahh\",\n \"commentImg\": [\n \"string\"\n ]\n}",
"headers": "access-Token: {{access-Token}}\nContent-Type: application/json\n",
"pathVariables": {}
"request": {
"method": "POST",
"header": [
{
"key": "access-Token",
"value": "{{access-Token}}"
},
{
"key": "Content-Type",
"value": "application/json"
}
],
"body": {
"mode": "raw",
"raw": "{\n \"activityId\": {{activityId}},\n \"commentType\": \"ACTIVITY\",\n \"commentStatus\": \"COMMENT\",\n \"comment\": \"hahhaahhahahahahahahh\",\n \"commentImg\": [\n \"string\"\n ]\n}"
},
"url": "{{gateway-user}}/app/new/activity/comment"
},
"response": []
},
{
"id": "a8d0d72d-6481-4571-a4f0-0e81faa20b1a",
"name": "app二维码获取活动详情",
"url": "{{gateway-user}}/app/new/activity/get/code/info/{{activityId}}",
"description": "",
"data": null,
"dataMode": "params",
"headerData": [],
"method": "GET",
"pathVariableData": [],
"queryParams": [],
"auth": null,
"events": [
"event": [
{
"listen": "test",
"script": {
......@@ -297,34 +275,21 @@
}
}
],
"folder": null,
"headers": "",
"pathVariables": {}
"request": {
"method": "GET",
"header": [],
"body": {},
"url": "{{gateway-user}}/app/new/activity/get/code/info/{{activityId}}"
},
"response": []
},
{
"id": "dd4da32a-1895-4c26-9b33-1a1d3d8bc54e",
"name": "app获取某一个活动详情",
"url": "{{gateway-user}}/app/activity/{{activityId}}",
"description": "",
"data": null,
"dataMode": "params",
"headerData": [
{
"key": "access-token",
"value": "{{access-Token}}",
"description": "",
"enabled": true
}
],
"method": "GET",
"pathVariableData": [],
"queryParams": [],
"auth": null,
"events": [
"name": "app端获取活动详情",
"event": [
{
"listen": "test",
"script": {
"id": "93f6cff3-ef65-40e9-ba2b-716185de2860",
"id": "2fd3ff6b-1da2-4b16-bf00-480169689fe1",
"type": "text/javascript",
"exec": [
"var jsonData = JSON.parse(responseBody);",
......@@ -341,53 +306,26 @@
}
}
],
"folder": null,
"headers": "access-token: {{access-Token}}\n",
"pathVariables": {}
"request": {
"method": "GET",
"header": [
{
"key": "access-Token",
"value": "{{access-Token}}"
}
],
"body": {},
"url": "{{gateway-user}}/app/new/activity/get/comment/info/{{activityId}}"
},
"response": []
},
{
"id": "e182c84d-8ec1-417e-af6b-486d78786781",
"name": "app获取某用户报名活动列表",
"url": "{{gateway-user}}/app/activity/user?p=1&c=2",
"description": "",
"data": [],
"dataMode": "raw",
"headerData": [
{
"key": "access-token",
"value": "{{access-Token}}",
"description": "",
"enabled": true
},
{
"key": "Content-Type",
"value": "application/json"
}
],
"method": "POST",
"pathVariableData": [],
"queryParams": [
{
"key": "p",
"value": "1",
"equals": true,
"description": "",
"enabled": true
},
{
"key": "c",
"value": "2",
"equals": true,
"description": "",
"enabled": true
}
],
"auth": null,
"events": [
"name": "app获取某一个活动详情",
"event": [
{
"listen": "test",
"script": {
"id": "74323a15-c4af-40e0-8e6e-1bd188b95239",
"id": "93f6cff3-ef65-40e9-ba2b-716185de2860",
"type": "text/javascript",
"exec": [
"var jsonData = JSON.parse(responseBody);",
......@@ -404,39 +342,26 @@
}
}
],
"folder": null,
"rawModeData": "{\n \"blockType\": \"ENTERPRISE\"\n}",
"headers": "access-token: {{access-Token}}\nContent-Type: application/json\n",
"pathVariables": {}
"request": {
"method": "GET",
"header": [
{
"key": "access-token",
"value": "{{access-Token}}"
}
],
"body": {},
"url": "{{gateway-user}}/app/activity/{{activityId}}"
},
"response": []
},
{
"id": "f59a8d39-c737-4eff-88ab-d6e620cfd980",
"name": "app根据小镇获取活动列表",
"url": "{{gateway-user}}/app/activity/town/user",
"description": "",
"data": [],
"dataMode": "raw",
"headerData": [
{
"key": "access-token",
"value": "{{access-Token}}",
"description": "",
"enabled": true
},
{
"key": "Content-Type",
"value": "application/json"
}
],
"method": "POST",
"pathVariableData": [],
"queryParams": [],
"auth": null,
"events": [
"name": "获取置顶活动",
"event": [
{
"listen": "test",
"script": {
"id": "3c9905dc-9e88-48dc-81d6-52361e995629",
"id": "bb090dcf-2104-4a22-8b39-b8220af62c9a",
"type": "text/javascript",
"exec": [
"var jsonData = JSON.parse(responseBody);",
......@@ -453,10 +378,18 @@
}
}
],
"folder": null,
"rawModeData": "{\n \"blockType\": \"ENTERPRISE\",\n \"townId\": 1\n}",
"headers": "access-token: {{access-Token}}\nContent-Type: application/json\n",
"pathVariables": {}
"request": {
"method": "GET",
"header": [
{
"key": "access-Token",
"value": "{{access-Token}}"
}
],
"body": {},
"url": "{{gateway-user}}/app/new/activity/get/top/one/1/ENTERPRISE"
},
"response": []
}
]
}
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment