Skip to content

Commit

Permalink
fix: fix missing search options
Browse files Browse the repository at this point in the history
* Add Columns and Tags support to global options

* Remove overlapping Columns field

* Update Column+Tag global option docs

#3
  • Loading branch information
hatt authored and Supamiu committed Sep 15, 2018
1 parent b39e8c8 commit a902fda
Show file tree
Hide file tree
Showing 2 changed files with 29 additions and 19 deletions.
29 changes: 29 additions & 0 deletions src/model/xivapi-options.ts
Expand Up @@ -8,4 +8,33 @@ export interface XivapiOptions {
* for example: language=fr&string=LeAwsome will search for LeAwesome on the field Name_fr.
*/
language?: string;

/**
* Pull specific columns from the data. By default the list just provides the ID, and result provides every column.
* You can request specific pieces of information from a list or result by plugging in the column names.
* For extended content you use dot notation to access it, for example:
*
* To access the data in Items or a search on the Items index, you could request with these columns:
*
* columns=Items.0.Name,Items.1.Name
* If you imagine an array having 50 items, this could be tedious and will eat into your maximum column count.
* You can therefore use a count format, eg:
*
* columns=Items.*50.Name
* This will return 50 rows from the column Items using the index Name
*
* There are restrictions on the number of columns you can query, the column character length and the maximum items.
* By default these are pretty strict so it is recommended to create a Developer App to be provided a key to increase your limits.
*/
columns?: string[];

/**
* You can add tracking counters to your app for whatever purpose using "tags". Tags will appear in your dashboard with a counter
* next to them. You can have as many tags you would like and counts will store for a period of 30 days before taping off
* and being removed if they become inactive.
*
* A tag must be alpha numeric and allows dashes and underscores, however this is not checked or validated until it hits XivAPI.
* A GitHub issue to add support for this to TypeScript can be found at https://github.com/Microsoft/TypeScript/issues/6579
*/
tags?: string[];
}
19 changes: 0 additions & 19 deletions src/model/xivapi-request-options.ts
Expand Up @@ -27,25 +27,6 @@ export interface XivapiRequestOptions extends XivapiOptions {
*/
ids?: number[];

/**
* Pull specific columns from the data. By default the list just provides the ID.
* You can request specific pieces of information from a list by plugging in the column names.
* For extended content you use dot notation to access it, for example:
*
* To access the data in Items these you would request the columns:
*
* columns=Items.0.Name,Items.1.Name
* If you imagine an array having 50 items, this could be tedious and will eat into your maximum column count.
* You can therefore use a count format, eg:
*
* columns=Items.*50.Name
* This will return 50 rows from the column Items using the index Name
*
* There are restrictions on the number of columns you can query, the column character length and the maximum items.
* By default these are pretty strict so it is recommended to create a Developer App to be provided a key to increase your limits.
*/
columns?: string[];

/**
* View the current column and schema information of the content. This will provide 2 objects: columns and schema.
*
Expand Down

0 comments on commit a902fda

Please sign in to comment.