fhir_rest_client 0.0.4 copy "fhir_rest_client: ^0.0.4" to clipboard
fhir_rest_client: ^0.0.4 copied to clipboard

A Dart package to describe FHIR REST calls and corresponding client to send these requests to a FHIR server

example/lib/example.dart

import 'package:dio/dio.dart';
import 'package:fhir_rest_client/fhir_rest_client.dart';

Future<void> main() async {
  final fhirRestclient = FhirRestClient(
    dio: Dio(
      BaseOptions(
        connectTimeout: const Duration(milliseconds: 30000),
        receiveTimeout: const Duration(milliseconds: 30000),
        headers: {
          'Authorization': 'Bearer MYTOKEN',
        },
      ),
    ),
    baseUrl: Uri.parse('https://myfhirrestserver.com'),
  );

  final patients = await fhirRestclient.execute(
    request: FhirRequest(
      operation: FhirRequestOperation.search,
      entityName: 'Patient',
    ),
  );

  print(patients);
}
1
likes
150
points
1.25k
downloads

Publisher

verified publisherevoleen.com

Weekly Downloads

A Dart package to describe FHIR REST calls and corresponding client to send these requests to a FHIR server

Homepage
Repository (GitHub)
View/report issues

Documentation

API reference

License

BSD-3-Clause (license)

Dependencies

dio, fhir_r4, freezed_annotation, json_annotation

More

Packages that depend on fhir_rest_client