Patient user getting 403 on CondingInput (gender, ...
# support
o
Last I checked, a practitioner logging in works, but mabe its broken now too after massive changes. Either way, when I log in as a user (medplumProfile works, so it is authed), I get 403. Here is an example component <CodingInput binding="http://hl7.org/fhir/ValueSet/icd-10" name="icd10" path="" placeholder="Search for ICD-10 codes..." /> I added this to the default patient access policy (per chatGpt's attempt to fix the 403) { "resourceType": "ValueSet" }
Just confirmed that it is something wrong with my access policy. As soon as I remove the access policy from the user, all the valueSets load in the CodinInputs. Here us the "resource" part of the policy "resource": [ { "resourceType": "Patient", "criteria": "Patient?_compartment=%patient" }, { "resourceType": "Observation", "criteria": "Observation?_compartment=%patient" }, { "resourceType": "DiagnosticReport", "criteria": "DiagnosticReport?_compartment=%patient" }, { "resourceType": "MedicationRequest", "criteria": "MedicationRequest?_compartment=%patient" }, { "resourceType": "Coverage", "criteria": "Coverage?_compartment=%patient" }, { "resourceType": "PaymentNotice", "criteria": "PaymentNotice?_compartment=%patient" }, { "resourceType": "CarePlan", "criteria": "CarePlan?_compartment=%patient" }, { "resourceType": "Immunization", "criteria": "Immunization?_compartment=%patient" }, { "resourceType": "Communication", "criteria": "Communication?_compartment=%patient" }, { "resourceType": "Organization", "readonly": true }, { "resourceType": "Practitioner", "readonly": true }, { "resourceType": "Schedule", "readonly": true }, { "resourceType": "Slot", "readonly": true }, { "resourceType": "Binary" }, { "resourceType": "ValueSet", "criteria": "ValueSet?url=*" }, { "resourceType": "CodeSystem", "criteria": "CodeSystem?url=*" } ],
i
Let us know if you need any additional assistance
o
To clarify, I am still having the issue when using this policy i posted
i
Can you share the full policy and a resource it applies to?
o
Here is the full patient access policy (minus the "resource" since it exceeds the char limit of discord. I pasted the resource above previously. { "resourceType": "AccessPolicy", "name": "Patient Access Policy Template", "id": "0198059f-af2b-7753-a088-9b09a80209e2", "compartment": { "reference": "%patient" }, "resource": [] "meta": { "project": "019682e4-6764-77be-9f1b-142f86ab2b28", "compartment": [ { "reference": "Project/019682e4-6764-77be-9f1b-142f86ab2b28" } ], "versionId": "01982578-c93e-717a-87f2-385be0fba19e", "lastUpdated": "2025-07-20T01:35:29.598Z", "author": { "reference": "Practitioner/01981e87-e192-73fb-88e8-03f891cb80bb", "display": "dev" } } }
Then I try to use a codingInput like so <CodingInput binding="http://hl7.org/fhir/ValueSet/icd-10" name="icd10" path="" placeholder="Search for ICD-10 codes..." /> This works when I disable the access policy on the user, but doesnt work with the access policy enabled
i
@oscadev is there any reason you added
"criteria": "CodeSystem?url="
and
"criteria": "ValueSet?url="
? If you remove those lines you should be able to get results from your CodingInput
o
that was from chatgpt. Thanks, that works
150 Views