@healthcloudai/hc-sdk 2.16.0 → 3.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,117 @@
1
+ # Update SMS/phone contact-preference consent
2
+
3
+ Operation ID: `patient.updateCommunicationConsent`
4
+
5
+ Update SMS/phone contact-preference consent
6
+
7
+ ## Public method
8
+
9
+ `updateCommunicationConsent`
10
+
11
+ Signature: `patient.updateCommunicationConsent(request)`
12
+
13
+ Return type: `Promise<CommunicationConsentResponse>`
14
+
15
+ ## Authentication
16
+
17
+ Classification: **AUTHENTICATED**
18
+
19
+ Schemes: `bearerAuth`
20
+
21
+ ## Prerequisites
22
+
23
+ None documented.
24
+
25
+ ## HTTP
26
+
27
+ `PUT /patients/communication-consent`
28
+
29
+ ## Path parameters
30
+
31
+ None.
32
+
33
+ ## Query parameters
34
+
35
+ None.
36
+
37
+ ## Body parameters
38
+
39
+ | Name | Type | Required | Format | Allowed values | Default | Nullable | Description |
40
+ |---|---|---:|---|---|---|---:|---|
41
+ | `body` | [`UpdateCommunicationConsentRequest`](../models/UpdateCommunicationConsentRequest.md) | No | | | | No | |
42
+
43
+ Request model: [`UpdateCommunicationConsentRequest`](../models/UpdateCommunicationConsentRequest.md)
44
+
45
+ ## Request example
46
+
47
+ ```json
48
+ {
49
+ "phone_permitted": true,
50
+ "sms_permitted": true
51
+ }
52
+ ```
53
+
54
+ ## Success responses
55
+
56
+ | Status | Shape | Content type | Description |
57
+ |---|---|---|---|
58
+ | `200` | [`CommunicationConsentResponse`](../models/CommunicationConsentResponse.md) | application/json | Consent updated |
59
+
60
+ ## Success response examples
61
+
62
+ ### 200
63
+
64
+ ```json
65
+ {
66
+ "effective_date": "2026-01-01",
67
+ "id": "string",
68
+ "phone_permitted": true,
69
+ "sms_permitted": true
70
+ }
71
+ ```
72
+
73
+ ## Common errors
74
+
75
+ None declared in canonical OpenAPI.
76
+
77
+ ## Error examples
78
+
79
+ None declared in canonical OpenAPI.
80
+
81
+ ## NodeJS / TypeScript implementation
82
+
83
+ ```ts
84
+ import { HCSDK } from "@healthcloudai/hc-sdk";
85
+ import type { UpdateCommunicationConsentRequest } from "@healthcloudai/hc-sdk";
86
+ ```
87
+
88
+ ```ts
89
+ const request = {
90
+ "phone_permitted": true,
91
+ "sms_permitted": true
92
+ };
93
+
94
+ const result = await patient.updateCommunicationConsent(request);
95
+ ```
96
+
97
+ ## cURL
98
+
99
+ ```bash
100
+ curl -X PUT \
101
+ -H 'Authorization: Bearer <ACCESS_TOKEN>' \
102
+ -H 'Content-Type: application/json' \
103
+ -d '{"phone_permitted":true,"sms_permitted":true}' \
104
+ 'https://dev-api-patient.health.cloud/patients/communication-consent'
105
+ ```
106
+
107
+ ## Notes
108
+
109
+ None.
110
+
111
+ ## Prepared Test Console scenario
112
+
113
+ No canonical scenario is currently associated.
114
+
115
+ ## Real response
116
+
117
+ No approved real integration response is currently published. Unapproved candidates are never rendered as examples.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@healthcloudai/hc-sdk",
3
- "version": "2.16.0",
3
+ "version": "3.0.0",
4
4
  "description": "All-in-one HealthCloud SDK with typed platform APIs and secure connector clients.",
5
5
  "author": "Healthcheck Systems Inc",
6
6
  "license": "MIT",
@@ -53,15 +53,15 @@
53
53
  }
54
54
  },
55
55
  "devDependencies": {
56
- "@types/node": "^20.19.30",
56
+ "@types/node": "^24.0.0",
57
57
  "@typescript-eslint/eslint-plugin": "^7.18.0",
58
58
  "@typescript-eslint/parser": "^7.18.0",
59
59
  "eslint": "^8.56.0",
60
- "playwright": "^1.62.0",
60
+ "playwright": "^1.63.0",
61
61
  "tsup": "^8.0.0",
62
- "tsx": "^4.20.3",
62
+ "tsx": "^4.23.13",
63
63
  "typescript": "^5.3.0",
64
- "vitest": "^3.2.7"
64
+ "vitest": "^5.0.0"
65
65
  },
66
66
  "engines": {
67
67
  "node": ">=18"