PrimaryConnectClient - the Ruby gem for the Primary Connect API V1
Client Library to interface with Primary Connect
This SDK is automatically generated by the OpenAPI Generator project:
- API version: v1
- Package version: 1.12.0
- Build package: org.openapitools.codegen.languages.RubyClientCodegen
To build the Ruby code into a gem:
gem build primary_connect_client.gemspec
Then either install the gem locally:
gem install ./primary_connect_client-1.12.0.gem
(for development, run gem install --dev ./primary_connect_client-1.12.0.gem
to install the development dependencies)
or publish the gem to a gem hosting service, e.g. RubyGems.
Finally add this to the Gemfile:
gem 'primary_connect_client', '~> 1.12.0'
If the Ruby gem is hosted at a git repository: https://github.com/PrimaryDotHealth/connect-ruby-client, then add the following in the Gemfile:
gem 'primary_connect_client', :git => 'https://github.com/PrimaryDotHealth/connect-ruby-client.git'
Include the Ruby code directly using -I
as follows:
ruby -Ilib script.rb
Please follow the installation procedure and then run the following code:
# Load the gem
require 'primary_connect_client'
# Setup authorization
PrimaryConnectClient.configure do |config|
# Configure Bearer authorization: bearer_auth
config.access_token = 'YOUR_BEARER_TOKEN'
end
api_instance = PrimaryConnectClient::DefaultApi.new
id = '01FGD44Q6MVCG2VNSMC4ZMOTQM' # String | Order ID
opts = {
accession: PrimaryConnectClient::Accession.new # Accession |
}
begin
#accession order by ULID
api_instance.accession_order(id, opts)
rescue PrimaryConnectClient::ApiError => e
puts "Exception when calling DefaultApi->accession_order: #{e}"
end
All URIs are relative to https://connect.primary.health
Class | Method | HTTP request | Description |
---|---|---|---|
PrimaryConnectClient::DefaultApi | accession_order | PUT /api/v1/orders/{id}/accession | accession order by ULID |
PrimaryConnectClient::DefaultApi | accession_order_by_specimen_id | PUT /api/v1/orders/accession | accession order by Specimen ID |
PrimaryConnectClient::DefaultApi | cancel_order | DELETE /api/v1/orders/{id} | cancel order |
PrimaryConnectClient::DefaultApi | create_measurement | POST /api/v1/measurements | create Measurement |
PrimaryConnectClient::DefaultApi | create_order | POST /api/v1/orders | create order |
PrimaryConnectClient::DefaultApi | create_result | POST /api/v1/orders/{order_id}/results | create result |
PrimaryConnectClient::DefaultApi | get_lab_report | GET /api/v1/results/{result_id}/lab_report | show lab report |
PrimaryConnectClient::DefaultApi | get_measurement | GET /api/v1/measurements/{id} | show measurement |
PrimaryConnectClient::DefaultApi | get_order | GET /api/v1/orders/{id} | show order |
PrimaryConnectClient::DefaultApi | list_events | GET /api/v1/events | list events |
PrimaryConnectClient::DefaultApi | list_orders | GET /api/v1/orders | list orders |
PrimaryConnectClient::DefaultApi | list_results | GET /api/v1/orders/{order_id}/results | list results |
PrimaryConnectClient::DefaultApi | reroute_order | POST /api/v1/orders/reroute | reroute Order identified in the payload |
PrimaryConnectClient::DefaultApi | reroute_order_by_ulid | POST /api/v1/orders/{id}/reroute | Reroute order by ULID |
PrimaryConnectClient::DefaultApi | update_order | PUT /api/v1/orders/{id} | update order |
- PrimaryConnectClient::Accession
- PrimaryConnectClient::AccessionOrder
- PrimaryConnectClient::Address
- PrimaryConnectClient::CodedValue
- PrimaryConnectClient::Demographics
- PrimaryConnectClient::Device
- PrimaryConnectClient::Dosage
- PrimaryConnectClient::Error
- PrimaryConnectClient::Event
- PrimaryConnectClient::Events
- PrimaryConnectClient::Identifier
- PrimaryConnectClient::Ids
- PrimaryConnectClient::Location
- PrimaryConnectClient::Measurement
- PrimaryConnectClient::Medication
- PrimaryConnectClient::MedicationAdministration
- PrimaryConnectClient::Meta
- PrimaryConnectClient::MetaDestination
- PrimaryConnectClient::MetaDestinations
- PrimaryConnectClient::MetaMessage
- PrimaryConnectClient::MetaProvenances
- PrimaryConnectClient::MetaSource
- PrimaryConnectClient::MetaTransmission
- PrimaryConnectClient::Name
- PrimaryConnectClient::Order
- PrimaryConnectClient::OrderIds
- PrimaryConnectClient::OrderOrder
- PrimaryConnectClient::OrderOrderClinicalInfo
- PrimaryConnectClient::OrderOrderDiagnoses
- PrimaryConnectClient::OrderOrderOrderingFacility
- PrimaryConnectClient::OrderPatient
- PrimaryConnectClient::OrderPatientContacts
- PrimaryConnectClient::OrderWithEventErrors
- PrimaryConnectClient::Orders
- PrimaryConnectClient::OrdersOrders
- PrimaryConnectClient::Patient
- PrimaryConnectClient::PhoneNumber
- PrimaryConnectClient::Provider
- PrimaryConnectClient::Result
- PrimaryConnectClient::ResultIds
- PrimaryConnectClient::ResultReferenceRange
- PrimaryConnectClient::ResultReport
- PrimaryConnectClient::Results
- PrimaryConnectClient::Specimen
- PrimaryConnectClient::Subject
- PrimaryConnectClient::V2Device
- PrimaryConnectClient::V2Dosage
- PrimaryConnectClient::V2Medication
- PrimaryConnectClient::V2MedicationAdministration
- PrimaryConnectClient::Visit
- PrimaryConnectClient::VisitCompany
- PrimaryConnectClient::VisitGuarantor
- PrimaryConnectClient::VisitGuarantorEmployer
- PrimaryConnectClient::VisitInsurances
- PrimaryConnectClient::VisitInsured
- PrimaryConnectClient::VisitPlan
- Type: Bearer authentication