{ "item": [ { "id": "bf7bcfcb-2a7d-4056-88d5-edfad18836c4", "name": "Webhook", "description": { "content": "", "type": "text/plain" }, "item": [ { "id": "a38db5e6-bafb-4c77-a77f-5ae61d99e747", "name": "Receive a bwell webhook event", "request": { "name": "Receive a bwell webhook event", "description": { "content": "This endpoint accepts bwell async operation events to be handled by the client.", "type": "text/plain" }, "url": { "path": [ "webhook" ], "host": [ "{{baseUrl}}" ], "query": [], "variable": [] }, "header": [ { "key": "Content-Type", "value": "application/json" }, { "key": "Accept", "value": "application/json" } ], "method": "POST", "auth": null, "body": { "mode": "raw", "raw": "{\n \"resourceType\": \"\",\n \"type\": \"\",\n \"id\": \"\",\n \"entry\": [\n {\n \"resource\": {\n \"resourceType\": \"\",\n \"eventCoding\": {\n \"system\": \"\",\n \"code\": \"\"\n },\n \"source\": {\n \"endpoint\": \"\"\n },\n \"destination\": [\n {\n \"endpoint\": \"\"\n },\n {\n \"endpoint\": \"\"\n }\n ],\n \"focus\": [\n {\n \"reference\": \"\"\n },\n {\n \"reference\": \"\"\n }\n ],\n \"extension\": [\n {\n \"url\": \"\",\n \"valueUri\": \"\"\n },\n {\n \"url\": \"\",\n \"valueUri\": \"\"\n }\n ],\n \"id\": \"\",\n \"identifier\": [\n {\n \"use\": \"\",\n \"system\": \"\",\n \"value\": \"\"\n },\n {\n \"use\": \"\",\n \"system\": \"\",\n \"value\": \"\"\n }\n ]\n },\n \"fullUrl\": \"\"\n },\n {\n \"resource\": {\n \"resourceType\": \"\",\n \"eventCoding\": {\n \"system\": \"\",\n \"code\": \"\"\n },\n \"source\": {\n \"endpoint\": \"\"\n },\n \"destination\": [\n {\n \"endpoint\": \"\"\n },\n {\n \"endpoint\": \"\"\n }\n ],\n \"focus\": [\n {\n \"reference\": \"\"\n },\n {\n \"reference\": \"\"\n }\n ],\n \"extension\": [\n {\n \"url\": \"\",\n \"valueUri\": \"\"\n },\n {\n \"url\": \"\",\n \"valueUri\": \"\"\n }\n ],\n \"id\": \"\",\n \"identifier\": [\n {\n \"use\": \"\",\n \"system\": \"\",\n \"value\": \"\"\n },\n {\n \"use\": \"\",\n \"system\": \"\",\n \"value\": \"\"\n }\n ]\n },\n \"fullUrl\": \"\"\n }\n ]\n}", "options": { "raw": { "language": "json" } } } }, "response": [ { "id": "268d615c-8247-4fc4-a445-829f5e10a806", "name": "Successfully received the webhook event.", "originalRequest": { "url": { "path": [ "webhook" ], "host": [ "{{baseUrl}}" ], "query": [], "variable": [] }, "header": [ { "key": "Accept", "value": "application/json" } ], "method": "POST", "body": { "mode": "raw", "raw": "{\n \"resourceType\": \"Bundle\",\n \"type\": \"message\",\n \"id\": \"bundle-data-export\",\n \"entry\": [\n {\n \"resource\": {\n \"resourceType\": \"MessageHeader\",\n \"eventCoding\": {\n \"system\": \"http://icanbwell.com/event-types\",\n \"code\": \"data-export-completed\"\n },\n \"source\": {\n \"endpoint\": \"https://icanbwell.com\"\n },\n \"destination\": [\n {\n \"endpoint\": \"https://client.system.com/webhook\"\n }\n ],\n \"focus\": [\n {\n \"reference\": \"Person/789\"\n }\n ],\n \"extension\": [\n {\n \"url\": \"http://icanbwell.com/fhir/StructureDefinition/download-url\",\n \"valueUri\": \"https://app.prod.icanbwell.com/client_id#/auth?authCode=12345&redirectUri=https://app.prod.icanbwell.com/client_id#/download/12345?type=userDataExport\"\n }\n ]\n }\n },\n {\n \"fullUrl\": \"https://icanbwell.com/fhir/Person/789\",\n \"resource\": {\n \"resourceType\": \"Person\",\n \"id\": \"789\",\n \"identifier\": [\n {\n \"use\": \"official\",\n \"system\": \"urn:client:identifier\",\n \"value\": \"a5ddab6d-24b0-4e52-a99d-f33263db5997\"\n }\n ]\n }\n }\n ]\n}", "options": { "raw": { "language": "json" } } } }, "status": "OK", "code": 200, "header": [ { "key": "Content-Type", "value": "application/json" } ], "body": "{\n \"resourceType\": \"Bundle\",\n \"type\": \"message\",\n \"id\": \"bundle-webhook-response\",\n \"entry\": [\n {\n \"resource\": {\n \"resourceType\": \"MessageHeader\",\n \"eventCoding\": {\n \"system\": \"http://icanbwell.com/event-types\",\n \"code\": \"webhook-payload-received\"\n },\n \"source\": {\n \"endpoint\": \"https://client.system.com\"\n },\n \"destination\": [\n {\n \"endpoint\": \"https://icanbwell.com\"\n }\n ],\n \"response\": {\n \"identifier\": \"bundle-user-delete\",\n \"code\": \"ok\"\n }\n }\n }\n ]\n}", "cookie": [], "_postman_previewlanguage": "json" }, { "id": "eb9f3fc0-cb84-45d8-bc36-e78da3f3ca59", "name": "Invalid request payload.", "originalRequest": { "url": { "path": [ "webhook" ], "host": [ "{{baseUrl}}" ], "query": [], "variable": [] }, "method": "POST", "body": { "mode": "raw", "raw": "{\n \"resourceType\": \"Bundle\",\n \"type\": \"message\",\n \"id\": \"bundle-data-export\",\n \"entry\": [\n {\n \"resource\": {\n \"resourceType\": \"MessageHeader\",\n \"eventCoding\": {\n \"system\": \"http://icanbwell.com/event-types\",\n \"code\": \"data-export-completed\"\n },\n \"source\": {\n \"endpoint\": \"https://icanbwell.com\"\n },\n \"destination\": [\n {\n \"endpoint\": \"https://client.system.com/webhook\"\n }\n ],\n \"focus\": [\n {\n \"reference\": \"Person/789\"\n }\n ],\n \"extension\": [\n {\n \"url\": \"http://icanbwell.com/fhir/StructureDefinition/download-url\",\n \"valueUri\": \"https://app.prod.icanbwell.com/client_id#/auth?authCode=12345&redirectUri=https://app.prod.icanbwell.com/client_id#/download/12345?type=userDataExport\"\n }\n ]\n }\n },\n {\n \"fullUrl\": \"https://icanbwell.com/fhir/Person/789\",\n \"resource\": {\n \"resourceType\": \"Person\",\n \"id\": \"789\",\n \"identifier\": [\n {\n \"use\": \"official\",\n \"system\": \"urn:client:identifier\",\n \"value\": \"a5ddab6d-24b0-4e52-a99d-f33263db5997\"\n }\n ]\n }\n }\n ]\n}", "options": { "raw": { "language": "json" } } } }, "status": "Bad Request", "code": 400, "header": [ { "key": "Content-Type", "value": "text/plain" } ], "body": "", "cookie": [], "_postman_previewlanguage": "text" }, { "id": "a982b64b-cd04-42e1-966a-5cdb278511bf", "name": "Invalid HMAC signature.", "originalRequest": { "url": { "path": [ "webhook" ], "host": [ "{{baseUrl}}" ], "query": [], "variable": [] }, "header": [ { "key": "Accept", "value": "application/json" } ], "method": "POST", "body": { "mode": "raw", "raw": "{\n \"resourceType\": \"Bundle\",\n \"type\": \"message\",\n \"id\": \"bundle-data-export\",\n \"entry\": [\n {\n \"resource\": {\n \"resourceType\": \"MessageHeader\",\n \"eventCoding\": {\n \"system\": \"http://icanbwell.com/event-types\",\n \"code\": \"data-export-completed\"\n },\n \"source\": {\n \"endpoint\": \"https://icanbwell.com\"\n },\n \"destination\": [\n {\n \"endpoint\": \"https://client.system.com/webhook\"\n }\n ],\n \"focus\": [\n {\n \"reference\": \"Person/789\"\n }\n ],\n \"extension\": [\n {\n \"url\": \"http://icanbwell.com/fhir/StructureDefinition/download-url\",\n \"valueUri\": \"https://app.prod.icanbwell.com/client_id#/auth?authCode=12345&redirectUri=https://app.prod.icanbwell.com/client_id#/download/12345?type=userDataExport\"\n }\n ]\n }\n },\n {\n \"fullUrl\": \"https://icanbwell.com/fhir/Person/789\",\n \"resource\": {\n \"resourceType\": \"Person\",\n \"id\": \"789\",\n \"identifier\": [\n {\n \"use\": \"official\",\n \"system\": \"urn:client:identifier\",\n \"value\": \"a5ddab6d-24b0-4e52-a99d-f33263db5997\"\n }\n ]\n }\n }\n ]\n}", "options": { "raw": { "language": "json" } } } }, "status": "Unauthorized", "code": 401, "header": [ { "key": "Content-Type", "value": "application/json" } ], "body": "{\n \"error\": \"Unauthorized\"\n}", "cookie": [], "_postman_previewlanguage": "json" }, { "id": "9ff34cce-3e54-42a2-a80c-58d3134e91f8", "name": "Internal server error.", "originalRequest": { "url": { "path": [ "webhook" ], "host": [ "{{baseUrl}}" ], "query": [], "variable": [] }, "method": "POST", "body": { "mode": "raw", "raw": "{\n \"resourceType\": \"Bundle\",\n \"type\": \"message\",\n \"id\": \"bundle-data-export\",\n \"entry\": [\n {\n \"resource\": {\n \"resourceType\": \"MessageHeader\",\n \"eventCoding\": {\n \"system\": \"http://icanbwell.com/event-types\",\n \"code\": \"data-export-completed\"\n },\n \"source\": {\n \"endpoint\": \"https://icanbwell.com\"\n },\n \"destination\": [\n {\n \"endpoint\": \"https://client.system.com/webhook\"\n }\n ],\n \"focus\": [\n {\n \"reference\": \"Person/789\"\n }\n ],\n \"extension\": [\n {\n \"url\": \"http://icanbwell.com/fhir/StructureDefinition/download-url\",\n \"valueUri\": \"https://app.prod.icanbwell.com/client_id#/auth?authCode=12345&redirectUri=https://app.prod.icanbwell.com/client_id#/download/12345?type=userDataExport\"\n }\n ]\n }\n },\n {\n \"fullUrl\": \"https://icanbwell.com/fhir/Person/789\",\n \"resource\": {\n \"resourceType\": \"Person\",\n \"id\": \"789\",\n \"identifier\": [\n {\n \"use\": \"official\",\n \"system\": \"urn:client:identifier\",\n \"value\": \"a5ddab6d-24b0-4e52-a99d-f33263db5997\"\n }\n ]\n }\n }\n ]\n}", "options": { "raw": { "language": "json" } } } }, "status": "Internal Server Error", "code": 500, "header": [ { "key": "Content-Type", "value": "text/plain" } ], "body": "", "cookie": [], "_postman_previewlanguage": "text" } ], "event": [], "protocolProfileBehavior": { "disableBodyPruning": true } } ], "event": [] } ], "event": [], "variable": [ { "type": "string", "value": "/", "key": "baseUrl" } ], "info": { "_postman_id": "369f2660-bdd0-40c2-b2ba-b56f1a8319d0", "name": "Client Webhook API", "schema": "https://schema.getpostman.com/json/collection/v2.1.0/collection.json", "description": { "content": "Client's Webhook API to receive bwell messages. The specification is heavily based on FHIR messaging specification. Some additional notes:\n- The actual URL/POST method to be provided by the client. `/webhook` POST is a placeholder.\n- `destination.endpoint` in the request will reflect the client supplied URL.\n- The client user can be identified via the `urn:client:identifier` `value` in the `Person` resource of the request.\n\n**Resources**:\n- [Messaging using FHIR Resources](https://www.hl7.org/fhir/messaging.html)\n- [Message Header Resource](https://www.hl7.org/fhir/messageheader.html)\n", "type": "text/plain" } } }