Skip to content
Kimon Kar edited this page Sep 5, 2019 · 7 revisions
xiv.data

.content()

https://xivapi.com/docs/Game-Data#content

Get an array of all content names.

Returns: [ string ]


.list(name, params)

https://xivapi.com/docs/Game-Data#lists

Get a paginated list of content for the specified content name.

Params object:

Parameter Type Description
limit number Limit the number of results.
ids CSV* Filter results down to specific ids.
page string The page to navigate to. See Pagination.

*CSV: accepts either string (e.g. '35,67,201') or array (e.g. [35, 67, 201])

Returns: { Pagination, Results }


.get(name, id)

https://xivapi.com/docs/Game-Data#data

Get a specific object from the given content name with the specified ID.

Returns: Object


.servers()

https://xivapi.com/docs/Game-Data#servers List all servers.

> xiv.data.servers()
[ 'Adamantoise',
  'Aegis',
  'Alexander',
  'Anima',
  'Asura',
  ...
]

.datacenters()

https://xivapi.com/docs/Game-Data#data-center List servers grouped by datacenter.

> xiv.data.datacenters()
{
  Aether: [Array],
  Chaos: [Array],
  Elemental: [Array],
  Gaia: [Array],
  Mana: [Array],
  Primal: [Array]
}
Clone this wiki locally