{
  "resourceType": "CapabilityStatement",
  "id": "MAIASubscriptionsCapabilityStatement",
  "url": "https://tiplu.de/fhir/maia/CapabilityStatement/Subscriptions-1.0",
  "title": "MAIA Subscriptions CapabilityStatement",
  "status": "active",
  "experimental": false,
  "publisher": "Tiplu GmbH",
  "version": "1.0.0",
  "date": "2026-03-31",
  "name": "MAIA Subscriptions CapabilityStatement",
  "description": "This CapabilityStatement describes the FHIR Subscription interface exposed by MAIA (product version 1.0 / software version 3.x). Subscribers receive push notifications via REST-Hook when a clinician accepts a rule-based evaluation (MaiaVerdachtsdiagnose). The implementation follows the FHIR R4/R5 Subscriptions Backport IG (http://hl7.org/fhir/uv/subscriptions-backport).",
  "contact": [
    {
      "telecom": [
        {
          "system": "url",
          "value": "https://tiplu.de"
        }
      ]
    }
  ],
  "kind": "capability",
  "software": {
    "name": "Maia",
    "version": "3.x.x"
  },
  "fhirVersion": "4.0.1",
  "format": [
    "application/fhir+json"
  ],
  "rest": [
    {
      "mode": "server",
      "resource": [
        {
          "extension": [
            {
              "url": "http://hl7.org/fhir/StructureDefinition/capabilitystatement-expectation",
              "valueCode": "SHALL"
            },
            {
              "url": "http://hl7.org/fhir/uv/subscriptions-backport/StructureDefinition/capabilitystatement-subscriptiontopic-canonical",
              "valueCanonical": "https://tiplu.de/fhir/maia/SubscriptionTopic/maia-alert-accepted"
            }
          ],
          "type": "Subscription",
          "documentation": "MAIA supports FHIR R4 Subscriptions using the R4/R5 Backport IG (http://hl7.org/fhir/uv/subscriptions-backport). The only supported topic is `maia-alert-accepted`, triggered when a clinician accepts a rule-based evaluation (MaiaVerdachtsdiagnose).\n\n**Fixed constraints (violations return 422):**\n- `criteria`: must be `https://tiplu.de/fhir/maia/SubscriptionTopic/maia-alert-accepted`\n- `channel.type`: only `rest-hook` is supported\n- `channel.payload`: must be `application/fhir+json`\n- `channel.endpoint`: must be an absolute URI with scheme `http` or `https`\n\n**Server-managed fields (client-supplied values are silently ignored):**\n- `status`: set to `requested` on creation; transitions to `active` after successful handshake, or `error` on failure\n- `channel.payloadContent`: always `full-resource`\n- `end`: subscription expiry is not supported; the field is accepted but ignored\n\n**Security note:** `channel.header` is write-only — accepted on create/update but masked on read to prevent token disclosure.",
          "interaction": [
            {
              "extension": [
                {
                  "url": "http://hl7.org/fhir/StructureDefinition/capabilitystatement-expectation",
                  "valueCode": "SHALL"
                }
              ],
              "code": "create"
            },
            {
              "extension": [
                {
                  "url": "http://hl7.org/fhir/StructureDefinition/capabilitystatement-expectation",
                  "valueCode": "SHALL"
                }
              ],
              "code": "read"
            },
            {
              "extension": [
                {
                  "url": "http://hl7.org/fhir/StructureDefinition/capabilitystatement-expectation",
                  "valueCode": "SHALL"
                }
              ],
              "code": "update"
            },
            {
              "extension": [
                {
                  "url": "http://hl7.org/fhir/StructureDefinition/capabilitystatement-expectation",
                  "valueCode": "SHALL"
                }
              ],
              "code": "delete"
            },
            {
              "extension": [
                {
                  "url": "http://hl7.org/fhir/StructureDefinition/capabilitystatement-expectation",
                  "valueCode": "SHALL"
                }
              ],
              "code": "search-type"
            }
          ]
        }
      ]
    }
  ]
}