def doi(self, doi, only_message=True):
request_url = build_url_endpoint(<EOL>'<STR_LIT:/>'.join([self.ENDPOINT, doi])<EOL>)<EOL>request_params = {}<EOL>result = self.do_http_request(<EOL>'<STR_LIT>',<EOL>request_url,<EOL>data=request_params,<EOL>custom_header=str(self.etiquette)<EOL>)<EOL>if result.status_code == <NUM_LIT>:<EOL><INDENT>return<EOL><DEDENT>result = result.json()<EOL>return result['<STR_LIT:message>'] if only_message is True else result<EOL>
This method retrieve the DOI metadata related to a given DOI
number.

args: Crossref DOI id (String)

return: JSON

Example:
    >>> from crossref.restful import Works
    >>> works = Works()
    >>> works.doi('10.1590/S0004-28032013005000001')
    {'is-referenced-by-count': 6, 'reference-count': 216, 'DOI': '10.1590/s0004-28032013005000001',
    'subtitle': [], 'issued': {'date-parts': [[2013, 4, 19]]}, 'source': 'Crossref',
    'short-container-title': ['Arq. Gastroenterol.'], 'references-count': 216, 'short-title': [],
    'deposited': {'timestamp': 1495911725000, 'date-time': '2017-05-27T19:02:05Z',
    'date-parts': [[2017, 5, 27]]}, 'ISSN': ['0004-2803'], 'type': 'journal-article',
    'URL': 'http://dx.doi.org/10.1590/s0004-28032013005000001',
    'indexed': {'timestamp': 1496034748592, 'date-time': '2017-05-29T05:12:28Z',
    'date-parts': [[2017, 5, 29]]}, 'content-domain': {'crossmark-restriction': False, 'domain': []},
    'created': {'timestamp': 1374613284000, 'date-time': '2013-07-23T21:01:24Z',
    'date-parts': [[2013, 7, 23]]}, 'issn-type': [{'value': '0004-2803', 'type': 'electronic'}],
    'page': '81-96', 'volume': '50', 'original-title': [], 'subject': ['Gastroenterology'],
    'relation': {}, 'container-title': ['Arquivos de Gastroenterologia'], 'member': '530',
    'prefix': '10.1590', 'published-print': {'date-parts': [[2013, 4, 19]]},
    'title': ['3rd BRAZILIAN CONSENSUS ON Helicobacter pylori'],
    'publisher': 'FapUNIFESP (SciELO)', 'alternative-id': ['S0004-28032013000200081'],
    'abstract': '<jats:p>Significant abstract data.....  .</jats:p>',
    'author': [{'affiliation': [{'name': 'Universidade Federal de Minas Gerais,  BRAZIL'}],
    'family': 'Coelho', 'given': 'Luiz Gonzaga'}, {'affiliation': [
    {'name': 'Universidade Federal do Rio Grande do Sul,  Brazil'}], 'family': 'Maguinilk',
    'given': 'Ismael'}, {'affiliation': [
    {'name': 'Presidente de Honra do Núcleo Brasileiro para Estudo do Helicobacter,  Brazil'}],
    'family': 'Zaterka', 'given': 'Schlioma'}, {'affiliation': [
    {'name': 'Universidade Federal do Piauí,  Brasil'}], 'family': 'Parente', 'given': 'José Miguel'},
    {'affiliation': [{'name': 'Universidade Federal de Minas Gerais,  BRAZIL'}],
    'family': 'Passos', 'given': 'Maria do Carmo Friche'}, {'affiliation': [
    {'name': 'Universidade de São Paulo,  Brasil'}], 'family': 'Moraes-Filho',
    'given': 'Joaquim Prado P.'}], 'score': 1.0, 'issue': '2'}