= Relaton-DOI: retrieve bibliographic items using DOI image:https://img.shields.io/gem/v/relaton-doi.svg["Gem Version", link="https://rubygems.org/gems/relaton-doi"] image:https://github.com/relaton/relaton-doi/workflows/macos/badge.svg["Build Status (macOS)", link="https://github.com/relaton/relaton-doi/actions?workflow=macos"] image:https://github.com/relaton/relaton-doi/workflows/windows/badge.svg["Build Status (Windows)", link="https://github.com/relaton/relaton-doi/actions?workflow=windows"] image:https://github.com/relaton/relaton-doi/workflows/ubuntu/badge.svg["Build Status (Ubuntu)", link="https://github.com/relaton/relaton-doi/actions?workflow=ubuntu"] image:https://codeclimate.com/github/relaton/relaton-doi/badges/gpa.svg["Code Climate", link="https://codeclimate.com/github/relaton/relaton-doi"] image:https://img.shields.io/github/issues-pr-raw/relaton/relaton-doi.svg["Pull Requests", link="https://github.com/relaton/relaton-doi/pulls"] image:https://img.shields.io/github/commits-since/relaton/relaton-doi/latest.svg["Commits since latest",link="https://github.com/relaton/relaton-doi/releases"] RelatonDoi is a Ruby gem that implements the https://github.com/metanorma/metanorma-model-iso#iso-bibliographic-item[IsoBibliographicItem model]. You can use it to retrieve metadata of Standards from https://crossref.org, and access such metadata through the `BibliographicItem` object. To collect metadata this gem makes a few requests to the CrossRef API. It may take a few seconds to get the metadata. == Installation Add this line to your application's Gemfile: [source,ruby] ---- gem 'relaton-doi' ---- And then execute: [source,sh] ---- $ bundle install ---- Or install it yourself as: [source,ruby] ---- $ gem install relaton-doi ---- == Usage === Retrieving items of known type using DOI If the resulting bibliographic item returned from CrossRef is a known Relaton flavor, such as a NIST or IEEE standard, the corresponding Relaton class object will be returned via the call. [source,ruby] ---- require 'relaton_doi' => true # get NIST standard RelatonDoi::Crossref.get "doi:10.6028/nist.ir.8245" [relaton-doi] (doi:10.6028/nist.ir.8245) Fetching from search.crossref.org ... [relaton-doi] (doi:10.6028/nist.ir.8245) Found: `10.6028/nist.ir.8245` => # # # # #