@praxium/sdk 0.2.9 → 0.2.11
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.
- package/README.md +8 -10
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -14,8 +14,15 @@ npm install @praxium/sdk
|
|
|
14
14
|
import { createTenantClient } from '@praxium/sdk'
|
|
15
15
|
|
|
16
16
|
const client = createTenantClient({
|
|
17
|
-
baseUrl: 'https://
|
|
17
|
+
baseUrl: process.env.PRAXIUM_API_URL!, // e.g. 'https://your-practice.praxium.nl'
|
|
18
|
+
apiKey: process.env.PRAXIUM_API_KEY!, // HMAC-signed key: 'hmac_v1_mytenant_1234567890_abc...'
|
|
19
|
+
tenantSlug: 'mytenant', // must match the slug in the API key
|
|
20
|
+
locale: 'nl', // 'nl' (Dutch) or 'en' (English)
|
|
18
21
|
})
|
|
22
|
+
|
|
23
|
+
// Returns data directly — throws PraxiumError on failure
|
|
24
|
+
const hours = await client.getOpeningHours()
|
|
25
|
+
const team = await client.getTeamMembers()
|
|
19
26
|
```
|
|
20
27
|
|
|
21
28
|
## Next.js Revalidation
|
|
@@ -35,15 +42,6 @@ npm run test # Run tests
|
|
|
35
42
|
npm run typecheck # Type-check without emitting
|
|
36
43
|
```
|
|
37
44
|
|
|
38
|
-
## Publishing
|
|
39
|
-
|
|
40
|
-
This package is dual-published:
|
|
41
|
-
|
|
42
|
-
- **GitLab Package Registry** (internal) — via `CI_JOB_TOKEN`
|
|
43
|
-
- **npm public registry** — via [OIDC Trusted Publishing](https://docs.npmjs.com/trusted-publishers/) (no stored secrets)
|
|
44
|
-
|
|
45
|
-
Versioning: `0.2.<commit-count>` — deterministic from git history.
|
|
46
|
-
|
|
47
45
|
## License
|
|
48
46
|
|
|
49
47
|
[MIT](LICENSE)
|