{ "parameters": { "$connections": { "value": { "blockchainethereum": { "connectionId": "/subscriptions/9aff6261-c18e-4417-9f05-cb8a8f540d03/resourceGroups/", "connectionName": "", "id": "/subscriptions/9aff6261-c18e-4417-9f05-cb8a8f540d03/providers/Microsoft.Web/locations/eastus/managedApis/blockchainethereum" } } } }, "definition": { "$schema": "https://schema.management.azure.com/providers/Microsoft.Logic/schemas/2016-06-01/workflowdefinition.json#", "contentVersion": "1.0.0.0", "parameters": { "$connections": { "defaultValue": { }, "type": "Object" } }, "triggers": { "manual": { "type": "Request", "kind": "Http", "inputs": { "schema": { "properties": { "_patient_name": { "type": "string" }, "_patient_consent": { "type": "string" } }, "type": "object" } } } }, "actions": { "Call smart contract function": { "runAfter": { }, "type": "ApiConnection", "inputs": { "body": { "_patient_name": "@triggerBody()?['_patient_name']", "_patient_consent": "@triggerBody()?['_patient_consent']" }, "host": { "connection": { "name": "@parameters('$connections')['blockchainethereum']['connectionId']" } }, "method": "post", "path": "/contract/functions/@{encodeURIComponent(encodeURIComponent('storepatientconsent'))}/execute", "queries": { "abi": "[{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"string\",\"name\":\"patient_name\",\"type\":\"string\"},{\"indexed\":true,\"internalType\":\"string\",\"name\":\"patient_consent\",\"type\":\"string\"}],\"name\":\"patientdata\",\"type\":\"event\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"_patient_name\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"_patient_consent\",\"type\":\"string\"}],\"name\":\"storepatientconsent\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", "contractAddress": "0xC2305d41Dd4408614264ee364950dc8009F1A010" } } }, "Response": { "runAfter": { "Call smart contract function": [ "Succeeded" ] }, "type": "Response", "kind": "Http", "inputs": { "body": "@body('Call smart contract function')", "statusCode": 200 } } }, "outputs": {} } }