4 "name": "06_Onboard_Service",
5 "_postman_id": "52d092e4-3896-404a-0ebd-e0bef781492e",
7 "schema": "https://schema.getpostman.com/json/collection/v2.0.0/collection.json"
11 "name": "check service exists and get infos",
16 "type": "text/javascript",
18 "tests[\"Status code is 200\"] = responseCode.code === 200;",
20 "var jsonData = JSON.parse(responseBody);",
21 "var service_found = false;",
22 "for (var i = 0; i < jsonData.length; i++) { ",
23 " if (jsonData[i].name === postman.getGlobalVariable(\"service\")) {",
24 " service_found = true;",
25 " postman.setGlobalVariable(\"auto_service_uuid\", \"\"+jsonData[i].uuid+\"\");",
26 " postman.setGlobalVariable(\"auto_service_invariant_uuid\", \"\"+jsonData[i].invariantUUID+\"\");",
29 "if (service_found === false) {",
30 " tests[postman.getGlobalVariable(\"service\")+\" does not exists, we continue the run\"] = true;",
34 " tests[postman.getGlobalVariable(\"service\")+\" already exists, stop the run\"] = true;",
35 " postman.setNextRequest(null);",
42 "url": "{{url-sdc}}/sdc/v1/catalog/services",
46 "key": "Content-Type",
47 "value": "application/json",
52 "value": "application/json",
56 "key": "X-TransactionId",
71 "key": "Authorization",
72 "value": "Basic YWFpOktwOGJKNFNYc3pNMFdYbGhhazNlSGxjc2UyZ0F3ODR2YW9HR21KdlV5MlU=",
76 "key": "x-ecomp-instanceid",
83 "raw": "{\"contactId\": \"cs0008\", \"vendorRelease\": \"1.0\", \"requirements\": {}, \"artifacts\": {}, \"capabilities\": {}, \"componentInstancesProperties\": {}, \"deploymentArtifacts\": {}, \"icon\": \"defaulticon\", \"vendorName\": \"test-api-license-model\", \"description\": \"vendor software product\", \"tags\": [\"test-vsp\"], \"groups\": [], \"properties\": [], \"categories\": [{\"subcategories\": [{\"normalizedName\": \"abstract\", \"name\": \"Abstract\", \"uniqueId\": \"resourceNewCategory.generic.abstract\", \"icons\": [\"icon\"]}], \"normalizedName\": \"generic\", \"name\": \"Generic\", \"uniqueId\": \"resourceNewCategory.generic\"}], \"name\": \"test-vsp\", \"toscaArtifacts\": {}, \"csarUUID\": \"F3CD5189C2DF45B4B1CFA6D6E45FD613\", \"resourceType\": \"VF\", \"csarVersion\": \"1.0\", \"componentType\": \"RESOURCE\", \"componentInstancesAttributes\": {}, \"attributes\": [], \"componentInstances\": []}"
90 "name": "Create a aLaCarte Service",
95 "type": "text/javascript",
97 "tests[\"Status code is 201\"] = responseCode.code === 201;",
99 "var jsonData = JSON.parse(responseBody);",
100 "postman.setGlobalVariable(\"auto_service_invariant_uuid\", \"\"+jsonData[\"invariantUUID\"]+\"\");",
101 "postman.setGlobalVariable(\"auto_service_uuid\", \"\"+jsonData[\"uuid\"]+\"\");",
102 "postman.setGlobalVariable(\"auto_service_unique_id\", \"\"+jsonData[\"uniqueId\"]+\"\");",
104 "tests[\"Service version is in NOT_CERTIFIED_CHECKOUT status\"] = jsonData[\"lifecycleState\"] === \"NOT_CERTIFIED_CHECKOUT\";"
110 "url": "{{url-sdc2}}/sdc1/feProxy/rest/v1/catalog/services",
114 "key": "Content-Type",
115 "value": "application/json",
120 "value": "application/json",
124 "key": "X-TransactionId",
125 "value": "ONAP-Test",
134 "key": "X-FromAppId",
135 "value": "ONAP-Test",
139 "key": "Authorization",
140 "value": "Basic YWFpOktwOGJKNFNYc3pNMFdYbGhhazNlSGxjc2UyZ0F3ODR2YW9HR21KdlV5MlU=",
144 "key": "x-ecomp-instanceid",
145 "value": "ONAP-Test",
151 "raw": "{\r\n\t\"artifacts\": {},\r\n\t\"toscaArtifacts\": {},\r\n\t\"contactId\": \"cs0008\",\r\n\t\"categories\": [{\r\n\t\t\"name\": \"Network Service\",\r\n\t\t\"normalizedName\": \"network service\",\r\n\t\t\"uniqueId\": \"serviceNewCategory.network service\",\r\n\t\t\"icons\": [\"network_l_1-3\"],\r\n\t\t\"subcategories\": null,\r\n\t\t\"version\": null,\r\n\t\t\"ownerId\": null,\r\n\t\t\"empty\": false,\r\n\t\t\"type\": null\r\n\t}],\r\n\t\"description\": \"Service {{service}}\",\r\n\t\"icon\": \"defaulticon\",\r\n\t\"componentInstancesProperties\": {},\r\n\t\"componentInstancesAttributes\": {},\r\n\t\"name\": \"{{service}}\",\r\n\t\"tags\": [\"{{service}}\"],\r\n\t\"capabilities\": {},\r\n\t\"requirements\": {},\r\n\t\"deploymentArtifacts\": {},\r\n\t\"componentType\": \"SERVICE\",\r\n\t\"projectCode\": \"123456\",\r\n\t\"componentInstances\": [],\r\n\t\"properties\": [],\r\n\t\"attributes\": [],\r\n\t\"forwardingPaths\": {},\r\n\t\"ecompGeneratedNaming\": true,\r\n\t\"serviceApiArtifacts\": {},\r\n\t\"instantiationType\": \"A-la-carte\",\r\n\t\"environmentContext\": \"General_Revenue-Bearing\"\r\n}"
158 "name": "check VF exists and get uuid",
163 "type": "text/javascript",
165 "tests[\"Status code is 200\"] = responseCode.code === 200;",
167 "var jsonData = JSON.parse(responseBody);",
168 "var vf_found = false;",
169 "for (var i = 0; i < jsonData.length; i++) { ",
170 " if (jsonData[i][\"name\"] === postman.getGlobalVariable(\"vf_name\")) {",
172 " postman.setGlobalVariable(\"auto_vf_uuid\", \"\"+jsonData[i][\"uuid\"]+\"\");",
173 " postman.setGlobalVariable(\"auto_vf_invariant_uuid\", \"\"+jsonData[i][\"invariantUUID\"]+\"\");",
176 "if (vf_found === false) {",
177 " tests[postman.getGlobalVariable(\"vf_name\")+\" does not exists, we stop the run\"] = true;",
178 " postman.setNextRequest(null);",
183 " tests[postman.getGlobalVariable(\"vf_name\")+\" exists, we continue the run\"] = true;",
190 "url": "{{url-sdc}}/sdc/v1/catalog/resources/{{auto_vf_uuid}}/metadata",
194 "key": "Content-Type",
195 "value": "application/json",
200 "value": "application/json",
204 "key": "X-TransactionId",
205 "value": "ONAP-Test",
214 "key": "X-FromAppId",
215 "value": "ONAP-Test",
219 "key": "Authorization",
220 "value": "Basic YWFpOktwOGJKNFNYc3pNMFdYbGhhazNlSGxjc2UyZ0F3ODR2YW9HR21KdlV5MlU=",
224 "key": "x-ecomp-instanceid",
225 "value": "ONAP-Test",
231 "raw": "{\"contactId\": \"cs0008\", \"vendorRelease\": \"1.0\", \"requirements\": {}, \"artifacts\": {}, \"capabilities\": {}, \"componentInstancesProperties\": {}, \"deploymentArtifacts\": {}, \"icon\": \"defaulticon\", \"vendorName\": \"test-api-license-model\", \"description\": \"vendor software product\", \"tags\": [\"test-vsp\"], \"groups\": [], \"properties\": [], \"categories\": [{\"subcategories\": [{\"normalizedName\": \"abstract\", \"name\": \"Abstract\", \"uniqueId\": \"resourceNewCategory.generic.abstract\", \"icons\": [\"icon\"]}], \"normalizedName\": \"generic\", \"name\": \"Generic\", \"uniqueId\": \"resourceNewCategory.generic\"}], \"name\": \"test-vsp\", \"toscaArtifacts\": {}, \"csarUUID\": \"F3CD5189C2DF45B4B1CFA6D6E45FD613\", \"resourceType\": \"VF\", \"csarVersion\": \"1.0\", \"componentType\": \"RESOURCE\", \"componentInstancesAttributes\": {}, \"attributes\": [], \"componentInstances\": []}"
238 "name": "Get VF uniqueId",
243 "type": "text/javascript",
245 "tests[\"Status code is 200\"] = responseCode.code === 200;",
247 "var jsonData = JSON.parse(responseBody);",
248 "var vf_found = false;",
249 "for (var i = 0; i < jsonData.resources.length; i++) { ",
250 " if (jsonData.resources[i].name === postman.getGlobalVariable(\"vf_name\")) {",
252 " postman.setGlobalVariable(\"auto_vf_unique_id\", \"\"+jsonData.resources[i].uniqueId+\"\");",
262 "raw": "{{url-sdc2}}/sdc1/feProxy/rest/v1/screen?excludeTypes=VFCMT&excludeTypes=Configuration",
275 "key": "excludeTypes",
281 "key": "excludeTypes",
282 "value": "Configuration",
292 "key": "Content-Type",
293 "value": "application/json",
298 "value": "application/json",
302 "key": "X-TransactionId",
303 "value": "ONAP-Test",
312 "key": "X-FromAppId",
313 "value": "ONAP-Test",
317 "key": "Authorization",
318 "value": "Basic YWFpOktwOGJKNFNYc3pNMFdYbGhhazNlSGxjc2UyZ0F3ODR2YW9HR21KdlV5MlU=",
322 "key": "x-ecomp-instanceid",
323 "value": "ONAP-Test",
329 "raw": "{\"contactId\": \"cs0008\", \"vendorRelease\": \"1.0\", \"requirements\": {}, \"artifacts\": {}, \"capabilities\": {}, \"componentInstancesProperties\": {}, \"deploymentArtifacts\": {}, \"icon\": \"defaulticon\", \"vendorName\": \"test-api-license-model\", \"description\": \"vendor software product\", \"tags\": [\"test-vsp\"], \"groups\": [], \"properties\": [], \"categories\": [{\"subcategories\": [{\"normalizedName\": \"abstract\", \"name\": \"Abstract\", \"uniqueId\": \"resourceNewCategory.generic.abstract\", \"icons\": [\"icon\"]}], \"normalizedName\": \"generic\", \"name\": \"Generic\", \"uniqueId\": \"resourceNewCategory.generic\"}], \"name\": \"test-vsp\", \"toscaArtifacts\": {}, \"csarUUID\": \"F3CD5189C2DF45B4B1CFA6D6E45FD613\", \"resourceType\": \"VF\", \"csarVersion\": \"1.0\", \"componentType\": \"RESOURCE\", \"componentInstancesAttributes\": {}, \"attributes\": [], \"componentInstances\": []}"
336 "name": "Add VF to Service",
341 "type": "text/javascript",
343 "tests[\"Status code is 201\"] = responseCode.code === 201;"
349 "url": "{{url-sdc2}}/sdc1/feProxy/rest/v1/catalog/services/{{auto_service_unique_id}}/resourceInstance",
353 "key": "Content-Type",
354 "value": "application/json",
359 "value": "application/json",
363 "key": "X-TransactionId",
364 "value": "ONAP-Test",
373 "key": "X-FromAppId",
374 "value": "ONAP-Test",
378 "key": "Authorization",
379 "value": "Basic YWFpOktwOGJKNFNYc3pNMFdYbGhhazNlSGxjc2UyZ0F3ODR2YW9HR21KdlV5MlU=",
383 "key": "x-ecomp-instanceid",
384 "value": "ONAP-Test",
390 "raw": "{\r\n\t\"name\": \"{{vf_name}}\",\r\n\t\"componentVersion\": \"1.0\",\r\n\t\"posY\": 100,\r\n\t\"posX\": 200,\r\n\t\"uniqueId\": \"{{auto_vf_unique_id}}\",\r\n\t\"originType\": \"VF\",\r\n\t\"componentUid\": \"{{auto_vf_unique_id}}\",\r\n\t\"icon\": \"defaulticon\"\r\n}\r\n"
397 "name": "Submit for testing",
402 "type": "text/javascript",
404 "tests[\"Status code is 200\"] = responseCode.code === 200;"
410 "url": "{{url-sdc2}}/sdc1/feProxy/rest/v1/catalog/services/{{auto_service_unique_id}}/lifecycleState/certificationRequest",
414 "key": "Content-Type",
415 "value": "application/json",
420 "value": "application/json",
424 "key": "X-TransactionId",
425 "value": "ONAP-Test",
434 "key": "X-FromAppId",
435 "value": "ONAP-Test",
439 "key": "Authorization",
440 "value": "Basic YWFpOktwOGJKNFNYc3pNMFdYbGhhazNlSGxjc2UyZ0F3ODR2YW9HR21KdlV5MlU=",
444 "key": "x-ecomp-instanceid",
445 "value": "ONAP-Test",
451 "raw": "{\"userRemarks\":\"please test\"}"
458 "name": "Start Certification",
463 "type": "text/javascript",
465 "tests[\"Status code is 200\"] = responseCode.code === 200;"
471 "url": "{{url-sdc2}}/sdc1/feProxy/rest/v1/catalog/services/{{auto_service_unique_id}}/lifecycleState/startCertification",
475 "key": "Content-Type",
476 "value": "application/json",
481 "value": "application/json",
485 "key": "X-TransactionId",
486 "value": "ONAP-Test",
495 "key": "X-FromAppId",
496 "value": "ONAP-Test",
500 "key": "Authorization",
501 "value": "Basic YWFpOktwOGJKNFNYc3pNMFdYbGhhazNlSGxjc2UyZ0F3ODR2YW9HR21KdlV5MlU=",
505 "key": "x-ecomp-instanceid",
506 "value": "ONAP-Test",
524 "type": "text/javascript",
526 "tests[\"Status code is 200\"] = responseCode.code === 200;",
528 "var jsonData = JSON.parse(responseBody);",
529 "postman.setGlobalVariable(\"auto_service_new_unique_id\", \"\"+jsonData[\"uniqueId\"]+\"\");"
535 "url": "{{url-sdc2}}/sdc1/feProxy/rest/v1/catalog/services/{{auto_service_unique_id}}/lifecycleState/certify",
539 "key": "Content-Type",
540 "value": "application/json",
545 "value": "application/json",
549 "key": "X-TransactionId",
550 "value": "ONAP-Test",
559 "key": "X-FromAppId",
560 "value": "ONAP-Test",
564 "key": "Authorization",
565 "value": "Basic YWFpOktwOGJKNFNYc3pNMFdYbGhhazNlSGxjc2UyZ0F3ODR2YW9HR21KdlV5MlU=",
569 "key": "x-ecomp-instanceid",
570 "value": "ONAP-Test",
576 "raw": "{\"userRemarks\":\"ok\"}"
583 "name": "distribution approuve",
588 "type": "text/javascript",
590 "tests[\"Status code is 200\"] = responseCode.code === 200;"
596 "url": "{{url-sdc2}}/sdc1/feProxy/rest/v1/catalog/services/{{auto_service_new_unique_id}}/distribution-state/approve",
600 "key": "Content-Type",
601 "value": "application/json",
606 "value": "application/json",
610 "key": "X-TransactionId",
611 "value": "ONAP-Test",
620 "key": "X-FromAppId",
621 "value": "ONAP-Test",
625 "key": "Authorization",
626 "value": "Basic YWFpOktwOGJKNFNYc3pNMFdYbGhhazNlSGxjc2UyZ0F3ODR2YW9HR21KdlV5MlU=",
630 "key": "x-ecomp-instanceid",
631 "value": "ONAP-Test",
637 "raw": "{\"userRemarks\":\"ok\"}"
644 "name": "Distribute service",
649 "type": "text/javascript",
651 "tests[\"Status code is 200\"] = responseCode.code === 200;"
657 "url": "{{url-sdc2}}/sdc1/feProxy/rest/v1/catalog/services/{{auto_service_new_unique_id}}/distribution/PROD/activate",
661 "key": "Content-Type",
662 "value": "application/json",
667 "value": "application/json",
671 "key": "X-TransactionId",
672 "value": "ONAP-Test",
681 "key": "X-FromAppId",
682 "value": "ONAP-Test",
686 "key": "Authorization",
687 "value": "Basic YWFpOktwOGJKNFNYc3pNMFdYbGhhazNlSGxjc2UyZ0F3ODR2YW9HR21KdlV5MlU=",
691 "key": "x-ecomp-instanceid",
692 "value": "ONAP-Test",
705 "name": "check distribution",
710 "type": "text/javascript",
712 "tests[\"Status code is 200\"] = responseCode.code === 200;",
714 "var jsonData = JSON.parse(responseBody);",
715 "var distrib_done = false;",
716 "for (var i = 0; i < jsonData.distributionStatusOfServiceList.length; i++) { ",
717 " if (jsonData.distributionStatusOfServiceList[i].deployementStatus === \"Distributed\") {",
718 " distrib_done = true;",
719 " postman.setGlobalVariable(\"auto_distribution_id\", \"\"+jsonData.distributionStatusOfServiceList[i].distributionID+\"\");",
723 "if (distrib_done === false) {",
724 " tests[postman.getGlobalVariable(\"service\")+\" not distributed\"] = false;",
728 " tests[postman.getGlobalVariable(\"service\")+\" distributed\"] = true;",
729 " postman.setNextRequest(null);",
736 "url": "{{url-sdc2}}/sdc1/feProxy/rest/v1/catalog/services/{{auto_service_uuid}}/distribution",
740 "key": "Content-Type",
741 "value": "application/json",
746 "value": "application/json",
750 "key": "X-TransactionId",
751 "value": "ONAP-Test",
760 "key": "X-FromAppId",
761 "value": "ONAP-Test",
765 "key": "Authorization",
766 "value": "Basic YmVlcDpib29w",
770 "key": "x-ecomp-instanceid",
771 "value": "ONAP-Test",
784 "name": "check distribution fully completed",
789 "type": "text/javascript",
791 "tests[\"Status code is 200\"] = responseCode.code === 200;",
793 "var jsonData = JSON.parse(responseBody);",
794 "var distrib_SO = false;",
795 "var distrib_AAI = false;",
796 "var distrib_SDNC = false;",
799 "for (var i = 0; i < jsonData.distributionStatusList.length; i++) { ",
800 " if ((jsonData.distributionStatusList[i].omfComponentID === \"SO-COpenSource-Env11\") && (jsonData.distributionStatusList[i].status === \"DOWNLOAD_OK\"))",
802 " distrib_SO = true;",
804 " if ((jsonData.distributionStatusList[i].omfComponentID === \"aai-ml\") && (jsonData.distributionStatusList[i].status === \"DOWNLOAD_OK\"))",
806 " distrib_AAI = true;",
808 " if ((jsonData.distributionStatusList[i].omfComponentID === \"sdc-COpenSource-Env11-sdnc-dockero\") && (jsonData.distributionStatusList[i].status === \"DOWNLOAD_OK\"))",
810 " distrib_SDNC = true;",
815 "if (distrib_SO === false) {",
816 " tests[postman.getGlobalVariable(\"service\")+\" not distributed to SO\"] = false;",
820 " tests[postman.getGlobalVariable(\"service\")+\" distributed to SO\"] = true;",
823 "if (distrib_AAI === false) {",
824 " tests[postman.getGlobalVariable(\"service\")+\" not distributed to AAI\"] = false;",
828 " tests[postman.getGlobalVariable(\"service\")+\" distributed to AAI\"] = true;",
831 "if (distrib_SDNC === false) {",
832 " tests[postman.getGlobalVariable(\"service\")+\" not distributed to SDNC\"] = false;",
836 " tests[postman.getGlobalVariable(\"service\")+\" distributed to SDNC\"] = true;",
843 "url": "{{url-sdc2}}/sdc1/feProxy/rest/v1/catalog/services/distribution/{{auto_distribution_id}}",
847 "key": "Content-Type",
848 "value": "application/json",
853 "value": "application/json",
857 "key": "X-TransactionId",
858 "value": "ONAP-Test",
867 "key": "X-FromAppId",
868 "value": "ONAP-Test",
872 "key": "Authorization",
873 "value": "Basic YmVlcDpib29w",
877 "key": "x-ecomp-instanceid",
878 "value": "ONAP-Test",