delete
Remove a single FHIR resource by logical ID or conditional search parameters, or run a named FHIR operation such as $expunge and return an OperationOutcome.
Instructions
Execute a FHIR delete interaction on a specific resource instance. Use this tool when you need to remove a single resource identified by its logical ID or optionally filtered by search parameters. The optional id parameter must match an existing resource instance when present. If you include searchParam, the server will perform a conditional delete, deleting the resource only if it matches the given criteria. If you supply operation, it will execute the named FHIR operation (e.g., $expunge) on the resource. This tool returns a FHIR OperationOutcome describing success or failure of the deletion.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"type": "<type>"
},
"name": "delete"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| id | No | The logical ID of a specific FHIR resource instance. | |
| type | Yes | The FHIR resource type name. Must exactly match one of the resource types supported by the server. | |
| operation | No | The name of a custom FHIR operation or extended query defined for the resourceMust match one of the operation names returned by `get_capabilities`. | |
| searchParam | No | A mapping of FHIR search parameter names to their desired values. These parameters refine queries for operation-specific query qualifiers. Only parameters exposed by `get_capabilities` for that resource type are valid. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes | A dictionary containing the confirmation of deletion or details on why deletion failed. |