name – [str] Full scientific name potentially with authorship (required)

rank – [str] The rank given as our rank enum. (optional)

kingdom – [str] If provided default matching will also try to match against this
if no direct match is found for the name alone. (optional)

phylum – [str] If provided default matching will also try to match against this
if no direct match is found for the name alone. (optional)

class – [str] If provided default matching will also try to match against this
if no direct match is found for the name alone. (optional)

order – [str] If provided default matching will also try to match against this
if no direct match is found for the name alone. (optional)

family – [str] If provided default matching will also try to match against this
if no direct match is found for the name alone. (optional)

genus – [str] If provided default matching will also try to match against this
if no direct match is found for the name alone. (optional)

strict – [bool] If True it (fuzzy) matches only the given name, but never a
taxon in the upper classification (optional)

verbose – [bool] If True show alternative matches considered which had been rejected.

offset – [int] Record to start at. Default: 0

limit – [int] Number of results to return. Default: 100

A list for a single taxon with many slots (with verbose=False - default), or a
list of length two, first element for the suggested taxon match, and a data.frame
with alternative name suggestions resulting from fuzzy matching (with verbose=True).

If you don’t get a match GBIF gives back a list of length 3 with slots synonym,
confidence, and matchType='NONE'.

facet – [str] A list of facet names used to retrieve the 100 most frequent values
for a field. Allowed facets are: datasetKey, higherTaxonKey, rank, status,
isExtinct, habitat, and nameType. Additionally threat and nomenclaturalStatus
are legal values but not yet implemented, so data will not yet be returned for them. (optional)

facetMincount – [str] Used in combination with the facet parameter. Set
facetMincount={#} to exclude facets with a count less than {#}, e.g.
http://bit.ly/1bMdByP only shows the type value ACCEPTED because the other
statuses have counts less than 7,000,000 (optional)

facetMultiselect – [bool] Used in combination with the facet parameter. Set
facetMultiselect=True to still return counts for values that are not currently
filtered, e.g. http://bit.ly/19YLXPO still shows all status values even though
status is being filtered by status=ACCEPTED (optional)

type – [str] Type of name. One of occurrence, checklist, or metadata. (optional)

hl – [bool] Set hl=True to highlight terms matching the query when in fulltext
search fields. The highlight will be an emphasis tag of class gbifH1 e.g.
q='plant',hl=True. Fulltext search fields include: title, keyword, country,
publishingcountry, publishingorganizationtitle, hostingorganizationtitle, and
description. One additional full text field is searched which includes information from
metadata documents, but the text of this field is not returned in the response. (optional)

frompygbifimportspecies# Look up names like mammaliaspecies.name_lookup(q='mammalia')# Pagingspecies.name_lookup(q='mammalia',limit=1)species.name_lookup(q='mammalia',limit=1,offset=2)# large requests, use offset parameterfirst=species.name_lookup(q='mammalia',limit=1000)second=species.name_lookup(q='mammalia',limit=1000,offset=1000)# Get all data and parse it, removing descriptions which can be quite longspecies.name_lookup('Helianthus annuus',rank="species",verbose=True)# Get all data and parse it, removing descriptions field which can be quite longout=species.name_lookup('Helianthus annuus',rank="species")res=out['results'][z.pop('descriptions',None)forzinres]res# Fuzzy searchingspecies.name_lookup(q='Heli',rank="genus")# Limit records to certain numberspecies.name_lookup('Helianthus annuus',rank="species",limit=2)# Query by habitatspecies.name_lookup(habitat="terrestrial",limit=2)species.name_lookup(habitat="marine",limit=2)species.name_lookup(habitat="freshwater",limit=2)# Using facetingspecies.name_lookup(facet='status',limit=0,facetMincount='70000')species.name_lookup(facet=['status','higherTaxonKey'],limit=0,facetMincount='700000')species.name_lookup(facet='nameType',limit=0)species.name_lookup(facet='habitat',limit=0)species.name_lookup(facet='datasetKey',limit=0)species.name_lookup(facet='rank',limit=0)species.name_lookup(facet='isExtinct',limit=0)# text highlightingspecies.name_lookup(q='plant',hl=True,limit=30)# Lookup by datasetKeyspecies.name_lookup(datasetKey='3f8a1297-3259-4700-91fc-acc4170b27ce')

frompygbifimportspeciesspecies.name_usage(key=1)# Name usage for a taxonomic namespecies.name_usage(name='Puma',rank="GENUS")# All name usagesspecies.name_usage()# References for a name usagespecies.name_usage(key=2435099,data='references')# Species profiles, descriptionsspecies.name_usage(key=3119195,data='speciesProfiles')species.name_usage(key=3119195,data='descriptions')species.name_usage(key=2435099,data='children')# Vernacular names for a name usagespecies.name_usage(key=3119195,data='vernacularNames')# Limit number of results returnedspecies.name_usage(key=3119195,data='vernacularNames',limit=3)# Search for names by dataset with datasetKey parameterspecies.name_usage(datasetKey="d7dddbf4-2cf0-4f39-9b2a-bb099caae36c")# Search for a particular languagespecies.name_usage(key=3119195,language="FRENCH",data='vernacularNames')