Not able to apply PlanDefinition, getting error
# support
n
I'm trying to apply a PlanDefinition to a Practitionnaire, but I'm encountering an error that says, "Expected an array for the 'input' property." Please see the attached image of the network log for reference.
r
Hi @nikulkhatik - are you in a position to share the
PlanDefinition
resource, as well as the HTTP call you are making to invoke the $apply operation?
To help debug, it would be great to see the kind of input you're sending. Typically, it would be a
Parameters
resource
Copy code
{
            resourceType: 'Parameters',
            parameter: [
              {
                name: 'subject',
                valueReference: subject,
              },
            ],
          }
n
r
Hi @nikulkhatik - I'm in the process of trying to reproduce your issue, but havne't been able to jsut yet. Would you mind pasting the JSON code for your specific PlanDefinition resource?
n
Copy code
{
  "resourceType": "PlanDefinition",
  "status": "active",
  "type": {
    "coding": [
      {
        "system": "http://hl7.org/fhir/uv/order-catalog/CodeSystem/laboratory-service-definition-type",
        "code": "panel",
        "display": "collection of tests and panels performed on one or more in vitro biologic specimens"
      }
    ]
  },
  "identifier": [
    {
      "use": "official",
      "value": "NLX-SD-2"
    }
  ],
  "name": "respiratory-panel-at-home",
  "title": "Respiratory Panel (at-home)",
  "action": [
    {
      "code": [
        {
          "coding": [
            {
              "system": "http://loinc.org",
              "code": "94500-6",
              "display": "Syndromic Multiplex Respiratory Pathogen"
            }
          ]
        }
      ],
      "definitionCanonical": "ActivityDefinition/60a6c169-a602-4ed6-a31e-44a00509554a",
      "output": [
        {
          "title": "Influenza A virus (InfA)",
          "requirement": {
            "type": "ObservationDefinition",
            "subjectReference": "ObservationDefinition/0a27d155-8ba6-4f96-8c8e-ce6558f7b18e"
          }
        }
      ]
    }
  ],
  "useContext": [
    {
      "code": {
        "system": "http://terminology.hl7.org/CodeSystem/usage-context-type",
        "code": "task"
      },
      "valueCodeableConcept": {
        "coding": [
          {
            "system": "http://terminology.hl7.org/CodeSystem/v3-ActCode",
            "code": "LABOE",
            "display": "laboratory test order entry task"
          }
        ]
      }
    }
  ],
  "id": "39ac16f8-bcf1-4023-ba96-a067ed1e0ac1",
  "meta": {
    "versionId": "ccf4ee49-360b-43b7-a3f9-b9a300e9a58b",
    "lastUpdated": "2023-09-21T13:03:18.562Z",
    "author": {
      "reference": "Practitioner/a4f10746-0a8d-4bbf-a6cc-4bac4e1b99eb",
      "display": "IT TC"
    },
    "project": "3cbc17ca-4769-4f34-8503-891940152dcf",
    "compartment": [
      {
        "reference": "Project/3cbc17ca-4769-4f34-8503-891940152dcf"
      }
    ]
  }
}
r
hi @nikulkhatik , I realize we never completed this conversation this. Were you able to resolve this on your end?
n
@rahul1, I am not able to resolve this as I have got another priorities
155 Views