Projo FHIR Documentation
0.1.0 - ci-build Switzerland flag

Projo FHIR Documentation - Local Development build (v0.1.0) built by the FHIR (HL7® FHIR® Standard) Build Tools. See the Directory of published versions

: Example Organization (multi-plan, multi-WABA) - JSON Representation

Raw json | Download

{
  "resourceType" : "Organization",
  "id" : "ExampleOrganization",
  "meta" : {
    "profile" : [
      🔗 "https://projo.evoleen.com/fhir/StructureDefinition/projo-organization"
    ]
  },
  "text" : {
    "status" : "generated",
    "div" : "<div xmlns=\"http://www.w3.org/1999/xhtml\"><p class=\"res-header-id\"><b>Generated Narrative: Organization ExampleOrganization</b></p><a name=\"ExampleOrganization\"> </a><a name=\"hcExampleOrganization\"> </a><div style=\"display: inline-block; background-color: #d9e0e7; padding: 6px; margin: 4px; border: 1px solid #8da1b4; border-radius: 5px; line-height: 60%\"><p style=\"margin-bottom: 0px\"/><p style=\"margin-bottom: 0px\">Profile: <a href=\"StructureDefinition-projo-organization.html\">Projo Organization</a></p></div><p style=\"border: 1px #661aff solid; background-color: #e6e6ff; padding: 10px;\">Unnamed Organization (https://projo.evoleen.com/fhir/organization#dermacare-clinic-zurich)</p><hr/><table class=\"grid\"><tr><td style=\"background-color: #f3f5da\" title=\"The organization of which this organization forms a part\">Part Of:</td><td colspan=\"3\"><a href=\"Organization/example-root-org\">Organization/example-root-org</a></td></tr><tr><td style=\"background-color: #f3f5da\" title=\"Ways to contact the organization\">Contact Detail</td><td colspan=\"3\"><a href=\"tel:+41441234567\">+41441234567</a></td></tr><tr><td style=\"background-color: #f3f5da\" title=\"Repeating complex extension on Organization that binds a plan kind to a versioned PlanDefinition canonical (ADR 0002, ADR 0007). Set by operators via migration/seeding scripts (setOrganizationPlanSlot). Projo runtime never writes plan-slot — only reads it. Read by the orchestrator's applyTriggeredPlanIfNeeded: selectPlanKind picks the lifecycle kind (onboarding for new patients, re-engagement for returning, default otherwise), then resolvePlanCanonicalForKind looks up the slot. For onboarding only, falls back to legacy default-plan (ADR 0003). The onboarding-routing slot is read separately by clinical routing after onboarding completion. plan-slot-kind precedence on cold inbound: onboarding &gt; re-engagement &gt; default.\">Plan Slot:</td><td colspan=\"3\"><ul><li>kind: default</li><li>planDefinition: <code>https://projo.evoleen.com/PlanDefinition/dermacare-atopic-dermatitis-care|1.0.0</code></li></ul></td></tr><tr><td style=\"background-color: #f3f5da\" title=\"Default preferred language for onboarded patients of this Organization. ISO 639-1 (e.g. 'de', 'en'). Set by operators at Organization creation time. Projo never writes this extension — only reads it. Read by buildPatient during identity resolution: getOrganizationPreferredLanguage reads the extension and stamps it onto Patient.communication[0].language.coding[0].code with preferred=true. If absent, the Patient is created without communication preferences and the sidecar's resolvePatientLanguage falls back to 'en'. The patient can later change their language via the dermacare-language-selection Questionnaire, which uses extraction-writeback (target=subject, mode=fill-if-empty) to update Patient.communication.language.\"><a href=\"StructureDefinition-preferred-language.html\">Preferred Language</a></td><td colspan=\"3\">de</td></tr><tr><td style=\"background-color: #f3f5da\" title=\"WhatsApp Business Account ID for this Organization. Set by operators for manually-created Organizations, or by the orchestrator's upsertOrganizationFromInboundBusinessPhone on the unresolved-receiver path. Read by the sidecar to resolve per-WABA credentials from Key Vault (whatsapp-{wabaId}-access-token, whatsapp-{wabaId}-app-secret) with an in-memory LRU cache (TTL 1 hour). No silent fallback — a missing WABA ID causes the sidecar to defer the CR for retry. Multi-WABA support (issue #238): each Organization carries its own WABA id.\"><a href=\"StructureDefinition-waba-account-id.html\">WABA Account ID</a></td><td colspan=\"3\">123456789012345</td></tr><tr><td style=\"background-color: #f3f5da\" title=\"Cached Meta Phone Number ID for the Organization's WhatsApp number. Set by two writers: (1) the orchestrator's upsertOrganizationFromInboundBusinessPhone on the unresolved-receiver path (from the reverse CR's inbound-business-phone-id extension); (2) the sidecar's ensureWhatsAppPhoneNumberId on the first outbound dispatch — queries Meta Graph API GET /{WABA-ID}/phone_numbers, matches by normalized E.164 digits, caches back to Organization. Read by the sidecar on every outbound dispatch to skip the Graph API lookup. No active refresh — if the cached value becomes stale (e.g. Meta rotates the phone-number-id), WhatsApp sends fail and an operator must clear the extension.\"><a href=\"StructureDefinition-wa-phone-number-id.html\">WhatsApp Phone Number ID</a></td><td colspan=\"3\">106540000000000</td></tr></table></div>"
  },
  "extension" : [
    {
      "extension" : [
        {
          "url" : "kind",
          "valueCode" : "default"
        },
        {
          "url" : "planDefinition",
          "valueCanonical" : "https://projo.evoleen.com/PlanDefinition/dermacare-atopic-dermatitis-care|1.0.0"
        }
      ],
      "url" : "https://projo.evoleen.com/fhir/StructureDefinition/plan-slot"
    },
    {
      "url" : "https://projo.evoleen.com/fhir/StructureDefinition/wa-phone-number-id",
      "valueString" : "106540000000000"
    },
    {
      "url" : "https://projo.evoleen.com/fhir/StructureDefinition/waba-account-id",
      "valueString" : "123456789012345"
    },
    {
      "url" : "https://projo.evoleen.com/fhir/StructureDefinition/preferred-language",
      "valueString" : "de"
    }
  ],
  "identifier" : [
    {
      "system" : "https://projo.evoleen.com/fhir/organization",
      "value" : "dermacare-clinic-zurich"
    }
  ],
  "telecom" : [
    {
      "system" : "phone",
      "value" : "+41441234567"
    }
  ],
  "partOf" : {
    "reference" : "Organization/example-root-org"
  }
}