@alvera-ai/platform-sdk 0.17.0 → 0.18.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.
- package/.agent/AGENTS.md +82 -144
- package/.agent/account_management.md +2 -2
- package/.agent/action_logs.md +4 -4
- package/.agent/ai_agents.md +28 -21
- package/.agent/ai_sandbox.md +49 -39
- package/.agent/connected_apps.md +3 -3
- package/.agent/cookbook/_fixtures/README.md +1 -1
- package/.agent/cookbook/_fixtures/{foundation → organic-marketing}/_lead_submissions_foundation_generic_table.liquid +1 -1
- package/.agent/cookbook/_fixtures/organic-marketing/_lead_submissions_foundation_legal_entity.liquid +80 -0
- package/.agent/cookbook/_fixtures/{foundation → organic-marketing}/_lead_submissions_foundation_mdm.liquid +2 -1
- package/.agent/cookbook/_fixtures/payments-compliance/_compliance_screenings_generic_table.liquid +57 -0
- package/.agent/cookbook/_fixtures/payments-compliance/_compliance_screenings_legal_entity.liquid +30 -0
- package/.agent/cookbook/_fixtures/payments-compliance/_compliance_screenings_mdm.liquid +44 -0
- package/.agent/cookbook/_fixtures/payments-compliance/_payment_accounts_generic_table.liquid +57 -0
- package/.agent/cookbook/_fixtures/payments-compliance/_payment_accounts_legal_entity.liquid +36 -0
- package/.agent/cookbook/_fixtures/payments-compliance/_payment_accounts_mdm.liquid +41 -0
- package/.agent/cookbook/_fixtures/primary-care-feedback/_cahps_appointments_generic_table.liquid +70 -0
- package/.agent/cookbook/_fixtures/primary-care-feedback/_cahps_appointments_legal_entity.liquid +52 -0
- package/.agent/cookbook/_fixtures/primary-care-feedback/_cahps_appointments_mdm.liquid +42 -0
- package/.agent/cookbook/_fixtures/subscription-saas/_customers_subscription_generic_table.liquid +38 -0
- package/.agent/cookbook/_fixtures/subscription-saas/_customers_subscription_legal_entity.liquid +48 -0
- package/.agent/cookbook/_fixtures/subscription-saas/_customers_subscription_mdm.liquid +49 -0
- package/.agent/cookbook/organic-marketing.md +2801 -0
- package/.agent/cookbook/payments-compliance.md +2180 -0
- package/.agent/cookbook/primary-care.md +2175 -0
- package/.agent/cookbook/subscription-saas.md +2403 -0
- package/.agent/data_activation_clients.md +65 -52
- package/.agent/datalakes.md +338 -171
- package/.agent/errors.md +3 -3
- package/.agent/generic_tables.md +151 -62
- package/.agent/interoperability_contracts.md +57 -22
- package/.agent/mdm.md +136 -153
- package/.agent/messages.md +36 -34
- package/.agent/mock-services.md +1 -1
- package/.agent/mutations.md +2 -2
- package/.agent/templates.md +14 -13
- package/.agent/tools.md +63 -21
- package/.agent/type_naming.md +13 -13
- package/.agent/workflows.md +99 -53
- package/README.md +2 -2
- package/dist/bin/platform-sdk.mjs +33 -47
- package/dist/bin/platform-sdk.mjs.map +1 -1
- package/dist/index.d.mts +565 -379
- package/dist/index.d.mts.map +1 -1
- package/dist/index.mjs +494 -59
- package/dist/index.mjs.map +1 -1
- package/package.json +4 -3
- package/.agent/cookbook/_fixtures/foundation/_lead_submissions_foundation_legal_entity.liquid +0 -88
- package/.agent/cookbook/_fixtures/healthcare/_cahps_appointments_healthcare_appointment.liquid +0 -47
- package/.agent/cookbook/_fixtures/healthcare/_cahps_appointments_healthcare_mdm.liquid +0 -24
- package/.agent/cookbook/_fixtures/healthcare/_cahps_appointments_healthcare_patient.liquid +0 -38
- package/.agent/cookbook/_fixtures/payments/_compliance_screenings_payments_compliance_screening.liquid +0 -59
- package/.agent/cookbook/_fixtures/payments/_compliance_screenings_payments_mdm.liquid +0 -36
- package/.agent/cookbook/_fixtures/payments/_payment_accounts_payments_mdm.liquid +0 -30
- package/.agent/cookbook/_fixtures/payments/_payment_accounts_payments_payment_account.liquid +0 -55
- package/.agent/cookbook/_fixtures/subscription/_customers_subscription_mdm.liquid +0 -20
- package/.agent/cookbook/_setup/foundation.md +0 -359
- package/.agent/cookbook/_setup/healthcare.md +0 -361
- package/.agent/cookbook/_setup/payments.md +0 -365
- package/.agent/cookbook/_setup/subscription.md +0 -364
- package/.agent/cookbook/action-status-updaters.md +0 -278
- package/.agent/cookbook/ai-agent-invoke.md +0 -279
- package/.agent/cookbook/appointment-review-sms-workflow.md +0 -801
- package/.agent/cookbook/birthday-greeting-sms-trigger.md +0 -696
- package/.agent/cookbook/bulk-ingest.md +0 -302
- package/.agent/cookbook/contact-us-triage-with-llm.md +0 -663
- package/.agent/cookbook/dunning-sms-for-delinquent.md +0 -659
- package/.agent/cookbook/generic-tables.md +0 -244
- package/.agent/cookbook/invite-team.md +0 -200
- package/.agent/cookbook/kyc-notification-on-account-activation.md +0 -661
- package/.agent/cookbook/marketing-campaign-send.md +0 -1044
- package/.agent/cookbook/paginated-restapi-poller.md +0 -383
- package/.agent/cookbook/rest-fetch.md +0 -273
- package/.agent/cookbook/sanctions-screening-with-agent-review.md +0 -773
- package/.agent/cookbook/score-leads-with-llm-categorization.md +0 -665
- package/.agent/cookbook/system-templates.md +0 -165
- package/.agent/cookbook/talk-to-data.md +0 -178
- package/.agent/cookbook/triage-prospects-by-priority.md +0 -571
- package/.agent/cookbook/welcome-sms-for-customers.md +0 -647
- /package/.agent/cookbook/_fixtures/{healthcare → primary-care-feedback}/memorandum-of-association-01.png +0 -0
- /package/.agent/cookbook/_fixtures/{healthcare → primary-care-feedback}/sample_two_page.pdf +0 -0
- /package/.agent/cookbook/_fixtures/{subscription → subscription-saas}/_customers_subscription_customer.liquid +0 -0
- /package/.agent/cookbook/_fixtures/{subscription → subscription-saas}/stripe_customers_batch1.csv +0 -0
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
{% comment %}
|
|
2
|
+
Stripe Customers → MDMInput JSON.
|
|
3
|
+
|
|
4
|
+
Used by Contract B's `mdm_input_config` (`resource_type:
|
|
5
|
+
"generic_table"`). The DAC pipeline renders this against the fetched
|
|
6
|
+
customer, validates the result as an MDM input, and resolves it —
|
|
7
|
+
which routes the attrs through the LegalEntity upsert, whose
|
|
8
|
+
identification dedupe collapses repeat resolves sharing the same
|
|
9
|
+
`(id_type, id_number, uri)` triple onto the SAME LegalEntity row
|
|
10
|
+
Contract A wrote. The resolved subject's id is then stamped onto the
|
|
11
|
+
GT row as `legal_entity_id`.
|
|
12
|
+
|
|
13
|
+
The `system` value flows from `data_source.uri`, injected by the DAC
|
|
14
|
+
as `source_uri` — the same channel Contract A's template reads — so
|
|
15
|
+
both contracts emit an identical `(uri, value)` pair and converge on
|
|
16
|
+
one LegalEntity per customer.
|
|
17
|
+
|
|
18
|
+
## Branches
|
|
19
|
+
* `legal_entity_type: "individual"` when Stripe's `customer_type`
|
|
20
|
+
is `individual`
|
|
21
|
+
* `legal_entity_type: "business"` otherwise, with the display name
|
|
22
|
+
as `business_name`
|
|
23
|
+
|
|
24
|
+
GH-859 removed the per-domain identity vocabularies: there is ONE
|
|
25
|
+
field set (`first_name` / `last_name` / `business_name` / `phone` /
|
|
26
|
+
`email` / `identifiers`), not a `customer`-flavoured variant.
|
|
27
|
+
{% endcomment %}
|
|
28
|
+
{% assign p = msg %}
|
|
29
|
+
{% assign le_type = "business" %}
|
|
30
|
+
{% if p.customer_type == "individual" %}{% assign le_type = "individual" %}{% endif %}
|
|
31
|
+
{% assign name_parts = p.name | default: "" | split: " " %}
|
|
32
|
+
{% assign first_name = name_parts[0] | default: "" %}
|
|
33
|
+
{% assign last_name_parts = name_parts | slice: 1, 9 %}
|
|
34
|
+
{% assign last_name = last_name_parts | join: " " %}
|
|
35
|
+
{
|
|
36
|
+
"legal_entity_type": "{{ le_type }}",
|
|
37
|
+
{% if le_type == "business" %}"business_name": "{{ p.name | json_escape }}",{% endif %}
|
|
38
|
+
{% if le_type == "individual" and first_name != "" %}"first_name": "{{ first_name | json_escape }}",{% endif %}
|
|
39
|
+
{% if le_type == "individual" and last_name != "" %}"last_name": "{{ last_name | json_escape }}",{% endif %}
|
|
40
|
+
{% if p.email and p.email != "" %}"email": "{{ p.email | json_escape }}",{% endif %}
|
|
41
|
+
{% if p.phone and p.phone != "" %}"phone": "{{ p.phone | json_escape }}",{% endif %}
|
|
42
|
+
"identifiers": [
|
|
43
|
+
{
|
|
44
|
+
"system": "{{ p.source_uri | json_escape }}",
|
|
45
|
+
"value": "{{ p.customer_number | json_escape }}",
|
|
46
|
+
"type": "digital_identifier"
|
|
47
|
+
}
|
|
48
|
+
]
|
|
49
|
+
}
|