{
:bananomia => {
description: "Wrapper for Bionomia API - access specimen and collection records",
api: "https://bionomia.net",
endpoints: {
:parse => {
description: "Parse human names",
params: {
:names => "Human name(s) separated by \\r\\n",
:verbose => "Print headers to STDOUT",
},
examples: [
"Bananomia.parse('Henry Robert Nicollon des Abbayes; Groom Q\\r\\nMrs. John Errol Chandos Aberdeen')",
"Date.parse(search_date)",
"Date.parse(r['item']['birthDate'])",
],
},
:person => {
description: "Get a person's profile by ID or specimens",
params: {
:id => "An ORCID or WikiData identifier",
:specimens => "Get the person's specimens",
:csv => "For specimens, whether to return a csv",
:page => "Pagination for the results list",
:verbose => "Print headers to STDOUT",
},
examples: [
"Bananomia.person('0000-0001-7618-5230')",
"Bananomia.person('0000-0001-7618-5230', specimens: true)",
"Bananomia.person('0000-0001-7618-5230', specimens: true, csv: true)",
],
},
:occurrence => {
description: "Get and occurrence record",
params: {
:id => "An occurence ID from Global Biodiversity Information Facility",
:verbose => "Print headers to STDOUT",
},
examples: [
"Bananomia.occurrence('477976412')",
],
},
:search_people => {
description: "Search human names",
params: {
:q => "A single human name",
:families_collected => "Comma-separated list of taxonomic families collected",
:families_identified => "Comma-separated list of taxonomic families identified",
:date => "Filters to alive during date (format: YYYY-MM-DD, YYYY-MM, or YYYY) e.g., Captain John Smith was alive from 1580-01-01 through 1631-06-21, so setting date to any value between their birth/death date will include Captain John in the search results Warning: Setting exactly equal to a person's birthdate, excludes them from search!",
:strict => "Must include vs should include on families_identified, families_collected, date",
:callback => "A string to produce a JSONP response instead of a JSON-LD response",
:page => "Pagination for the results list",
:verbose => "Print headers to STDOUT",
},
examples: [
"Bananomia.search_people('smith', families_collected: 'scarabaeidae', strict: true)",
"Bananomia.search_people('Thomas McElrath', families_collected: 'Acholeplasmataceae', strict: true)",
"Bananomia.search_people('Thomas McElrath', families_identified: 'Acholeplasmataceae', strict: true)",
],
},
:search_occurrences => {
description: "Search occurrences",
params: {
:dataset_id => "a registered dataset UUID provided by the Global Biodiversity Information Facility",
:occurrence_id => "identifier from the data provider",
:callback => "A string to produce a JSONP response instead of a JSON-LD response",
:page => "Pagination for the results list",
:verbose => "Print headers to STDOUT",
},
examples: [],
},
:suggest => {
description: "Suggest human names (autocomplete widget)",
params: {
:q => "Part of a human name",
:is_public => "Filters results to public profiles",
:has_occurrences => "Filters results to profiles with occurrences",
:limit => "The number of results to return",
:verbose => "Print headers to STDOUT",
},
examples: [
"Bananomia.suggest('anning')",
],
},
},
},
:bell_pepper => {
description: "Wrapper for BELS API - georeference locality descriptions via the Biodiversity Enhanced Location Services",
api: "https://bels.geo-vocab.org/",
endpoints: {
:bestgeoref => {
description: "Get a georeference",
params: {
:id => "an optional identifier that will be returned with the result",
:city => "The city",
:continent => "The name of the continent in which the Location occurs",
:county => "The full, unabbreviated name of the next smaller administrative region than stateProvince (county, shire, department, etc.) in which the Location occurs",
:country => "The name of the country or major administrative unit in which the Location occurs",
:country_code => "The ISO 3166-1-alpha-2 code for the country in which the Location occurs",
:give_me => "The type of georeference match (BEST_GEOREF)",
:locality => "The specific description of the place",
:state_province => "The name of the next smaller administrative region than country (state, province, canton, department, region, etc.) in which the Location occurs",
},
examples: [],
},
},
},
:bok_choy => {
description: "Wrapper for BHL API - access biodiversity heritage library data",
api: "https://www.biodiversitylibrary.org/api",
endpoints: {
:name_refs => {
description: "Finds BHL references for a name",
params: {
:name => "A canonical scientific name (e.g., Pardosa moesta)",
:author => "An author string (e.g., Banks)",
:year => "A year string (e.g., 1892)",
:reference => "A reference string (e.g., Docums Mycol. 34(nos 135-136))",
:nomen_event => "If true, tries to find nomenclatural event reference (default: true)",
:json => "An optional JSON hash of name and reference data (overrides all other parameters)",
:verbose => "Print headers to STDOUT",
},
examples: [
"Choy.name_refs(name: 'Cyphoderris strepitans', nomen_event: true)",
],
},
:cached_refs => {
description: "Finds a nomenclatural event in BHL by an external ID from a data source",
params: {
:id => "An external ID from a data source",
:verbose => "Print headers to STDOUT",
},
examples: [
"Choy.cached_refs('6C8Q2')",
],
},
:items_page_nums => {
description: "Get a page by item ID and page number",
params: {
:item_id => "A BHL item ID",
:page_num => "A BHL page number",
:verbose => "Print headers to STDOUT",
},
examples: [
"Choy.items_page_nums(item_id: 15402, page_num: 183)",
],
},
:items => {
description: "Get metadata and taxonomic statistics for a BHL item",
params: {
:id => "A BHL item ID",
:verbose => "Print headers to STDOUT",
},
examples: [
"Choy.items(73397)",
"items(taxon_name: 'Lepidoptera')",
],
},
:page => {
description: "Get BHL reference metadata by page ID",
params: {
:id => "A page ID from BHL",
:verbose => "Print headers to STDOUT",
},
examples: [
"Choy.page(6589171)",
],
},
:taxon_items => {
description: "Finds BHL items in which a given higher taxon is prevalent",
params: {
:taxon_name => "A taxonomic name (e.g., Lepidoptera)",
:verbose => "Print headers to STDOUT",
},
examples: [
"Choy.taxon_items(taxon_name: 'Lepidoptera')",
],
},
:references => {
description: "Gets BHL reference metadata by page ID",
params: {
:id => "A page ID from BHL",
:verbose => "Print headers to STDOUT",
},
examples: [
"Choy.references(6589171)",
],
},
:ping => {
description: "Check the API status",
params: {
:verbose => "Print headers to STDOUT",
},
examples: [],
},
:version => {
description: "Check the API version",
params: {
:verbose => "Print headers to STDOUT",
},
examples: [],
},
},
},
:checkerberry => {
description: "Wrapper for GNverifier API - verify and search scientific names across curated databases",
api: "https://verifier.globalnames.org",
endpoints: {
:verify => {
description: "Verify scientific names",
params: {
:names => "A single name or array of names to verify",
:data_sources => "The data source IDs to use for verification",
:vernacular_languages => "A single language ISO 639-3 or an array of ISO 639-3 languages for vernacular names",
:with_all_matches => "Show all matches for each name",
:with_capitalization => "Capitalize the first character",
:with_species_group => "Match to species group",
:with_uninomial_fuzzy_match => "Enable uninomial fuzzy matching",
:with_stats => "Include statistics in response",
:min_taxon_threshold => "The minimum taxon threshold for main taxon assignment",
:verbose => "Print headers to STDOUT",
},
examples: [
"Checkerberry.verify('Homo sapiens')",
"Checkerberry.verify(['Homo sapiens', 'Mus musculus'])",
"Checkerberry.verify('Homo sapiens', data_sources: 1)",
],
},
:search => {
description: "Search for scientific names",
params: {
:query => "The search query",
:data_sources => "The data source IDs to use for verification",
:parent_taxon => "The parent taxon name",
:name_string => "The exact name string to search for",
:genus => "The genus name",
:species => "The species name",
:species_any => "Any part of the species name",
:infraspecies => "The infraspecies name",
:author => "The author name",
:year => "The year of publication",
:year_start => "The start year for a range search",
:year_end => "The end year for a range search",
:with_all_results => "Show all matches for each name",
},
examples: [
"Checkerberry.search(name_string: \"Homo sapiens\", genus: 'Homo', species: 'sapiens')",
"Checkerberry.search(parent_taxon: \"Plantae\", genus: 'Homo', species: 'sapiens')",
"Checkerberry.search(parent_taxon: \"Animalia\", genus: 'Homo', species: 'sapiens')",
],
},
:data_sources => {
description: "Get list of data sources",
params: {
:verbose => "Print headers to STDOUT",
},
examples: [],
},
:data_source => {
description: "Get a single data source by ID",
params: {
:source_id => "The data source ID",
:verbose => "Print headers to STDOUT",
},
examples: [
"Checkerberry.data_source(1)",
],
},
:ping => {
description: "Ping the API (check if the service is alive)",
params: {
:verbose => "Print headers to STDOUT",
},
examples: [],
},
:version => {
description: "Get version information",
params: {
:verbose => "Print headers to STDOUT",
},
examples: [],
},
},
},
:colrapi => {
description: "Wrapper for Catalogue of Life (ChecklistBank) API - access global taxonomic checklists and name data",
api: "https://www.checklistbank.org/api",
endpoints: {
:assembly => {
description: "Get assembly status",
params: {
:dataset_id => "The dataset id",
},
examples: [
"Colrapi.assembly('3')",
],
},
:archive => {
description: "Get a dataset's original archive",
params: {
:dataset_id => "The dataset id",
:attempt => "Returns archive for a past import attempt number",
},
examples: [
"Colrapi.archive('36223', attempt: 71)",
],
},
:dataset => {
description: "Get dataset metadata",
params: {},
examples: [
"Colrapi.dataset(dataset_id: @dataset_id)",
"Colrapi.dataset(dataset_id: '1027', attempt: 100)",
"Colrapi.dataset(offset: 2848, limit: 6)",
],
},
:decision => {
description: "Get project decisions",
params: {
:dataset_id => "The dataset id",
:decision_id => "The decision id",
:name => "The scientific name to match",
:rank => "The rank of the scientific name",
:modified_by => "Filter by a user id on last modified by",
:broken => "Whether the decision is broken or not",
:subject_dataset_id => "The source dataset id",
:mode => "The type of decision (block, reviewed, update, update_recursive, ignore)",
:subject => "TODO: what does this do? All decisions with subject=true are bare names, so maybe it checks if the subject taxon exists?",
:offset => "Offset for pagination",
:limit => "Limit for pagination",
:verbose => "Print headers to STDOUT",
},
examples: [
"Colrapi.decision(@dataset_id)",
"Colrapi.decision(@dataset_id, offset: 5, limit: 3)",
"Colrapi.decision(@dataset_id, rank: 'family')",
],
},
:duplicate => {
description: "Get duplicate names",
params: {
:dataset_id => "The dataset id",
:offset => "Offset for pagination",
:limit => "Limit for pagination",
:verbose => "Print headers to STDOUT",
},
examples: [
"Colrapi.duplicate(@dataset_id)",
],
},
:diff => {
description: "Get names diff between 2 datasets",
params: {
:dataset_id => "The first dataset id",
:dataset2_id => "The second dataset id",
:root_id => "The root taxon for the first dataset",
:root2_id => "The root taxon for the second dataset",
:min_rank => "The minimum taxonomic rank",
:authorship => "Include authorship",
:include_synonyms => "Include synonyms",
:include_parent => "Include parent",
:parent_rank => "Filter by parent rank",
:token => "An authentication token from Colrapi.user_login()",
:offset => "Offset for pagination",
:limit => "Limit for pagination",
:verbose => "Print headers to STDOUT",
},
examples: [
"Colrapi.diff(@dataset1_id, @dataset2_id, token: @token)",
],
},
:editor => {
description: "Get editor info",
params: {
:dataset_id => "The dataset id",
:token => "The authentication token from retrieved with Colrapi.user_login(user, password) # @return [Array, Hash, Boolean] An array of hashes",
},
examples: [
"Colrapi.editor(@dataset_id, 'a.b.c')",
"Colrapi.editor(@dataset_id, @token)",
],
},
:estimate => {
description: "Get estimates",
params: {
:dataset_id => "The dataset id",
:estimate_id => "The estimate ID",
:name => "The scientific name",
:rank => "taxonomic rank",
:modified_by => "Filter by a user id on last modified by",
:broken => "Whether the estimate is broken or not",
:min => "Filter by the minimum estimate",
:max => "Filter by the maximum estimate",
:offset => "Offset for pagination",
:limit => "Limit for pagination",
:verbose => "Print headers to STDOUT",
},
examples: [
"Colrapi.estimate(@dataset_id)",
"Colrapi.estimate(@dataset_id, offset: 7, limit: 3)",
"Colrapi.estimate(@dataset_id, estimate_id: 68)",
],
},
:export => {
description: "TODO: /dataset/{key}/export is covered, but /export and /export/{id} are not",
params: {
:dataset_id => "The dataset id",
:show_id => "TODO: not implemented because it doesn't seem to do anything?",
:verbose => "Print headers to STDOUT",
},
examples: [
"Colrapi.export('36223')",
],
},
:issues => {
description: "Get data quality issues",
params: {
:dataset_id => "The dataset id",
:issue => "Filter by data quality issue (e.g., ACCEPTED_NAME_MISSING, DUPLICATE_NAME, URL_INVALID)",
:mode => "Verbatim (default) or interpreted",
:offset => "Offset for pagination",
:limit => "Limit for pagination",
:verbose => "Print headers to STDOUT",
},
examples: [
"Colrapi.issues(@dataset_id)",
"Colrapi.issues(@dataset_id, issue: 'duplicate name')",
"Colrapi.issues(@dataset_id, issue: 'duplicate name', mode: 'interpreted')",
],
},
:importer => {
description: "Get importer status",
params: {
:dataset_id => "Calls the dataset_id endpoint /importer/{dataset_id}",
:dataset_id_filter => "Filters the importer queue by dataset_id",
:state => "The import status (e.g., waiting, preparing, downloading, processing, inserting, ...)",
:running => "Filter by actively importing datasets",
:offset => "Offset for pagination",
:limit => "Limit for pagination",
:verbose => "Print headers to STDOUT",
},
examples: [
"Colrapi.importer()",
"Colrapi.importer(dataset_id: '1148')",
"Colrapi.importer(running: false)",
],
},
:logo => {
description: "Get a dataset's logo",
params: {
:dataset_id => "The dataset id",
:size => "The size of the logo (original, large, medium, small)",
},
examples: [
"Colrapi.logo('9837')",
"Colrapi.logo('9837', size: 'original')",
"Colrapi.logo('9837', size: 'medium')",
],
},
:metrics => {
description: "Get metrics for the *last successful* import of a dataset or a specific import_attempt",
params: {
:dataset_id => "The dataset id",
:import_attempt => "The import attempt",
},
examples: [
"Colrapi.metrics('9837')",
"Colrapi.metrics('49590')",
"Colrapi.metrics(dataset_id)",
],
},
:name => {
description: "Get names or a name from a dataset",
params: {
:dataset_id => "The dataset id",
:name_id => "The name id",
:subresource => "The name subresource endpoint (relations, synonyms, types, or orphans)",
:offset => "Offset for pagination",
:limit => "Limit for pagination",
:verbose => "Print headers to STDOUT",
},
examples: [
"Colrapi.name(@dataset_id, name_id: @name_id)",
"Colrapi.name(@dataset_id, offset: 13383, limit: 1)",
"Colrapi.name(@dataset_id, name_id: '00000fe0-d4e6-4a74-8c99-b4ad127e7e64')",
],
},
:name_list => {
description: "Get a text list of names for a dataset",
params: {
:dataset_id => "The dataset id",
:import_attempt => "The import attempt number",
},
examples: [
"Colrapi.name_list(@dataset_id, import_attempt: @import_attempt)",
],
},
:name_tree => {
description: "Get a text tree of names for a dataset",
params: {
:dataset_id => "The dataset id",
:import_attempt => "The import attempt number",
},
examples: [
"Colrapi.name_tree(@dataset_id, import_attempt: @import_attempt)",
],
},
:nameusage => {
description: "Get name usages or a nameusage from a dataset",
params: {
:dataset_id => "The dataset id",
:nameusage_id => "The nameusage id",
:q => "The scientific name or authorship search query",
:rank => "The rank of the taxon in the search query q",
:nidx_id => "The name index id",
:subresource => "The name subresource endpoint (relations, synonyms, types, or orphans)",
:offset => "Offset for pagination",
:limit => "Limit for pagination",
:verbose => "Print headers to STDOUT",
},
examples: [
"Colrapi.nameusage(@dataset_id)",
"Colrapi.nameusage(@dataset_id, nameusage_id: '32', subresource: 'related')",
"Colrapi.nameusage(@dataset_id, nameusage_id: '32', subresource: 'source')",
],
},
:matching => {
description: "Get names or a name from a dataset",
params: {
:dataset_id => "The dataset id",
:name => "The scientific name to match",
:authorship => "The authorship string for the scientific name",
:code => "The nomenclatural code (bacterial, botanical, cultivars, phytosociological, virus, zoological)",
:rank => "The rank of the scientific name",
:within_superkingdom => "Restricts query to within a superkingdom",
:within_kingdom => "Restricts query to within a kingdom",
:within_subkingdom => "Restricts query to within a subkingdom",
:within_superphylum => "Restricts query to within a superphylum",
:within_phylum => "Restricts query to within a phylum",
:within_subphylum => "Restricts query to within a subphylum",
:within_superclass => "Restricts query to within a superclass",
:within_class => "Restricts query to within a class",
:within_subclass => "Restricts query to within a subclass",
:within_superorder => "Restricts query to within a superorder",
:within_order => "Restricts query to within a order",
:within_suborder => "Restricts query to within a suborder",
:within_superfamily => "Restricts query to within a superfamily",
:within_family => "Restricts query to within a family",
:within_subfamily => "Restricts query to within a subfamily",
:within_tribe => "Restricts query to within a tribe",
:within_subtribe => "Restricts query to within a subtribe",
:within_genus => "Restricts query to within a genus",
:within_subgenus => "Restricts query to within a subgenus",
:within_section => "Restricts query to within a section",
:within_species => "Restricts query to within a species",
:verbose => "Print headers to STDOUT",
},
examples: [
"Colrapi.matching(@dataset_id, name: @name)",
"Colrapi.matching(@dataset_id, name: @homonym)",
"Colrapi.matching(@dataset_id, name: @homonym, within_kingdom: 'Plantae')",
],
},
:nameusage_pattern => {
description: "Search for a name usage with a regex pattern",
params: {
:dataset_id => "restricts name usage pattern search within a dataset",
:regexp => "The regular expression pattern",
:status => "The taxonomic status (accepted, provisionally_accepted, synonym, ambiguous_synonym, misapplied, bare_name)",
:rank => "The taxonomic rank",
:project_id => "Filter to names from project_id, required if decision_mode used",
:decision_mode => "The type of decision (block, reviewed, update, update_recursive, ignore)",
:offset => "Offset for pagination",
:limit => "Limit for pagination",
:verbose => "Print headers to STDOUT",
},
examples: [
"Colrapi.nameusage_pattern(@col_ac22, '[A-Z]rnithorhynchus anatinus')",
"Colrapi.nameusage_pattern(@col_ac22, '[A-Z]rnithorhynchus anatinus', rank: 'species')",
"Colrapi.nameusage_pattern(@col_ac22, '[A-Z]rnithorhynchus anatinus', rank: 'family')",
],
},
:nameusage_search => {
description: "Search the nameusage route, which uses Elastic Search",
params: {
:authorship => "filters by authorship",
:authorship_year => "filters by authorship year",
:content => "restrict search to SCIENTIFIC_NAME, or AUTHORSHIP",
:dataset_id => "restricts name usage search within a dataset",
:endpoint => "some endpoints have nested options",
:environment => "filter by environment (MARINE, TERRESTRIAL, FRESHWATER, BRACKISH)",
:extinct => "filter by extinct status (0, 1)",
:facet => "the search facet",
:field => "filter by name field (see: http://api.checklistbank.org/vocab/namefield)",
:highest_taxon_id => "Filter by highest taxon ID",
:issue => "the data quality issue",
:max_rank => "maximum taxonomic rank of name usages",
:min_rank => "minimum taxonomic rank of name usages",
:name_type => "filter by name type (hybrid formula, informal, no name, otu, placeholder, scientific, virus)",
:nomenclatural_code => "filter by nomenclatural code (botanical, zoological, bacterial, viral, phytosociological, cultivars)",
:nomenclatural_status => "filter by nomenclatural status (acceptable, conserved, doubtful, established, manuscript, not established, rejected, unacceptable)",
:origin => "filter by origin of the name usage (see: http://api.checklistbank.org/vocab/origin)",
:q => "A query string",
:rank => "taxonomic rank of name usages",
:secondary_source => "filter by secondary source (authorship, basionym, extinct, holotype, parent, published in, rank, temporal range)",
:sector_dataset_id => "filter by the sector source dataset ID",
:sector_mode => "filter by the sector mode (attach, merge, union)",
:status => "filter by taxonomic status (accepted, ambiguous synonym, misapplied, provisionally accepted, synonym)",
:taxonomic_group => "filter by taxonomic group (see: http://api.checklistbank.org/vocab/taxgroup)",
:type => "sets the type of search to PREFIX, WHOLE_WORDS, or EXACT",
:usage_id => "Filter by usage ID",
:sort_by => "sort results by NAME, TAXONOMIC, INDEX_NAME_ID, NATIVE, or RELEVANCE",
:reverse => "sort in reverse order",
:offset => "Offset for pagination",
:limit => "Limit for pagination",
:verbose => "Print headers to STDOUT",
},
examples: [
"Colrapi.nameusage_search(q: @name)",
"Colrapi.nameusage_search(q: @name, offset: 2, limit: 1)",
"Colrapi.nameusage_search(q: 'Atta', rank: 'genus')",
],
},
:nameusage_suggest => {
description: "Get a name usage suggestion",
params: {
:dataset_id => "restricts name usage search within a dataset",
:q => "A suggestion search query",
:fuzzy => "Whether to include fuzzy matches for misspellings (TODO: might not actually work?)",
:min_rank => "The minimum rank to suggest",
:max_rank => "The maximum rank to suggest",
:sort_by => "The sorting order (name, taxonomic, index_name_id, native, relevance)",
:reverse => "Sort in opposite order",
:accepted => "Suggest only accepted names",
:verbose => "Print headers to STDOUT",
},
examples: [
"Colrapi.nameusage_suggest(@col_ac22, 'Alces alc', max_rank: 'subspecies', limit: 1)",
],
},
:nidx => {
description: "Get names index info",
params: {
:nidx_id => "a names index ID",
:subresource => "the subresource (group)",
},
examples: [
"Colrapi.nidx(1)",
"Colrapi.nidx(1, subresource: 'group')",
],
},
:nidx_match => {
description: "Get names index matches",
params: {
:q => "A match query",
:authorship => "An authorship string",
:rank => "The taxonomic rank",
:code => "The nomenclatural code",
:verbose => "Print headers to STDOUT",
},
examples: [
"Colrapi.nidx_match('Alces alces')",
],
},
:parser => {
description: "Parse a {subresource}",
params: {
:subresource => "the type of parser to use",
:q => "a query string or array of query strings to parse",
},
examples: [
"Colrapi.parser(subresource: 'boolean', q: 'TRUE')",
"Colrapi.parser(subresource: 'country',\n q: %w[Canada DEU Mexico])",
"Colrapi.parser(subresource: 'datasettype', q: 'taxonomic')",
],
},
:parser_idconverter => {
description: "Encode or decode identifiers to different formats (e.g., proquints are used as stable identifiers in ChecklistBank)",
params: {
:mode => "encode or decode",
:id => "the identifier to convert",
:format => "the format (proquint, hex, latin29, latin32, latin36, base64)",
:verbose => "Print headers to STDOUT",
},
examples: [
"Colrapi.parser_idconverter('encode', @int, 'proquint')",
"Colrapi.parser_idconverter('decode', @proquint, 'integer')",
],
},
:parser_metadata => {
description: "Parse metadata",
params: {
:url => "The url to a metadata file",
:format => "The format of the metadata (yaml, json, eml, datacite, zenodo)",
:verbose => "Print headers to STDOUT",
},
examples: [
"Colrapi.parser_metadata('https://api.checklistbank.org/dataset/1027.yaml', format: 'yaml')",
],
},
:parser_name => {
description: "Parse a scientific name",
params: {
:name => "The scientific name to parse",
:authorship => "The authorship string for the scientific name",
:rank => "The rank of the scientific name to parse",
:code => "The nomenclatural code (bacterial, botanical, cultivars, phytosociological, virus, zoological)",
},
examples: [
"Colrapi.parser_name('Acalypha macrostachya Jacq.')",
"Colrapi.parser_name()",
"Colrapi.parser_name(name)",
],
},
:patch => {
description: "Get metadata patch",
params: {
:dataset_id => "The dataset id",
:token => "The authentication token from retrieved with Colrapi.user_login(user, password)",
},
examples: [
"Colrapi.patch(@dataset_id)",
"Colrapi.patch(@dataset_id, patch_id: @patch_id)",
],
},
:preview => {
description: "Get the latest preview release metadata (or points to the project draft dataset after the preview is released?)",
params: {
:project_id => "The project id",
:token => "The authentication token from retrieved with Colrapi.user_login(user, password)",
:verbose => "Print headers to STDOUT",
},
examples: [
"Colrapi.preview(@project_id, @token)",
],
},
:reference => {
description: "Get a reference with @reference_id from dataset @dataset_id via the reference route",
params: {
:dataset_id => "The dataset id",
:reference_id => "The reference id",
:subresource => "The reference subresource endpoint (orphans)",
:issue => "The data quality issue (https://api.checklistbank.org/vocab/issue)",
:offset => "Offset for pagination",
:limit => "Limit for pagination",
:verbose => "Print headers to STDOUT",
},
examples: [
"Colrapi.reference(@dataset_id)",
"Colrapi.reference(@dataset_id, offset: 3838, limit: 2)",
"Colrapi.reference(@dataset_id, reference_id: @reference_id)",
],
},
:reviewer => {
description: "Get reviewer info",
params: {
:dataset_id => "The dataset id",
:token => "The authentication token from retrieved with Colrapi.user_login(user, password) # @return [Array, Hash, Boolean] An array of hashes",
},
examples: [],
},
:sector => {
description: "Get sector metadata, which allows importing datasets into project subtrees",
params: {
:dataset_id => "The dataset id",
:sector_id => "The sector id",
:name => "The scientific name to query",
:rank => "The rank of the scientific name",
:modified_by => "Filter by a user id on last modified by",
:broken => "Whether the decision is broken or not",
:subject_dataset_id => "The source dataset id",
:last_synced_before => "Filter by sectors synced before this date",
:mode => "Filter by type of sector (attach, union, merge)",
:subject => "TODO: what does this do? All decisions with subject=true are bare names, so maybe it checks if the subject taxon exists?",
:min_size => "The minimum number of records in the sector",
:without_data => "Filters to empty sectors with no data synced into the project yet",
:offset => "Offset for pagination",
:limit => "Limit for pagination",
:verbose => "Print headers to STDOUT",
},
examples: [
"Colrapi.sector(@dataset_id)",
"Colrapi.sector(@dataset_id, offset: 11, limit: 5)",
"Colrapi.sector(@dataset_id, sector_id: 1756)",
],
},
:sector_sync => {
description: "Get sector sync info",
params: {
:dataset_id => "The dataset id",
:sector_id => "The sector id",
:state => "The sector sync state (e.g., waiting, processing, inserting, indexing, finished, etc.)",
:running => "Filter to sector syncs that are only running",
:attempt => "The sync attempt number for sector_id",
:subresource => "The subresource for attempt (names or tree)",
:offset => "Offset for pagination",
:limit => "Limit for pagination",
:verbose => "Print headers to STDOUT",
},
examples: [
"Colrapi.sector_sync(@col_draft)",
"Colrapi.sector_sync(@col_draft, sector_id: res['result'][0]['sectorKey'])",
"Colrapi.sector_sync(@col_draft, sector_id: sector_id, attempt: attempt, subresource: 'names')",
],
},
:source => {
description: "Get source metadata for datasets assembled into a project dataset",
params: {
:dataset_id => "The project dataset id",
:source_id => "The source dataset id",
:not_current_only => "Return only not current sources",
:original => "TODO: what does this do?",
},
examples: [
"Colrapi.source('9837')",
"Colrapi.source('9837', not_current_only: true)",
"Colrapi.source('9837', source_id: '1027')",
],
},
:settings => {
description: "Get the dataset settings",
params: {
:dataset_id => "The dataset id",
},
examples: [
"Colrapi.settings('1021')",
],
},
:synonym => {
description: "Get a synonym with @synonym_id from dataset @dataset_id via the synonym route",
params: {
:dataset_id => "The dataset id",
:synonym_id => "The synonym id",
:subresource => "The synonym subresource endpoint (source)",
:offset => "Offset for pagination",
:limit => "Limit for pagination",
:verbose => "Print headers to STDOUT",
},
examples: [
"Colrapi.synonym(@dataset_id)",
"Colrapi.synonym(@dataset_id, offset: 3893, limit: 4)",
"Colrapi.synonym(@dataset_id, synonym_id: @synonym_id)",
],
},
:taxon_ids => {
description: "Get the full list of taxon IDs for a dataset (returns 1 ID string per line, not JSON)",
params: {
:dataset_id => "The dataset id",
},
examples: [
"Colrapi.taxon_ids(@dataset_id)",
],
},
:taxon => {
description: "Get a taxon with @id from dataset @dataset_id via the taxon route",
params: {
:dataset_id => "The dataset id",
:taxon_id => "The taxon id",
:subresource => "The taxon subresource endpoint (classification, distribution, info, interaction, media, relation, source, synonyms, treatment, or vernacular)",
:format => "The format of the treatment (plain_text, markdown, xml, html, tax_pub, taxon_x, rdf)",
:offset => "Offset for pagination",
:limit => "Limit for pagination",
:verbose => "Print headers to STDOUT",
},
examples: [
"Colrapi.taxon(@dataset_id, taxon_id: @taxon_id)",
"Colrapi.taxon(@dataset_id, offset: 3483, limit: 1)",
"Colrapi.taxon(@dataset_id, taxon_id: @taxon_id, subresource: 'classification')",
],
},
:tree => {
description: "Get the root taxa",
params: {
:dataset_id => "The dataset id",
:taxon_id => "The taxon id",
:children => "Display the children of taxon_id",
:offset => "Offset for pagination",
:limit => "Limit for pagination",
:verbose => "Print headers to STDOUT",
},
examples: [
"tree(@dataset_id, import_attempt: @import_attempt)",
"Colrapi.tree(@dataset_id)",
"Colrapi.tree(@dataset_id, taxon_id: 'N', children: true, offset: 3, limit: 5)",
],
},
:user => {
description: "Get user data",
params: {
:user_id => "The user id",
:q => "The search query",
:role => "The user role (admin, editor, or reviewer)",
:offset => "Offset for pagination",
:limit => "Limit for pagination",
:token => "The authentication token from retrieved with Colrapi.user_login(user, password)",
:verbose => "Print headers to STDOUT",
},
examples: [
"Colrapi.user(q: @user, token: @token)",
"Colrapi.user(user_id: @user_id)",
],
},
:user_dataset => {
description: "Get datasets user can access",
params: {
:token => "The access token from Colrapi.user_login()",
:dataset_id => "A dataset id to check",
:origin => "Filter by the origin of a dataset (external, project, release, xrelease)",
},
examples: [],
},
:user_login => {
description: "Authenticate user and get authentication token",
params: {},
examples: [
"Colrapi.user_login(@user, @password)",
],
},
:user_me => {
description: "Get the authenticated user",
params: {
:token => "The authentication token from retrieved with Colrapi.user_login(user, password)",
:verbose => "Print headers to STDOUT",
},
examples: [
"Colrapi.user_me(@token)",
],
},
:verbatim => {
description: "Get verbatim data",
params: {
:dataset_id => "The dataset id",
:verbatim_id => "The verbatim id",
:q => "The search query string",
:issue => "Filter by data quality issue (e.g., ACCEPTED_NAME_MISSING, DUPLICATE_NAME, URL_INVALID)",
:type => "The file type (e.g., acef:AcceptedSpecies, col:Taxon, dwc:Taxon) TODO: May not work yet: https://github.com/CatalogueOfLife/backend/issues/1201 @param term [Array, String] Filter by term (http://api.checklistbank.org/vocab/term) @param term_operator [String] The operator to use with term ('and' or 'or')",
:offset => "Offset for pagination",
:limit => "Limit for pagination",
:verbose => "Print headers to STDOUT",
},
examples: [
"Colrapi.verbatim(@dataset_id)",
"Colrapi.verbatim(@dataset_id, offset: 5, limit: 2)",
"Colrapi.verbatim(@dataset_id, verbatim_id: '4')",
],
},
:vernacular => {
description: "Get vernacular names",
params: {
:dataset_id => "The dataset id",
:q => "A vernacular name search query",
:language => "The language of the vernacular name (see: http://api.checklistbank.org/vocab/language)",
:offset => "Offset for pagination",
:limit => "Limit for pagination",
:verbose => "Print headers to STDOUT",
},
examples: [
"Colrapi.vernacular(offset: 5, limit: 4)",
"Colrapi.vernacular(dataset_id: @col_ac22)",
"Colrapi.vernacular(dataset_id: @col_ac22, offset: 8, limit: 6)",
],
},
:version => {
description: "Get backend version",
params: {},
examples: [],
},
:vocab => {
description: "Get vocab",
params: {
:term => "The vocab term",
:subresource => "The subresource which is usually the id, code, or name",
:children => "Returns the geotime's children if true",
:verbose => "Print headers to STDOUT",
},
examples: [
"Colrapi.vocab(term: 'issue')",
"Colrapi.vocab(term: 'geotime')",
"Colrapi.vocab(term: 'geotime', subresource: 'Jurassic')",
],
},
},
},
:crawlyflower => {
description: "Wrapper for WoRMS API - access World Register of Marine Species data",
api: "https://www.marinespecies.org/rest/",
endpoints: {
:children => {
description: "Get the direct children (max. 50) for a given AphiaID",
params: {
:id => "The AphiaID to search for",
:marine_only => "Limit to marine taxa. Default: true",
:extant_only => "Limit to extant taxa. Default: true",
:offset => "Starting record number. Default: 1",
},
examples: [
"Crawlyflower.children(126132)",
],
},
:classification => {
description: "Get the complete classification for one taxon",
params: {
:id => "The AphiaID to search for",
},
examples: [
"Crawlyflower.classification(127160)",
],
},
:distributions => {
description: "Get all distributions for a given AphiaID",
params: {
:id => "The AphiaID to search for",
},
examples: [
"Crawlyflower.distributions(127160)",
],
},
:external_id => {
description: "Get any external identifier(s) for a given AphiaID",
params: {
:id => "The AphiaID to search for",
:type => "Type of external identifier (algaebase, bold, dyntaxa, fishbase, iucn, lsid, ncbi, tsn, gisd)",
},
examples: [
"Crawlyflower.external_id(127160, type: \"tsn\")",
"external_id(\"173002\", type: \"tsn\")",
],
},
:aphia_id_by_name => {
description: "Get the AphiaID for a given name",
params: {
:name => "Name to search for",
:marine_only => "Limit to marine taxa. Default: true",
:extant_only => "Limit to extant taxa. Default: true",
},
examples: [
"Crawlyflower.aphia_id_by_name(\"Solea solea\")",
],
},
:name => {
description: "Get the name for a given AphiaID",
params: {
:id => "The AphiaID to search for",
},
examples: [
"name(\"Species\")",
"Crawlyflower.name(127160)",
"name(\"Solea solea\")",
],
},
:record => {
description: "Get the complete AphiaRecord for a given AphiaID",
params: {
:id => "The AphiaID to search for",
},
examples: [
"Crawlyflower.record(127160)",
"record(127160)",
"record(127160, format: :turtle)",
],
},
:records_by_aphia_ids => {
description: "Get AphiaRecords for multiple AphiaIDs in one go (max: 50)",
params: {
:ids => "The AphiaIDs to search for",
},
examples: [
"Crawlyflower.records_by_aphia_ids([127160, 126436])",
],
},
:record_by_external_id => {
description: "Get the Aphia Record for a given external identifier",
params: {
:id => "The external identifier to search for",
:type => "Type of external identifier (algaebase, bold, dyntaxa, fishbase, iucn, lsid, ncbi, tsn, gisd)",
},
examples: [
"Crawlyflower.record_by_external_id(\"173002\", type: \"tsn\")",
],
},
:records_by_date => {
description: "Lists all AphiaRecords that have their last edit action during the specified period",
params: {
:startdate => "ISO 8601 formatted start date(time)",
:enddate => "ISO 8601 formatted end date(time)",
:marine_only => "Limit to marine taxa",
:extant_only => "Limit to extant taxa",
:offset => "Starting record number. Default: 1",
},
examples: [],
},
:records_by_match_names => {
description: "Try to find AphiaRecords using the TAXAMATCH fuzzy matching algorithm",
params: {
:scientificnames => "Names to search for",
:authorships => "The authorities of the given names",
:marine_only => "Limit to marine taxa",
:extant_only => "Limit to extant taxa",
:match_authority => "Use the authority in the matching process",
},
examples: [
"Crawlyflower.records_by_match_names(scientificnames: [\"Solea solea\"])",
],
},
:records_by_name => {
description: "Get one or more matching (max. 50) AphiaRecords for a given name",
params: {
:name => "Name to search for",
:like => "Add a '%'-sign after the ScientificName. Default: true",
:marine_only => "Limit to marine taxa",
:extant_only => "Limit to extant taxa",
:offset => "Starting record number. Default: 1",
},
examples: [
"Crawlyflower.records_by_name(\"Solea solea\")",
],
},
:records_by_names => {
description: "For each given scientific name, try to find one or more AphiaRecords (max 500 names)",
params: {
:scientificnames => "Names to search for",
:like => "Add a '%'-sign after the ScientificName. Default: false",
:marine_only => "Limit to marine taxa",
:extant_only => "Limit to extant taxa",
},
examples: [
"Crawlyflower.records_by_names(scientificnames: [\"Solea solea\", \"Gadus morhua\"])",
],
},
:records_by_vernacular => {
description: "Get one or more Aphia Records (max. 50) for a given vernacular",
params: {
:name => "The vernacular to find records for",
:like => "Add a '%'-sign before and after the input. Default: false",
:offset => "Starting record number. Default: 1",
},
examples: [
"Crawlyflower.records_by_vernacular(\"common sole\")",
],
},
:synonyms => {
description: "Get all synonyms for a given AphiaID",
params: {
:id => "The AphiaID to search for",
:offset => "Starting record number. Default: 1",
},
examples: [
"Crawlyflower.synonyms(127160)",
],
},
:vernaculars => {
description: "Get all vernaculars for a given AphiaID",
params: {
:id => "The AphiaID to search for",
},
examples: [
"Crawlyflower.vernaculars(127160)",
],
},
:sources => {
description: "Get one or more sources/references including links, for one AphiaID",
params: {
:id => "The AphiaID to search for",
},
examples: [
"Crawlyflower.sources(127160)",
],
},
:taxon_ranks_by_id => {
description: "Get taxonomic ranks by their identifier",
params: {
:id => "A taxonomic rank identifier. Default: -1",
:aphia_id => "The AphiaID of the kingdom",
},
examples: [
"Crawlyflower.taxon_ranks_by_id(-1)",
],
},
:taxon_ranks_by_name => {
description: "Get taxonomic ranks by their name",
params: {
:name => "A taxonomic rank name",
:aphia_id => "The AphiaID of the kingdom",
},
examples: [
"Crawlyflower.taxon_ranks_by_name(\"Species\")",
],
},
:records_by_taxon_rank_id => {
description: "Get the AphiaRecords for a given taxonRankID (max 50)",
params: {
:id => "A taxonomic rank identifier",
:belongs_to => "Limit the results to descendants of the given AphiaID",
:offset => "Starting record number. Default: 1",
},
examples: [
"Crawlyflower.records_by_taxon_rank_id(220, belongs_to: 126132)",
],
},
:full_record => {
description: "Get the complete AphiaFullRecord (linked open data) for a given AphiaID",
params: {
:id => "The AphiaID to search for",
:format => "Response format: :jsonld (default), :rdf, :turtle, :ntriples",
},
examples: [
"Crawlyflower.full_record(127160)",
"Crawlyflower.full_record(127160, format: :turtle)",
"Crawlyflower.full_record(127160, format: :rdf)",
],
},
:attribute_keys => {
description: "Get attribute definitions",
params: {
:id => "The attribute definition id to search for. Use 0 for root items",
:include_children => "Include the tree of children. Default: true",
},
examples: [
"Crawlyflower.attribute_keys(0)",
],
},
:attribute_values_by_category => {
description: "Get list values that are grouped by a CategoryID",
params: {
:id => "The CategoryID to search for",
},
examples: [],
},
:aphia_ids_by_attribute_key => {
description: "Get a list of AphiaIDs (max 50) with attribute tree for a given attribute definition ID",
params: {
:id => "The attribute definition id to search for",
:offset => "Starting record number. Default: 1",
},
examples: [],
},
:attributes => {
description: "Get a list of attributes for a given AphiaID",
params: {
:id => "The AphiaID to search for",
:include_inherited => "Include attributes inherited from parent(s). Default: false",
},
examples: [
"Crawlyflower.attributes(127160)",
],
},
:suggest => {
description: "Get taxa suggestions for a given prefix of a taxon name",
params: {
:name_part => "The prefix to use to search for taxa",
:rank_min => "The minimum rank of the returned suggestion. Default: 10",
:rank_max => "The maximum rank of the returned suggestion. Default: 280",
:max_matches => "The maximum number of suggestions to return. Default: 20, Max: 50",
:excluded_ids => "AphiaIDs to exclude from the result set",
:combine_vernaculars => "When true the name can also match vernaculars. Default: false",
:marine_only => "Limit to marine taxa. Default: true",
:fossil_id => "Determines the search behavior for fossil taxa. Default: 0",
:languages => "List of ISO 639-3 language codes to filter search results",
},
examples: [
"Crawlyflower.suggest(\"Solea\")",
],
},
},
},
:hookkaido => {
description: "Wrapper for OWL Ontology API - access biodiversity ontology data",
api: "https://www.ontobee.org",
endpoints: {
:ontologies => {
description: "List available ontology IDs (lowercased)",
params: {},
examples: [],
},
:search => {
description: "Search OLS for terms in specific ontologies matching a user-provided term.",
params: {},
examples: [],
},
},
},
:nasturtium => {
description: "Wrapper for iNaturalist API - access species observations and biodiversity data",
api: "https://api.inaturalist.org/v1",
endpoints: {
:controlled_terms => {
description: "Get controlled vocabulary terms",
params: {
:taxon_id => "If set returns controlled terms for the taxon",
:page => "The results page number",
:per_page => "The results limit",
:verbose => "Print headers to STDOUT",
},
examples: [
"Nasturtium.controlled_terms(per_page: @per_page)",
"Nasturtium.controlled_terms(taxon_id: 1, per_page: @per_page)",
],
},
:identifications => {
description: "Get identifications",
params: {
:id => "An array of identification IDs",
:current_taxon => "The identification taxon is the same as its observation's taxon",
:own_observation => "The identification was added by th observer",
:is_change => "The identification was created as a result of a taxon change",
:taxon_active => "The identification's taxon is currently an active taxon",
:observation_taxon_active => "The observation's taxon is currently an active taxon",
:rank => "Filter by a comma-separated list of taxonomic ranks on the identification",
:observation_rank => "Filter by a comma-separated list of taxonomic ranks on the observation",
:user_id => "Filter by a comma-separated list of user IDs",
:user_login => "Filter by a comma-separated list of user logins",
:current => "The most recent identification on an observation by a user",
:category => "The type of identification (improving, supporting, leading)",
:place_id => "Filter by a comma-separated list of place IDs",
:quality_grade => "Filter by a comma-separated list of quality grades (casual, needs_id, research)",
:taxon_id => "Filter by a comma-separated list of taxon IDs on the identification",
:observation_taxon_id => "Filter by a comma-separated list of taxon IDs on the observation",
:iconic_taxon_id => "Filter by a comma-separated list of iconic taxon IDs on the identification",
:observation_iconic_taxon_id => "Filter by a comma-separated list of iconic taxon IDs on the observation",
:rank_lowest => "The identification's taxon must have this rank or higher",
:rank_highest => "The identification's taxon must have this rank or lower",
:observation_rank_lowest => "The observation's taxon must have this rank or higher",
:observation_rank_highest => "The observation's taxon must have this rank or lower",
:without_taxon_id => "Exclude this comma-separated list of identification taxon IDs and their descendants",
:without_observation_taxon_id => "Exclude this comma-separated list of observation taxon IDs and their descendants",
:before => "Identified before this time (d2)",
:after => "Identified after this time (d1)",
:observation_created_before => "Observation record was created before this time (observation_created_d2)",
:observation_created_after => "Observation record was created after this time (observation_created_d1)",
:observed_before => "Observed before this time (observed_d2)",
:observed_after => "Observed after this time (observed_d1)",
:id_below => "The identification ID must be below the provided value",
:id_above => "The identification ID must be above the provided value",
:only_id => "Only return record IDs",
:order => "Ascending or descending sort order (asc, desc)",
:order_by => "The parameter to sort by (created_at, id)",
:page => "The results page number",
:per_page => "The results limit",
:verbose => "Print headers to STDOUT",
},
examples: [
"Nasturtium.identifications(id: 342040114, per_page: @per_page)",
"Nasturtium.identifications(current_taxon: true, per_page: @per_page)",
"Nasturtium.identifications(current_taxon: false, per_page: @per_page)",
],
},
:mapping => {
description: "Get map tiling assets for observations",
params: {},
examples: [],
},
:places_id => {
description: "Get places",
params: {
:id => "A comma-separated list of place IDs",
:admin_level => "A comma-separated list of admin levels (-10: continent, 0: country, 10: state, 20: county, 30: town, 100: park)",
},
examples: [
"Nasturtium.places_id(1000)",
"Nasturtium.places_id(1000, admin_level: 100)",
"Nasturtium.places_id(r['place_id'])",
],
},
:places_autocomplete => {
description: "Suggest places",
params: {
:q => "A place name must start with this query",
:order_by => "The parameter to sort by (area) # TODO: iNaturalist bug? doesn't seem to affect sorting in the API?",
:per_page => "The results limit",
:verbose => "Print headers to STDOUT",
},
examples: [
"Nasturtium.places_autocomplete('Kickapoo Rail Trail')",
"Nasturtium.places_autocomplete('The')",
],
},
:places_nearby => {
description: "https://api.inaturalist.org/v1/places/nearby?nelat=40.346036&nelng=-87.951568&swlat=39.935393&swlng=-88.628846",
params: {
:ne_latitude => "Get nearby places within provided (nelat) bounding box (ne_latitude, ne_longitude, sw_latitude, sw_longitude)",
:ne_longitude => "Get nearby places within provided (nelng) bounding box (ne_latitude, ne_longitude, sw_latitude, sw_longitude)",
:sw_latitude => "Get nearby places within provided (swlat) bounding box (ne_latitude, ne_longitude, sw_latitude, sw_longitude)",
:sw_longitude => "Get nearby places within provided (swlng) bounding box (ne_latitude, ne_longitude, sw_latitude, sw_longitude)",
:name => "Place name must match this value # TODO: iNaturalist bug? you can't provide the last word of a name (e.g., River Bend Forest works, but River Bend Forest Preserve doesn't work)",
:per_page => "The results limit",
:verbose => "Print headers to STDOUT",
},
examples: [
"Nasturtium.places_nearby(@ne_lat, @ne_lng, @sw_lat, @sw_lng)",
"Nasturtium.places_nearby(@ne_lat, @ne_lng, @sw_lat, @sw_lng, name: \"Meadowbrook\")",
],
},
:posts => {
description: "Get journal posts",
params: {
:login => "Filter by user login",
:project_id => "Filter by project ID",
:parent_id => "Filter by parent ID",
:page => "",
:per_page => "",
:verbose => "Print headers to STDOUT",
},
examples: [
"Nasturtium.posts(login: 'loarie', per_page: @per_page)",
"Nasturtium.posts(parent_id: 1)",
"Nasturtium.posts(project_id: 42768)",
],
},
:projects => {
description: "TODO: Add tests",
params: {
:q => "Project name must begin with query string",
:autocomplete => "Returns projects that start with the search q",
:id => "Project must have this ID",
:not_id => "Project must not have this ID",
:latitude => "Filter by projects within a {radius} kilometer circle around the provided latitude coordinate (lat)",
:longitude => "Filter by projects within a {radius} kilometer circle around the provided longitude coordinate (lng)",
:radius => "Filter by projects within the provided radius in kilometers",
:place_id => "Filter by a comma-separated list of place_ids",
:featured => "Filter by marked featured for the relevant site",
:noteworthy => "Filter by marked noteworthy for the relevant site",
:site_id => "The site ID that applies to featured and noteworthy, defaults to site of the authenticated user or the main iNaturalist site",
:rule_details => "Return more details about the project rules",
:type => "Filter by project type [collection, umbrella]",
:member_id => "Filter by projects that include a user ID",
:has_params => "Must have search parameter requirements",
:has_posts => "Project must have posts",
:page => "The results page number",
:per_page => "The results limit",
:order_by => "The parameter to sort by (observed_on, species_guess, votes, id, created_at)",
:verbose => "Print headers to STDOUT",
},
examples: [
"Nasturtium.projects(id: '67047', per_page: @per_page)",
"Nasturtium.projects(latitude: 41.295233, longitude: -89.024618, radius: 1, per_page: @per_page)",
"Nasturtium.projects(place_id: 35, per_page: @per_page)",
],
},
:project_members => {
description: "Get project members",
params: {
:id => "The project ID",
:page => "The results page number",
:per_page => "The results limit",
:verbose => "Print headers to STDOUT",
},
examples: [
"Nasturtium.project_members(733, page: 1, per_page: @per_page)",
],
},
:search => {
description: "Search places, projects, taxa, users",
params: {
:q => "A search query",
:sources => "Type of record to search (places, projects, taxa, users)",
:place_id => "Filter to an array of place_ids (TODO: place_id is an array in the documentation but doesn't seem to work even with their example?)",
:preferred_place_id => "Place of preference for regional taxon common names",
:locale => "Locale preference for taxon common names (e.g., en-US)",
:page => "The results page number",
:per_page => "The results limit",
:verbose => "Print headers to STDOUT",
},
examples: [
"Nasturtium.search(q: 'oak', sources: 'taxa')",
"Nasturtium.search(q: 'oak', place_id: '35')",
"Nasturtium.search(q: 'Danaus plexippus', preferred_place_id: 6903)",
],
},
:user => {
description: "Get user",
params: {
:id => "The user ID",
:verbose => "Print headers to STDOUT",
},
examples: [
"Nasturtium.user(@id)",
],
},
:user_me => {
description: "Get logged in user",
params: {
:id => "The user ID",
:verbose => "Print headers to STDOUT",
},
examples: [
"Nasturtium.user_me()",
],
},
:user_projects => {
description: "Get user's projects",
params: {
:id => "The user ID",
:rule_details => "Return more details about project rules",
:project_type => "Filter by project type (collection, contest, traditional, umbrella)",
:page => "The results page number",
:per_page => "The results limit",
:verbose => "Print headers to STDOUT",
},
examples: [
"Nasturtium.user_projects(@id)",
"Nasturtium.user_projects(@id, project_type: 'collection')",
"Nasturtium.user_projects(@id, per_page: 1, page: 2)",
],
},
:user_autocomplete => {
description: "Get user suggestions",
params: {
:q => "The username must begin with this query",
:project_id => "Only show members of this project ID",
:per_page => "The results limit",
:verbose => "Print headers to STDOUT",
},
examples: [
"Nasturtium.user_autocomplete('debpau')",
"Nasturtium.user_autocomplete('ab', per_page: 1)",
],
},
:observations => {
description: "Get observations",
params: {
:subresource => "Access a subresource endpoint of observations (histogram, identifiers, observers, popular_field_values, species_counts)",
:q => "An observation properties search query",
:search_on => "Observation properties to search on (names, tags, description, place)",
:id => "A comma-separated list of observation IDs",
:not_id => "A comma-separated list of observation IDs that must not be included",
:acc => "Filter by whether the positional accuracy/coordinate uncertainty was specified",
:captive => "Filter on whether it was captive/cultivated observations",
:endemic => "Filter on whether observations were of taxa endemic to their location",
:geo => "Filter to only georeferenced observations",
:identified => "Filter to only observations with community identifications",
:introduced => "Filter to observations of taxa that were introduced to their location",
:mappable => "Filter to only observations that show on map tiles",
:native => "Filter to only observations of taxa native tot heir location",
:out_of_range => "Filter to only observations made in locations outside the taxon's known ranges",
:pcid => "Filter to observations identified by a curator of a project",
:photos => "Filter to observations with photos",
:popular => "Filter to only observations that have been favorited by at least 1 user",
:sounds => "Filter to observations with sounds",
:taxon_is_active => "Filter to observations of active taxon concepts",
:threatened => "Filter to observations of taxa that are threatened at their location",
:verifiable => "Filter by observations with a quality_grade=needs_id,research",
:licensed => "Filter by observations with a license",
:photo_licensed => "License attribute of at least one photo in an observation must not be nil",
:license => "Filter by a comma-separated list of licenses (cc-by,cc-by-nc,cc-by-nd,cc-by-sa,cc-by-nc-nd,cc-by-nc-sa,cc0)",
:photo_license => "Filter by a comma-separated list of photo licenses (cc-by,cc-by-nc,cc-by-nd,cc-by-sa,cc-by-nc-nd,cc-by-nc-sa,cc0)",
:sound_license => "Filter by a comma-separated list of sound licenses (cc-by,cc-by-nc,cc-by-nd,cc-by-sa,cc-by-nc-nd,cc-by-nc-sa,cc0)",
:ofv_datatype => "Filter by a comma-separated list of datatypes that the observation must include # TODO: does it take arrays?",
:place_id => "Filter by a comma-separated list of place_ids",
:project_id => "Filter by a comma-separated list of project_ids",
:rank => "Filter by an array of taxon ranks",
:site_id => "Filter by a comma-separated list of site_ids",
:taxon_id => "Filter by a comma-separated list of taxon_ids and their descendants",
:without_taxon_id => "Exclude a comma-separated list of taxon_ids and their descendants",
:taxon_name => "Filter by a comma-separated list of scientific or common names",
:user_id => "Filter by observations made by a comma-separated list of user_ids",
:user_login => "Filter by a comma-separated list of user_logins",
:ident_user_id => "Filter by observations identified by a particular user_id",
:day => "Filter on a comma-separated list of days",
:month => "Filter on a comma-separated list of months",
:year => "Filter on a comma-separated list of years",
:term_id => "Filter on a comma-separated list of term_ids",
:without_term_id => "String, Integer, nil] Exclude on a comma-separated list of term_ids",
:term_value_id => "Filter on annotations made with this controlled value ID; must be used with term_id",
:without_term_value_id => "Exclude on annotations made with this controlled value ID",
:acc_above => "Positional accuracy must be above value",
:acc_below => "Positional accuracy must be below value",
:acc_below_or_unknown => "Positional accuracy must be below value or unknown",
:before => "Must have been observed on or before this date (d2)",
:after => "Must have been observed on or after this date (d1)",
:observed_on => "Must have been observed on this date",
:created_before => "Must have been created on or before this date (created_d2)",
:created_on => "Must have been created on this date",
:created_after => "Must have been created on or before this date (created_d1)",
:unobserved_by_user_id => "Taxon must be unobserved by the provided user_id",
:apply_project_rules_for => "Must match rules of the provided project_id",
:conservation_status => "Taxon must have this conservation status (cs) code, use with place_id to make location-specific",
:conservation_status_authority => "Taxon must have the conservation status from the provided authority (csa), use with place_id to make location-specific",
:conservation_status_iucn => "Taxon must have the provided conservation status from the IUCN, use with place_id to make location-specific",
:geoprivacy => "Filter by a comma-separated list of geoprivacy settings (obscured, obscured_private, open)",
:taxon_geoprivacy => "Filter by a comma-separated list of geoprivacy settings (obscured, obscured_private, open) of the most conservative geoprivacy associated with one of the taxa proposed in the current identifications",
:rank_lowest => "Taxon rank must be less than or equal to provided rank",
:rank_highest => "Taxon rank must be greater than or equal to provided rank",
:iconic_taxa => "Filter by taxa with the provided iconic taxon (Actinopterygii, Animalia, Amphibia, Arachnida, Aves, Chromista, Fungi, Insecta, Mammalia, Mollusca, Repitilia, Plantae, Protozoa, unknown)",
:id_below => "Most have an observation ID below the provided value",
:id_above => "Most have an observation ID above the provided value",
:identifications => "Filter by identifications status (most_agree, some_agree, most_disagree)",
:latitude => "Filter by observations within a {radius} kilometer circle around the provided latitude coordinate (lat)",
:longitude => "Filter by observations within a {radius} kilometer circle around the provided longitude coordinate (lng)",
:radius => "Filter by observations within the provided radius in kilometers",
:ne_latitude => "Filter by observations within provided (nelat) bounding box (ne_latitude, ne_longitude, sw_latitude, sw_longitude)",
:ne_longitude => "Filter by observations within provided (nelng) bounding box (ne_latitude, ne_longitude, sw_latitude, sw_longitude)",
:sw_latitude => "Filter by observations within provided (swlat) bounding box (ne_latitude, ne_longitude, sw_latitude, sw_longitude)",
:sw_longitude => "Filter by observations within provided (swlng) bounding box (ne_latitude, ne_longitude, sw_latitude, sw_longitude)",
:list_id => "Taxon must bin the list with the provided ID",
:not_in_project => "Observation must not be in the provided project_id or slug",
:not_matching_project_rules_for => "Must not match the rules of the provided project_id or slug",
:quality_grade => "Filter by observation quality grade (casual, needs_id, research)",
:updated_since => "Filter by observations updated since the provided time",
:reviewed => "Observations have been reviewed by viewer_id",
:viewer_id => "Use with reviewed boolean to filter by observations reviewed by the provided viewer_id",
:locale => "Locale preference for taxon common names (e.g., en-US)",
:preferred_place_id => "Place of preference for regional taxon common names",
:ttl => "Set the Cache-Control HTTP header with a max-age value to cache the request on iNaturalist serers and within the client",
:only_id => "Only return record IDs",
:order => "Ascending or descending sort order (asc, desc)",
:order_by => "The parameter to sort by (observed_on, species_guess, votes, id, created_at)",
:page => "The results page number",
:per_page => "The results limit",
:headers => "Return headers instead of body",
:verbose => "Print headers to STDOUT",
},
examples: [
"Nasturtium.observations(id: '150842485')",
"Nasturtium.observations(id_above: 1000, id_below: 2000, only_id: true)",
"Nasturtium.observations(id_above: 1000, id_below: 2000, not_id: not_ids, only_id: true)",
],
},
:taxa => {
description: "Taxon search",
params: {
:id => "A taxon ID or comma-separated array of taxon IDs",
:q => "A search query",
:is_active => "Filter to taxa with active taxon concepts",
:taxon_id => "Filter by a comma-separated array of taxon_ids",
:parent_id => "Filter by a taxon parent_id",
:rank => "Filter by an array of taxon ranks",
:rank_level => "Filter by taxon rank level (e.g., 70 for kingdom)",
:id_above => "ID must be greater than value",
:id_below => "ID must be below value",
:preferred_place_id => "Place of preference for regional taxon common names",
:locale => "Locale preference for taxon common names (e.g., en-US)",
:only_id => "Only return record IDs",
:all_names => "Include all taxon names in the response",
:order => "Ascending or descending sort order (asc, desc)",
:order_by => "The parameter to sort by",
:page => "The results page number",
:per_page => "The results limit",
:verbose => "Print headers to STDOUT",
},
examples: [
"Nasturtium.taxa(only_id: true, per_page: @per_page)",
"Nasturtium.taxa(id: 1)",
"Nasturtium.taxa(parent_id: 1)",
],
},
:taxa_autocomplete => {
description: "Taxon suggest",
params: {
:q => "A suggest query",
:is_active => "Suggest only taxa with active taxon concepts",
:taxon_id => "Filter by comma-separated taxon IDs",
:rank => "Filter by an array of taxon ranks",
:rank_level => "Filter by taxon rank level (e.g., 70 for kingdom)",
:locale => "Locale preference for taxon common names (e.g., en-US)",
:preferred_place_id => "Place of preference for regional taxon common names",
:all_names => "Include all taxon names in the response",
:per_page => "The results limit",
:verbose => "Print headers to STDOUT",
},
examples: [
"Nasturtium.taxa_autocomplete(q: 'Ladona ')",
"Nasturtium.taxa_autocomplete(q: 'Sinapis', is_active: true, rank: 'species')",
"Nasturtium.taxa_autocomplete(q: 'Sinapis', is_active: false, rank: 'species')",
],
},
},
},
:plazucchini => {
description: "Wrapper for Plazi TreatmentBank API - access taxonomic treatments and species data",
api: "https://api.plazi.org",
endpoints: {
:authors_described_species => {
description: "Authors Described Species",
params: {
:author => "The author (default: \"Agosti, D\")",
:limit => "The optional result limit",
:order_mode => "The optional sort order (ASC, DESC, nil)",
:verbose => "Print headers to STDOUT",
},
examples: [
"Plazucchini.authors_described_species(author: 'Mockford, Edward L.', limit: 1)",
],
},
:authors_material_type_citations => {
description: "Authors Material Type Citations",
params: {
:genus_epithet => "The genus epithet (default: \"Tyrannosaurus\")",
:species_epithet => "The species epithet (default: \"rex\")",
:limit => "The optional result limit",
:order_mode => "The optional sort order (ASC, DESC, nil)",
:verbose => "Print headers to STDOUT",
},
examples: [],
},
:authors_new_species => {
description: "Authors New Species",
params: {
:author => "The author (required, default: \"Malabarba\")",
:status => "The taxonomic status (default: \"sp. nov.\")",
:limit => "The optional result limit",
:order_mode => "The optional sort order (ASC, DESC, nil)",
:verbose => "Print headers to STDOUT",
},
examples: [
"Plazucchini.authors_new_species(author: 'Mockford', status: 'sp. nov.', limit: 1)",
],
},
:authors_publication_dates => {
description: "Authors Publication Dates",
params: {
:author => "The author (default: \"Agosti, D\")",
:limit => "The optional result limit",
:order_mode => "The optional sort order (ASC, DESC, nil)",
:verbose => "Print headers to STDOUT",
},
examples: [
"Plazucchini.authors_publication_dates(author: 'Mockford', limit: 1)",
],
},
:authors_publication_journals => {
description: "Authors Publication Journals",
params: {
:author => "The author (default: \"Agosti, D\")",
:limit => "The optional result limit",
:order_mode => "The optional sort order (ASC, DESC, nil)",
:verbose => "Print headers to STDOUT",
},
examples: [
"Plazucchini.authors_publication_journals(author: 'Mockford', limit: 1)",
],
},
:authors_publication_partners => {
description: "Authors Publication Partners (Co-Authors)",
params: {
:author => "The author (default: \"Agosti, D\")",
:limit => "The optional result limit",
:order_mode => "The optional sort order (ASC, DESC, nil)",
:verbose => "Print headers to STDOUT",
},
examples: [
"Plazucchini.authors_publication_partners(author: 'Mockford', limit: 1)",
],
},
:authors_specimen_locations => {
description: "Authors Specimen Locations",
params: {
:collector => "The collector (default: \"Agosti\")",
:limit => "The optional result limit",
:order_mode => "The optional sort order (ASC, DESC, nil)",
:verbose => "Print headers to STDOUT",
},
examples: [
"Plazucchini.authors_specimen_locations(collector: 'Mockford', limit: 1)",
],
},
:authors_treatment_count => {
description: "Authors Treatment Count",
params: {
:author => "The author (required, default: \"Linnaeus\")",
:limit => "The optional result limit",
:order_mode => "The optional sort order (ASC, DESC, nil)",
:verbose => "Print headers to STDOUT",
},
examples: [
"Plazucchini.authors_treatment_count(author: 'Mockford', limit: 1)",
],
},
:contributors_material_citations => {
description: "Contributors Liberated Material Citations",
params: {
:user => "The user that made the contribution (default: \"tatiana\")",
:limit => "The optional result limit",
:order_mode => "The optional sort order (ASC, DESC, nil)",
:verbose => "Print headers to STDOUT",
},
examples: [
"Plazucchini.contributors_material_citations(user: 'admin', limit: 1)",
],
},
:contributors_pages => {
description: "Contributors Liberated Pages",
params: {
:user => "The user that made the contribution (default: \"tatiana\")",
:limit => "The optional result limit",
:order_mode => "The optional sort order (ASC, DESC, nil)",
:verbose => "Print headers to STDOUT",
},
examples: [
"Plazucchini.contributors_pages(user: 'admin', limit: 1)",
],
},
:contributors_publications => {
description: "Contributors Liberated Publications",
params: {
:user => "The user that made the contribution (default: \"tatiana\")",
:limit => "The optional result limit",
:order_mode => "The optional sort order (ASC, DESC, nil)",
:verbose => "Print headers to STDOUT",
},
examples: [
"Plazucchini.contributors_publications(user: 'admin', limit: 1)",
],
},
:contributors_treatments => {
description: "Contributors Liberated Treatments",
params: {
:user => "The user that made the contribution (default: \"tatiana\")",
:limit => "The optional result limit",
:order_mode => "The optional sort order (ASC, DESC, nil)",
:verbose => "Print headers to STDOUT",
},
examples: [
"Plazucchini.contributors_treatments(user: 'admin', limit: 1)",
],
},
:institutions_cited_materials => {
description: "Institutions Cited Materials",
params: {
:collection_code => "The collection code (default: \"MNHN\")",
:limit => "The optional result limit",
:order_mode => "The optional sort order (ASC, DESC, nil)",
:verbose => "Print headers to STDOUT",
},
examples: [
"Plazucchini.institutions_cited_materials(collection_code: 'INHS', limit: 1)",
],
},
:institutions_distribution_range => {
description: "Institutions Distribution Range",
params: {
:collection_code => "The collection code (default: \"MNHN\")",
:limit => "The optional result limit",
:order_mode => "The optional sort order (ASC, DESC, nil)",
:verbose => "Print headers to STDOUT",
},
examples: [
"Plazucchini.institutions_distribution_range(collection_code: 'INHS', limit: 1)",
],
},
:institutions_journal_occurrences => {
description: "Institutions Journal Occurrences",
params: {
:collection_code => "The collection code (default: \"MNHN\")",
:limit => "The optional result limit",
:order_mode => "The optional sort order (ASC, DESC, nil)",
:verbose => "Print headers to STDOUT",
},
examples: [
"Plazucchini.institutions_journal_occurrences(collection_code: 'INHS', limit: 1)",
],
},
:institutions_specimens_stored => {
description: "Institutions Specimens Stored",
params: {
:collection_code => "The collection code (default: MNHN)",
:limit => "The optional result limit",
:order_mode => "The optional sort order (ASC, DESC, nil)",
:verbose => "Print headers to STDOUT",
},
examples: [
"Plazucchini.institutions_specimens_stored(collection_code: 'INHS', limit: 1)",
],
},
:institutions_stored_types => {
description: "Institutions Stored Types",
params: {
:collection_code => "The collection code (default: MNHN)",
:limit => "The optional result limit",
:order_mode => "The optional sort order (ASC, DESC, nil)",
:verbose => "Print headers to STDOUT",
},
examples: [
"Plazucchini.institutions_stored_types(collection_code: 'INHS', limit: 1)",
],
},
:journals_cited_collections => {
description: "Journals Cited Collections",
params: {
:journal => "The journal name (default: Phytotaxa)",
:limit => "The optional result limit",
:order_mode => "The optional sort order (ASC, DESC, nil)",
:verbose => "Print headers to STDOUT",
},
examples: [
"Plazucchini.journals_cited_collections(journal: 'Zootaxa', limit: 1)",
],
},
:journals_published_figures_count => {
description: "Journals Published Figures Count",
params: {
:journal => "The journal name (default: Zootaxa)",
:limit => "The optional result limit",
:order_mode => "The optional sort order (ASC, DESC, nil)",
:verbose => "Print headers to STDOUT",
},
examples: [
"Plazucchini.journals_published_figures_count(journal: 'Acarologia', limit: 1)",
],
},
:journals_published_material_distribution => {
description: "Journals Published Material Distribution",
params: {
:journal => "The journal name (default: Phytotaxa)",
:limit => "The optional result limit",
:order_mode => "The optional sort order (ASC, DESC, nil)",
:verbose => "Print headers to STDOUT",
},
examples: [
"Plazucchini.journals_published_material_distribution(journal: 'Acarologia', limit: 1)",
],
},
:journals_published_new_species_count => {
description: "Journals Published New Species Count",
params: {
:journal => "The journal name",
:limit => "The optional result limit",
:order_mode => "The optional sort order (ASC, DESC, nil)",
:verbose => "Print headers to STDOUT",
},
examples: [
"Plazucchini.journals_published_new_species_count(journal: 'Acarologia')",
],
},
:journals_published_page_count => {
description: "Journals Published Page Count",
params: {
:journal => "The journal name (default: )",
:limit => "The optional result limit",
:order_mode => "The optional sort order (ASC, DESC, nil)",
:verbose => "Print headers to STDOUT",
},
examples: [
"Plazucchini.journals_published_page_count(journal: 'Acarologia')",
],
},
:journals_published_synonyms => {
description: "Journals Published Synonyms Count",
params: {
:journal => "The journal name",
:limit => "The optional result limit",
:order_mode => "The optional sort order (ASC, DESC, nil)",
:verbose => "Print headers to STDOUT",
},
examples: [
"Plazucchini.journals_published_synonyms(journal: 'Acarologia')",
],
},
:journals_published_tables => {
description: "Journals Published Tables Count",
params: {
:journal => "The journal name",
:limit => "The optional result limit",
:order_mode => "The optional sort order (ASC, DESC, nil)",
:verbose => "Print headers to STDOUT",
},
examples: [
"Plazucchini.journals_published_tables(journal: 'Acarologia')",
],
},
:journals_published_treatment_count => {
description: "Journals Published Treatment Count",
params: {
:journal => "The journal name",
:limit => "The optional result limit",
:order_mode => "The optional sort order (ASC, DESC, nil)",
:verbose => "Print headers to STDOUT",
},
examples: [
"Plazucchini.journals_published_treatment_count(journal: 'Acarologia')",
],
},
:metrics_journal_data_count => {
description: "Metrics Journal Data Count",
params: {
:limit => "The optional result limit",
:order_mode => "The optional sort order (ASC, DESC, nil)",
:verbose => "Print headers to STDOUT",
},
examples: [
"Plazucchini.metrics_journal_data_count(limit: 1)",
],
},
:metrics_user_contribution_count => {
description: "Metrics User Contribution Count",
params: {
:limit => "The optional result limit",
:order_mode => "The optional sort order (ASC, DESC, nil)",
:verbose => "Print headers to STDOUT",
},
examples: [
"Plazucchini.metrics_user_contribution_count(limit: 1)",
],
},
:specimens_with_genes => {
description: "Specimens With Genes",
params: {
:genus_epithet => "The genus (required, default: \"Exobasidium\")",
:limit => "The optional result limit",
:order_mode => "The optional sort order (ASC, DESC, nil)",
:verbose => "Print headers to STDOUT",
},
examples: [
"Plazucchini.specimens_with_genes(genus_epithet: 'Alces', limit: 1)",
],
},
:taxon_materials_citations => {
description: "Taxon Materials Citations",
params: {
:genus_epithet => "The genus of the treatment",
:species_epithet => "The species of the treatment",
:limit => "The optional result limit",
:order_mode => "The optional sort order (ASC, DESC, nil)",
:verbose => "Print headers to STDOUT",
},
examples: [
"Plazucchini.taxon_materials_citations(genus_epithet: 'Alces', species_epithet: 'alces', limit: 1)",
],
},
:taxon_occurrence_by_materials_citation => {
description: "Taxon Occurrence By Material Citation",
params: {
:limit => "The optional result limit",
:order_mode => "The optional sort order (ASC, DESC, nil)",
:verbose => "Print headers to STDOUT",
},
examples: [
"Plazucchini.taxon_occurrence_by_materials_citation(limit: 1)",
],
},
:taxon_specimens_in_collections => {
description: "Taxon Specimens In Collections",
params: {
:genus_epithet => "The genus of the treatment",
:limit => "The optional result limit",
:order_mode => "The optional sort order (ASC, DESC, nil)",
:verbose => "Print headers to STDOUT",
},
examples: [
"Plazucchini.taxon_specimens_in_collections(genus_epithet: 'Allium', limit: 1)",
],
},
:taxon_treatments_for_taxon => {
description: "Taxon Treatments for taxon",
params: {
:genus_epithet => "The genus of the treatment",
:species_epithet => "The species of the treatment",
:limit => "The optional result limit",
:order_mode => "The optional sort order (ASC, DESC, nil)",
:verbose => "Print headers to STDOUT",
},
examples: [],
},
:taxon_treatments_with_keys => {
description: "Taxon Treatments With Keys",
params: {
:genus_epithet => "The genus of the treatment",
:limit => "The optional result limit",
:order_mode => "The optional sort order (ASC, DESC, nil)",
:verbose => "Print headers to STDOUT",
},
examples: [
"Plazucchini.taxon_treatments_with_keys(genus_epithet: 'Allium', limit: 1)",
],
},
:treatments_fetch => {
description: "Treatments Fetch",
params: {
:uuid => "The UUID of the treatment to fetch (required)",
:verbose => "Print headers to STDOUT",
},
examples: [
"Plazucchini.treatments_fetch(uuid: 'D51587EFFFEC9A37F0C01851F8E4F99F')",
],
},
:treatments_search => {
description: "Search treatments",
params: {
:kingdom_epithet => "The kingdom to search (optional)",
:phylum_epithet => "The phylum to search (optional)",
:class_epithet => "The class to search (optional)",
:order_epithet => "The order to search (optional)",
:family_epithet => "The family to search (optional)",
:genus_epithet => "The genus to search (optional)",
:species_epithet => "The species to search (optional)",
:limit => "The search result limit (optional)",
:order_mode => "The optional sort order (ASC, DESC, nil)",
:verbose => "Print headers to STDOUT",
},
examples: [
"Plazucchini.treatments_search(limit: 1)",
"Plazucchini.treatments_search(kingdom_epithet: 'Animalia', limit: 1)",
"Plazucchini.treatments_search(phylum_epithet: 'Arthropoda', limit: 1)",
],
},
:treatments_search_by_doi => {
description: "Search treatments by DOI",
params: {
:doi => "The DOI to search for (required)",
:verbose => "Print headers to STDOUT",
},
examples: [
"Plazucchini.treatments_search_by_doi(doi: '10.5281/zenodo.8117062')",
],
},
:treatments_summary => {
description: "Get a treatment summary",
params: {
:uuid => "The UUID of the treatment (required)",
:verbose => "Print headers to STDOUT",
},
examples: [
"Plazucchini.treatments_summary(uuid: 'D51587EFFFEC9A37F0C01851F8E4F99F')",
],
},
:ping => {
description: "Ping the API (check if the service is alive)",
params: {
:verbose => "Print headers to STDOUT",
},
examples: [],
},
},
},
:syconium => {
description: "Wrapper for OpenAlex API - access research publications and academic data",
api: "https://api.openalex.org",
endpoints: {
},
},
:wikimelon => {
description: "Wrapper for Wikidata API - access linked open knowledge data",
api: "https://www.wikidata.org/w/api.php",
endpoints: {
:query => {
description: "Run a Wikidata SPARQL query",
params: {
:query => "a Wikidata query",
:verbose => "Print headers to STDOUT",
},
examples: [
"Wikimelon.query('SELECT * WHERE { ?s ?p ?o } LIMIT 1')",
"Wikimelon.query(query)",
],
},
:entity => {
description: "Get Wikidata entity data",
params: {
:entity_id => "a Wikidata entity ID",
:revision_id => "a revision ID",
:verbose => "Print headers to STDOUT",
},
examples: [
"Wikimelon.entity('Q13')",
"Wikimelon.entity('Q13', revision_id: 109)",
],
},
},
},
}.freeze