Skip to content
Snippets Groups Projects
Commit 457eb8dd authored by torrespel's avatar torrespel
Browse files

Changed node script port

parent b2109faa
No related branches found
No related tags found
1 merge request!15Changed node script port
......@@ -88,7 +88,7 @@
"header": [],
"body": {
"mode": "raw",
"raw": "{\n \"username\": \"{{USER_NAME}}\",\n \"password\": \"{{USER_PASSWORD}}\",\n \"enterprise\": \"ETSI\",\n \"country\": \"Spain\",\n \"email\": \"example@gmail.com\",\n \"purpose\": \"Use OpenCAPIF\",\n \"phone_number\": \"+123456789\",\n \"company_web\": \"www.etsi.com\",\n \"description\": \"UserDescription\"\n}",
"raw": "{\n \"username\": \"{{USER_NAME}}\",\n \"password\": \"{{USER_PASSWORD}}\",\n \"enterprise\": \"Telefonica\",\n \"country\": \"Spain\",\n \"email\": \"naas@gmail.com\",\n \"purpose\": \"Use OpenCAPIF for NaaS6G project\",\n \"phone_number\": \"+123456789\",\n \"company_web\": \"www.naas6g.com\",\n \"description\": \"UserDescription\"\n}",
"options": {
"raw": {
"language": "json"
......@@ -128,7 +128,7 @@
"",
"setTimeout(() => {",
" pm.sendRequest({",
" url: 'http://localhost:3000/write_ca',",
" url: 'http://'+ pm.environment.get(\"NODE_HOSTNAME\") + ':'+ pm.environment.get(\"NODE_PORT\")+'/write_ca',",
" method: 'POST',",
" header: 'Content-Type:application/json',",
" encoding: 'binary',",
......@@ -226,7 +226,7 @@
"",
" setTimeout(() => {",
" pm.sendRequest({",
" url: 'http://localhost:3000/generate_csr',",
" url: 'http://'+ pm.environment.get(\"NODE_HOSTNAME\") + ':'+ pm.environment.get(\"NODE_PORT\")+'/generate_csr',",
" method: 'POST',",
" header: 'Content-Type:application/json',",
" encoding: 'binary',",
......@@ -251,7 +251,8 @@
}
],
"protocolProfileBehavior": {
"strictSSL": false
"strictSSL": false,
"protocolVersion": "auto"
},
"request": {
"auth": {
......@@ -283,12 +284,11 @@
}
},
"url": {
"raw": "https://{{CAPIF_HOSTNAME}}:{{CAPIF_PORT}}/{{ONBOARDING_URL}}",
"raw": "https://{{CAPIF_HOSTNAME}}/{{ONBOARDING_URL}}",
"protocol": "https",
"host": [
"{{CAPIF_HOSTNAME}}"
],
"port": "{{CAPIF_PORT}}",
"path": [
"{{ONBOARDING_URL}}"
]
......@@ -305,7 +305,7 @@
"exec": [
"setTimeout(() => {",
" pm.sendRequest({",
" url: 'http://localhost:3000/write_cert',",
" url: 'http://'+ pm.environment.get(\"NODE_HOSTNAME\") + ':'+ pm.environment.get(\"NODE_PORT\")+'/write_cert',",
" method: 'POST',",
" header: 'Content-Type:application/json',",
" encoding: 'binary',",
......@@ -329,6 +329,14 @@
"listen": "test",
"script": {
"exec": [
"var res = JSON.parse(responseBody);",
"if (pm.response.code == 201){",
" ",
" pm.environment.set('API_ID', res.apiId);",
"",
"}",
"",
"",
""
],
"type": "text/javascript",
......@@ -337,7 +345,8 @@
}
],
"protocolProfileBehavior": {
"strictSSL": true
"strictSSL": true,
"protocolVersion": "auto"
},
"request": {
"auth": {
......@@ -354,7 +363,7 @@
],
"body": {
"mode": "raw",
"raw": "\n{\n \"apiName\": \"hello_api_demo_v2\",\n \"aefProfiles\": [\n {\n \"aefId\": \"{{AEF_ID}}\",\n \"versions\": [\n {\n \"apiVersion\": \"v1\",\n \"expiry\": \"2021-11-30T10:32:02.004Z\",\n \"resources\": [\n {\n \"resourceName\": \"hello-endpoint\",\n \"commType\": \"REQUEST_RESPONSE\",\n \"uri\": \"/hello\",\n \"custOpName\": \"string\",\n \"operations\": [\n \"POST\"\n ],\n \"description\": \"Endpoint to receive a welcome message\"\n }\n ],\n \"custOperations\": [\n {\n \"commType\": \"REQUEST_RESPONSE\",\n \"custOpName\": \"string\",\n \"operations\": [\n \"POST\"\n ],\n \"description\": \"string\"\n }\n ]\n }\n ],\n \"protocol\": \"HTTP_1_1\",\n \"dataFormat\": \"JSON\",\n \"securityMethods\": [\"OAUTH\"],\n \"interfaceDescriptions\": [\n {\n \"ipv4Addr\": \"localhost\",\n \"port\": 8088,\n \"securityMethods\": [\"OAUTH\"]\n }\n ]\n }\n ],\n \"description\": \"Hello api services\",\n \"supportedFeatures\": \"fffff\",\n \"shareableInfo\": {\n \"isShareable\": true,\n \"capifProvDoms\": [\n \"string\"\n ]\n },\n \"serviceAPICategory\": \"string\",\n \"apiSuppFeats\": \"fffff\",\n \"pubApiPath\": {\n \"ccfIds\": [\n \"string\"\n ]\n },\n \"ccfId\": \"string\"\n }",
"raw": "\n{\n \"apiName\": \"hello_api_demo_v6\",\n \"aefProfiles\": [\n {\n \"aefId\": \"{{AEF_ID}}\",\n \"versions\": [\n {\n \"apiVersion\": \"v1\",\n \"expiry\": \"2021-11-30T10:32:02.004Z\",\n \"resources\": [\n {\n \"resourceName\": \"hello-endpoint\",\n \"commType\": \"REQUEST_RESPONSE\",\n \"uri\": \"/hello\",\n \"custOpName\": \"string\",\n \"operations\": [\n \"POST\"\n ],\n \"description\": \"Endpoint to receive a welcome message\"\n }\n ],\n \"custOperations\": [\n {\n \"commType\": \"REQUEST_RESPONSE\",\n \"custOpName\": \"string\",\n \"operations\": [\n \"POST\"\n ],\n \"description\": \"string\"\n }\n ]\n }\n ],\n \"protocol\": \"HTTP_1_1\",\n \"dataFormat\": \"JSON\",\n \"securityMethods\": [\"OAUTH\"],\n \"interfaceDescriptions\": [\n {\n \"ipv4Addr\": \"localhost\",\n \"port\": 8088,\n \"securityMethods\": [\"OAUTH\"]\n }\n ]\n }\n ],\n \"description\": \"Hello api services\",\n \"supportedFeatures\": \"fffff\",\n \"shareableInfo\": {\n \"isShareable\": true,\n \"capifProvDoms\": [\n \"string\"\n ]\n },\n \"serviceAPICategory\": \"string\",\n \"apiSuppFeats\": \"fffff\",\n \"pubApiPath\": {\n \"ccfIds\": [\n \"string\"\n ]\n },\n \"ccfId\": \"string\",\n \"apiStatus\": {\n \"aefIds\": []\n }\n }",
"options": {
"raw": {
"language": "json"
......@@ -409,7 +418,7 @@
"",
"setTimeout(() => {",
" pm.sendRequest({",
" url: 'http://localhost:3000/generate_csr_invoker',",
" url: 'http://'+ pm.environment.get(\"NODE_HOSTNAME\") + ':'+ pm.environment.get(\"NODE_PORT\")+'/generate_csr_invoker',",
" method: 'POST',",
" header: 'Content-Type:application/json',",
" encoding: 'binary',",
......@@ -487,7 +496,7 @@
"exec": [
"setTimeout(() => {",
" pm.sendRequest({",
" url: 'http://localhost:3000/write_cert',",
" url: 'http://'+ pm.environment.get(\"NODE_HOSTNAME\") + ':'+ pm.environment.get(\"NODE_PORT\")+'/write_cert',",
" method: 'POST',",
" header: 'Content-Type:application/json',",
" encoding: 'binary',",
......@@ -578,7 +587,7 @@
"exec": [
"setTimeout(() => {",
" pm.sendRequest({",
" url: 'http://localhost:3000/write_cert',",
" url: 'http://'+ pm.environment.get(\"NODE_HOSTNAME\") + ':'+ pm.environment.get(\"NODE_PORT\")+'/write_cert',",
" method: 'POST',",
" header: 'Content-Type:application/json',",
" encoding: 'binary',",
......@@ -660,7 +669,7 @@
"exec": [
"setTimeout(() => {",
" pm.sendRequest({",
" url: 'http://localhost:3000/write_cert',",
" url: 'http://'+ pm.environment.get(\"NODE_HOSTNAME\") + ':'+ pm.environment.get(\"NODE_PORT\")+'/write_cert',",
" method: 'POST',",
" header: 'Content-Type:application/json',",
" encoding: 'binary',",
......@@ -830,7 +839,7 @@
"exec": [
"setTimeout(() => {",
" pm.sendRequest({",
" url: 'http://localhost:3000/write_cert',",
" url: 'http://'+ pm.environment.get(\"NODE_HOSTNAME\") + ':'+ pm.environment.get(\"NODE_PORT\")+'/write_cert',",
" method: 'POST',",
" header: 'Content-Type:application/json',",
" encoding: 'binary',",
......@@ -881,7 +890,7 @@
"exec": [
"setTimeout(() => {",
" pm.sendRequest({",
" url: 'http://localhost:3000/write_cert',",
" url: 'http://'+ pm.environment.get(\"NODE_HOSTNAME\") + ':'+ pm.environment.get(\"NODE_PORT\")+'/write_cert',",
" method: 'POST',",
" header: 'Content-Type:application/json',",
" encoding: 'binary',",
......
{
"id": "7111197e-e9c8-4988-a519-3284ab9021a9",
"name": "CAPIF",
"id": "adb492cf-1d02-4a7c-a4a2-00cb54c202f1",
"name": "CAPIF Copy",
"values": [
{
"key": "CAPIF_HOSTNAME",
......@@ -26,6 +26,18 @@
"type": "default",
"enabled": true
},
{
"key": "NODE_HOSTNAME",
"value": "localhost",
"type": "default",
"enabled": true
},
{
"key": "NODE_PORT",
"value": "3010",
"type": "default",
"enabled": true
},
{
"key": "USERNAME",
"value": "ProviderONE",
......@@ -262,6 +274,6 @@
}
],
"_postman_variable_scope": "environment",
"_postman_exported_at": "2024-07-30T07:59:01.623Z",
"_postman_exported_using": "Postman/11.3.2"
"_postman_exported_at": "2024-10-07T09:27:29.742Z",
"_postman_exported_using": "Postman/11.12.0"
}
\ No newline at end of file
No preview for this file type
......@@ -193,7 +193,7 @@ app.post('/write_ca', (req, res) => {
});
});
app.listen(3000, () => {
console.log('ResponsesToFile App is listening now! Send them requests my way!');
app.listen(3010, () => {
console.log('Listener API running.');
console.log(`Data is being stored at location: ${path.join(process.cwd(), folderPath)}`);
});
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment