Skip to content

Request for clearer examples and improved types for FHIR search in @googleapis/healthcare library #3549

@mohsinht

Description

@mohsinht

Is your feature request related to a problem? Please describe.

I’m trying to search the FHIR store using the @googleapis/healthcare library, specifically the projects.locations.datasets.fhirStores.fhir.search method, but I have encountered several issues:

  1. The documentation and examples are very vague, particularly for performing search queries using GET and POST.
  2. The query structure I’m trying to use, for example: Observation?combo-code=mysite.com|bmi&subject=Patient/some-id, does not seem to fit easily within the current structure of the @googleapis/healthcare search method.
  3. The search method parameters and types are not clearly defined or typed within the library, leading to confusion and difficulty in usage.

Describe the solution you'd like

I would like clearer examples and documentation for using the search method, specifically with both GET and POST requests. It would be helpful to show how to handle FHIR query strings such as Observation?combo-code=mysite.com|bmi&subject=Patient/some-id in the @googleapis/healthcare library. Additionally, proper TypeScript typings for these search parameters would greatly improve the developer experience.

Describe alternatives you've considered

I have considered bypassing the library and making direct HTTP requests with the Google Auth library, but that adds complexity and seems like an unnecessary workaround.

Additional context

The StackOverflow community also has threads discussing the vague types and lack of clarity around using the search method. More detailed samples and clearer type definitions would go a long way in making the library more accessible and easier to use.

Metadata

Metadata

Assignees

No one assigned

    Labels

    priority: p3Desirable enhancement or fix. May not be included in next release.type: feature request‘Nice-to-have’ improvement, new feature or different behavior or design.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions