Class: Api::V2::SampleMetadataResource
- Inherits:
-
BaseResource
- Object
- JSONAPI::Resource
- BaseResource
- Api::V2::SampleMetadataResource
- Defined in:
- app/resources/api/v2/sample_metadata_resource.rb
Overview
Access this resource via the /api/v2/sample_metadata/
endpoint.
Provides a JSON:API representation of Sample::Metadata which contains additional metadata related to a Sample.
A Sample represents the life of a DNA/RNA sample as it moves through processes. It may exist in multiple receptacles as aliquots. Sample tracks aspects that are always true, like its origin.
For more information about JSON:API see the JSON:API Specifications or look at the JSONAPI::Resources package for Sequencescape's implementation of the JSON:API standard.
Instance Attribute Summary collapse
-
#cohort ⇒ String
The cohort to which the sample belongs.
-
#collected_by ⇒ String
The name of the organization or person that collected the sample.
-
#concentration ⇒ String
The concentration of the sample, typically measured in ng/µL.
-
#donor_id ⇒ String
The unique identifier assigned to the sample donor.
-
#gender ⇒ String
The gender of the organism providing the sample (e.g., Male, Female, Unknown).
-
#sample_common_name ⇒ String
The common name of the organism from which the sample was derived (e.g., Homo sapiens).
-
#sample_description ⇒ String
A textual description of the sample.
-
#supplier_name ⇒ String
The name of the supplier that provided the sample.
-
#volume ⇒ String
The volume of the sample, typically measured in µL.
Instance Method Summary collapse
-
#filter_sample_id(value) ⇒ SampleMetadataResource
Filters sample metadata by
sample_id
, allowing users to retrieve metadata for a specific sample.
Methods inherited from BaseResource
apply_includes, creatable_fields, default_includes, #fetchable_fields, inclusions, resolve_relationship_names_to_relations, updatable_fields
Instance Attribute Details
#cohort ⇒ String
Returns The cohort to which the sample belongs.
56 |
# File 'app/resources/api/v2/sample_metadata_resource.rb', line 56 attribute :cohort |
#collected_by ⇒ String
Returns The name of the organization or person that collected the sample.
60 |
# File 'app/resources/api/v2/sample_metadata_resource.rb', line 60 attribute :collected_by |
#concentration ⇒ String
Returns The concentration of the sample, typically measured in ng/µL.
64 |
# File 'app/resources/api/v2/sample_metadata_resource.rb', line 64 attribute :concentration |
#donor_id ⇒ String
Returns The unique identifier assigned to the sample donor.
68 |
# File 'app/resources/api/v2/sample_metadata_resource.rb', line 68 attribute :donor_id |
#gender ⇒ String
Returns The gender of the organism providing the sample (e.g., Male, Female, Unknown).
72 |
# File 'app/resources/api/v2/sample_metadata_resource.rb', line 72 attribute :gender |
#sample_common_name ⇒ String
Returns The common name of the organism from which the sample was derived (e.g., Homo sapiens).
76 |
# File 'app/resources/api/v2/sample_metadata_resource.rb', line 76 attribute :sample_common_name |
#sample_description ⇒ String
Returns A textual description of the sample.
80 |
# File 'app/resources/api/v2/sample_metadata_resource.rb', line 80 attribute :sample_description |
#supplier_name ⇒ String
Returns The name of the supplier that provided the sample.
84 |
# File 'app/resources/api/v2/sample_metadata_resource.rb', line 84 attribute :supplier_name |
#volume ⇒ String
Returns The volume of the sample, typically measured in µL.
88 |
# File 'app/resources/api/v2/sample_metadata_resource.rb', line 88 attribute :volume |
Instance Method Details
#filter_sample_id(value) ⇒ SampleMetadataResource
Filters sample metadata by sample_id
, allowing users to retrieve metadata for a specific sample.
102 |
# File 'app/resources/api/v2/sample_metadata_resource.rb', line 102 filter :sample_id |