openEHR Postman workspace

This public postman workspace is super useful!!

I think this deserves more attention and promotion in the community. It’s another example of lowering the barrier of entry.
I think we could add it to the ITS REST API spec. And potentially to the ehrbase documentation and or github readme.

I did encounter some issues though.

  1. the first run of the api gave an error: There was an error in evaluating the Pre-request Script:Error: Cannot find package '@freshehr/openehr-shim', I disabled (commented out) the script. Which fixed the issue, but I don’t know the downsides.
  2. a set of environment variable is required. I couldn’t find a way to import/set the environment, it doesn’t
  3. the create ehr calls fail: { “error”: “Bad Request”, “message”: “Subject’s namespace format invalid”}, disabling the api’s preprocess script solves this
  4. multiple ehrscap calls fail (non succeeded) with error 401 unauthorized. enabling the authorization environment variable didn’t help. ehrbase console didn’t show a log.

An import of your collection and environment with my changes is available at: Postman

3 Likes

With the kind help of @ian.mcnicoll most of this is now fixed.

  1. the script’s been moved to NPM which makes it accessible to public workspaces too.
  2. environment is provided as part of the workspace.
  3. fixed by removing ‘.’ and ‘_’ from the subject namespace, apparently unsupported by ehrbase?
  4. got this mostly working on my private workspace. I plan to merge upstream once it’s stable.

underscore is supported but . is not .

This is a log-standing known issue @birger.haarbrandt can we get it fixed? It is due to an error in the regex , originally copied from an error in the spec which has since been corrected.

and thanks for picking this up @joost - further suggestions very welcome

Maybe this helps a little to progress this: update subject namespace regex by joostholslag · Pull Request #1498 · ehrbase/ehrbase · GitHub

2 Likes