Closed LindaLawton closed 2 years ago
So PUT to https://care-gateway.test001.ehealth.sundhed.dk/fhir/Bundle/[id] And use the same [id] inside the bundle
If you check care gateway Page
The example shows HTTP Post is there any reason we can not continue to use the HTTP Post method we have been using since the beginning? To be clear we have been using the HTTP Post endpoint since July 2021 why the sudden change?
My issues with the id inside the bundle is that the system does not respect that id. The bundle Id we send is not the bundle ide that is returned in the response.
Yes, that was the picture until the decision was taken to use client-assigned ids. That is illegal for POST requests - so PUT is required (see https://www.hl7.org/fhir/http.html#create)
Could you emphasize on your last comment? Which system do you refer to?
Thanks for pointing out the documentation error - I have corrected it now
We have been testing the connection to KL gateway since June. Using this end point. With a HTTP Post request as we were instructed.
"KlGateway": { "Hostname": "https://kl-gateway-testserver.azurewebsites.net", "Path": "/fhir/Bundle?_format=json&_pretty=true",
Then late January 2022 the endpoint was shutdown and we were told to use
"Hostname": "https://care-gateway.test001.ehealth.sundhed.dk",
"Path": "/fhir/Bundle?_format=json&_pretty=true",
At that time my team member Mikael asked on Zulip if we would still be able to use the Post endpoint sending the full report as we have been for the last nine months. We had noted that we could not find it mentioned of the Post method Endpoint in the care gateway page. I believe he was told by Torben that this was not a problem and we could continue to do things has we have been.
My concern is that we are almost 10 months into the development process and the endpoint has changed. I am not accustom to specs changing this late in the development life cycle. I'm curious as to why we were not informed about this sooner. I am also worried the model has changed as well. We have serval months of extensive testing already complete using the POST endpoint we now need to redo that testing with the PUT endpoint
@LindaLawton we dont make picture perfect specs. Noone does that. In collaboration with @tmh-mjolner (responsible for the FHIR IG's that define the data model) we found that the suggested pattern with using POST would violate the standard - and it does. We found this bug back in late November. Why it wasn't announced I cannot say. Anyways, you need to use PUT as specified. Without knowing anything about your codebase I cannot imagine that this will be a change of paramount proportions, being a change from POST to PUT, but I could of course be wrong.
@jkiddo I completely understand the need for changes they are part of the development process. That being said when implementing obvious breaking changes its accepted practice to announce them before they are implemented. This makes it possible for developers using your system to spec it into their process.
You broke my system with no warning. That is what i am objecting to. Not that you changed something.
I agree. Keeping the POST option open would however break the standard, break business rules and cause all kinds of pain. You should have been notified back in November. It was a mistake that you weren't.
@LindaLawton I can see that your colleague also found out Feb 16. that PUT is what is supported from https://chat.fhir.org/#narrow/stream/274483-denmark.2Fkl.2Fprofile.2Fkl-gateway/topic/When.20changes.20to.20a.20citizen.2FDeliveryReport.2E.20Should.20we.20update.20a
I don't have access to that forum so cant really comment on what was posted there.
Its an open forum
Wait a minute ... it looks like @tmh-mjolner put a lock on it. @tmh-mjolner would you please open it up?
I think I have authorization working but when I try to send requests to the new endpoint. I am getting an error.
I was told that this is the new endpoint
https://care-gateway.test001.ehealth.sundhed.dk/fhir
I assume that the endpoint to post the bundle to would then behttps://care-gateway.test001.ehealth.sundhed.dk/fhir/Bundle
If I don't send an access token I get the following, as I would expect since I am not authorized.
Request attempt 1 (sanity check)
Sending to just the basic endpoint with an access token. results in an error as i am not sending an operation name that being bundle.
https://care-gateway.test001.ehealth.sundhed.dk/fhir
request attempt two
So i tried sending the request to the bundle endpoint.
The error message i am getting confuses me. This is a Http post request with the json body of the bundle i am trying to post. This is the exact same post that i made to the old endpoint. Why would it be looking for Http parameters? The old endpoint supported ?_format=json&_pretty=true query parms but this endpoint doesn't appear to support them.
update attempt 3
Tried adding the bundle Id. I am just guessing at this point I cant find anything about parameters for the Post request in the documentation Care Gateway
{ "resourceType": "OperationOutcome", "issue": [ { "severity": "error", "code": "not-supported", "diagnostics": "Invalid request: The FHIR endpoint on this server does not know how to handle POST operation[Bundle] with parameters [[id]]" } ] }
Post body sending for both requests is