summaryrefslogtreecommitdiff
path: root/data/docs/11
diff options
context:
space:
mode:
authorYorhel <git@yorhel.nl>2018-02-08 16:06:17 +0100
committerYorhel <git@yorhel.nl>2018-02-08 16:12:07 +0100
commit93b79ef9ebafcfccd0d239ffd06e2b547e209e3d (patch)
tree98d96f024d00bf318b16243518e53c2977136202 /data/docs/11
parent3f3a4d9810bb2483a89442b85d438639f26ecb7e (diff)
Store d+ pages in the DB as versioned entries + use markdown
This touches a bunch of things: - Adds a new first-class database entry type - Removes the d+.+.+ BBCode link syntax, adds a new d+#+ and d+#+.+ link syntax (references have been updated where possible) - Adds a new dependency on Text::MultiMarkdown
Diffstat (limited to 'data/docs/11')
-rw-r--r--data/docs/111870
1 files changed, 0 insertions, 1870 deletions
diff --git a/data/docs/11 b/data/docs/11
deleted file mode 100644
index 77e7cf66..00000000
--- a/data/docs/11
+++ /dev/null
@@ -1,1870 +0,0 @@
-:TITLE:Public Database API
-:INC:index
-
-:SUB:Introduction
-<p>
- This document describes the public API of VNDB and is intended to be read by
- programmers. This API allows programs and websites to access (parts of) the
- VNDB database without actually visiting the website.
- <br /><br />
- In addition to this real-time API, we also provide some information in the
- form of <a href="/d14">database dumps</a>.
- <br /><br />
-</p>
-
-<b>Usage terms</b>
-<p>
- This service is free for non-commercial use. The API is provided on a
- best-effort basis, no guarantees are made about the stability or applicability
- of this service.
-</p>
-<br />
-
-<b>Design goals</b>
-<ul>
- <li>
- Simple in implementation of both client and server. "Simple" here means that
- it shouldn't take much code to write a secure and full implementation and that
- client applications shouldn't require huge dependency trees just to use this API.
- </li>
- <li>Powerful: Not as powerful as raw SQL, but not as rigid as commonly used REST or RPC protocols.</li>
- <li>High-level: common applications need to perform only few actions to get what they want.</li>
- <li>Fast: minimal bandwidth overhead and simple and customizable queries.</li>
-</ul>
-<br />
-
-<b>Design overview</b>
-<ul>
- <li>TCP-based, all communication between the client and the server is done
- using one TCP connection. This connection stays alive until it is explicitely
- closed by either the client or the server.</li>
- <li>Request/response, client sends a request and server replies with a response.</li>
- <li>Session-based: clients are required to login before issuing commands to
- the server. A session is created by issuing the 'login' command, this session
- stays valid for the lifetime of the TCP connection.</li>
- <li><b>Everything</b> sent between the client and the server is encoded in UTF-8.</li>
-</ul>
-<br />
-
-<b>Limits</b>
-<p>The following limits are enforced by the server, in order to limit the
-server resources and prevent abuse of this service.</p>
-<ul>
- <li>10 connections per IP. All connections that are opened after reaching this limit will be immediately closed.</li>
- <li>200 commands per 10 minutes per ip. Server will reply with a 'throttled' error (type="cmd") when reaching this limit.</li>
- <li>
- 1 second of SQL time per minute per ip. SQL time is the total time taken to
- run the database queries for each command. This depends on both the command
- (filters and get flags) and server load, and is thus not very predictable.
- Server will reply with a 'throttled' error with type="sql" upon reaching
- this limit.
- </li>
- <li>Each command returns at most 25 results, with the exception of get
- votelist/vnlist/wishlist, which returns at most 100 results.</li>
-</ul>
-<p>
- These limits may sound strict, but in practice you won't have to worry much
- about it. As long as your application properly waits when the server replies
- with a "throttle" error, everything will be handled automatically. In the event
- that your application does require more resources, don't hesitate to ask.
-</p>
-
-
-<br />
-<b>Connection info:</b>
-<dl>
- <dt>Host</dt><dd>api.vndb.org</dd>
- <dt>Port (plain tcp)</dt><dd>19534 ('VN')</dd>
- <dt>Port (TLS)</dt><dd>19535<br />For improved security, make sure to verify that the certificate is valid for 'api.vndb.org' and is signed by a trusted root (in particular, by <a href="https://letsencrypt.org/certificates/">Let's Encrypt</a>).</dd>
-</dl>
-
-
-
-:SUB:Request/response syntax
-<p>
- The VNDB API uses the JSON format for data in various places, this document assumes
- you are familiar with it. See <a href="http://json.org/">JSON.org</a> for a quick
- overview and <a href="http://www.ietf.org/rfc/rfc4627.txt?number=4627">RFC 4627</a>
- for the glory details.
- <br /><br />
- The words <i>object</i>, <i>array</i>, <i>value</i>, <i>string</i>,
- <i>number</i> and <i>integer</i> refer to the JSON data types. In addition the following
- definitions are used in this document:
-</p>
-<dl>
- <dt><i>request</i> or <i>command</i></dt><dd>
- Message sent from the client to the server.
- </dd><dt><i>response</i></dt><dd>
- Message sent from the server to the client.
- </dd><dt><i>whitespace</i></dt><dd>
- Any sequence of the following characters: space, tab, line feed and carriage
- return. (hexadecimal: 20, 09, 0A, 0D, respectively). This is in line with the
- definition of whitespace in the JSON specification.
- </dd><dt><i>date</i></dt><dd>
- A <i>string</i> signifying a date (in particular: release date). The
- following formats are used: "yyyy" (when day and month are unknown), "yyyy-mm"
- (when day is unknown) "yyyy-mm-dd", and "tba" (To Be Announced). If the year is
- not known and the date is not "tba", the special value <b>null</b> is used.
- </dd>
-</dl>
-<br />
-
-<b>Message format</b>
-<p>
- A message is formatted as a command or response name, followed by any number of
- arguments, followed by the End Of Transmission character (04 in hexadecimal).
- Arguments are separated by one or more whitespace characters, and any sequence
- of whitespace characters is allowed before and after the message.<br />
- The command or response name is an unescaped string containing only lowercase
- alphabetical ASCII characters, and indicates what kind of command or response
- this message contains.<br />
- An argument can either be an unescaped string (not containing whitespace), any
- JSON value, or a filter string. The following two examples demonstrate a
- 'login' command, with an object as argument. Both messages are equivalent, as
- the whitespace is ignored. '0x04' is used to indicate the End Of Transmission
- character.
-</p>
-<pre>
- login {"protocol":1,"username":"ayo"}<b class="standout">0x04</b>
-</pre><pre>
- login {
- "protocol" : 1,
- "username" : "ayo"
- }
- <b class="standout">0x04</b>
-</pre>
-The 0x04 byte will be ommitted in the other examples in this document. It is
-however still required.<br />
-
-<br />
-<b>Filter string syntax</b>
-<p>
- Some commands accept a filter string as argument. This argument is formatted
- similar to boolean expressions in most programming languages. A filter consists
- of one or more <i>expressions</i>, separated by the boolean operators "and" or
- "or" (lowercase). Each filter expression can be surrounded by parentheses to
- indicate precedence, the filter argument itself must be surrounded by parentheses.
- <br />
- An <i>expression</i> consists of a <i>field name</i>, followed by an
- <i>operator</i> and a <i>value</i>. The field name must consist entirely of
- lowercase alphanumeric characters and can also contain an underscore. The
- operator must be one of the following characters: =, !=, &lt;, &lt;=, &gt;,
- &gt;= or ~. The <i>value</i> can be any valid JSON value. Whitespace
- characters are allowed, but not required, between all expressions, field names,
- operators and values.<br />
- The following two filters are equivalent:
-</p>
-<pre>
- (title~"osananajimi"or(id=2))
-</pre><pre>
- (
- id = 2
- or
- title ~ "osananajimi"
- )
-</pre>
-<p>More complex filters are also possible:</p>
-<pre>
- ((platforms = ["win", "ps2"] or languages = "ja") and released > "2009-01-10")
-</pre>
-<p>See the individual commands for more details.</p>
-
-
-:SUB:The 'login' command
-<pre>
- login {"protocol":1,"client":"test","clientver":0.1,"username":"ayo","password":"hi-mi-tsu!"}
-</pre>
-<p>
- Every client is required to login before issuing other commands. The login
- command accepts a JSON object as argument. This object has the following members:
-</p>
-<dl>
- <dt>protocol</dt><dd>An integer that indicates which protocol version the client implements. Must be 1.</dd>
- <dt>client</dt><dd>
- A string identifying the client application. Between the 3 and 50 characters,
- must contain only alphanumeric ASCII characters, space, underscore and hyphens.
- When writing a client, think of a funny (unique) name and hardcode it into
- your application.
- </dd><dt>clientver</dt><dd>A number or string indicating the software version of the client.</dd>
- <dt>username</dt><dd>(optional) String containing the username of the person using the client.</dd>
- <dt>password</dt><dd>(optional) String, password of that user in plain text.</dd>
-</dl>
-<p>
- The server replies with either 'ok' (no arguments), or 'error' (see below).
- Note that logging in using a username and password is optional, but some
- commands are only available when logged in. It is strongly recommended to
- connect with TLS when logging in with a username and password.
-</p>
-
-
-:SUB:The 'dbstats' command
-<p>
- This command gives the global database statistics that are visible in the main
- menu of the site. The command is simply:
-</p>
-<pre>
- dbstats
-</pre>
-<p>And the response has the following format:</p>
-<pre>
- dbstats <b class="standout">stats</b>
-</pre>
-<p>Where <i>stats</i> is a JSON object with integer values. Example response:</p>
-<pre>
- dbstats {"users":49084,
- "threads":3998,
- "tags":1627,
- "releases":28071,
- "producers":3456,
- "chars":14046,
- "posts":52470,
- "vn":13051,
- "traits":1272}
-</pre>
-
-
-:SUB:The 'get' command
-<p>
- This command is used to fetch data from the database. It accepts 4 arguments:
- the type of data to fetch (e.g. visual novels or producers), what part of that
- data to fetch (e.g. only the VN titles, or the descriptions and relations as
- well), a filter expression, and lastly some options.
-</p>
-<pre>
- get <b class="standout">type flags filters options</b>
-</pre>
-<p>
- <i>type</i> and <i>flags</i> are unescaped strings. The accepted values for <i>type</i> are
- documented below. <i>flags</i> is a comma-separated list of flags indicating what
- info to fetch. The filters, available flags and their meaning are documented
- separately for each type. The last <i>options</i> argument is optional, and
- influences the behaviour of the returned results. When present, <i>options</i>
- should be a JSON object with the following members (all are optional):
-</p>
-<dl>
- <dt>page</dt><dd>
- integer, used for pagination. Page 1 (the default) returns the first 10
- results (1-10), page 2 returns the following 10 (11-20), etc. (The actual
- number of results per page can be set with the "results" option below).
- </dd><dt>results</dt><dd>
- integer, maximum number of results to return. Also affects the "page" option
- above. For example: with "page" set to 2 and "results" set to 5, the second
- five results (that is, results 6-10) will be returned. Default: 10.
- </dd><dt>sort</dt><dd>
- string, the field to order the results by. The accepted field names differ
- per type, the default sort field is the ID of the database entry.
- </dd>
- <dt>reverse</dt><dd>boolean, default false. Set to true to reverse the order of the results.</dd>
-</dl>
-<p>
- The following example will fetch basic information and information about the
- related anime of the visual novel with id = 17:
-</p>
-<pre>
- get vn basic,anime (id = 17)
-</pre>
-<p>
- The server will reply with a 'results' message, this message is followed by a
- JSON object describing the results. This object has three members: 'num', which
- is an integer indicating the number of results returned, 'more', which is true
- when there are more results available (i.e. increasing the <i>page</i> option
- described above will give new results) and 'items', which contains the results
- as an array of objects. For example, the server could reply to the previous
- command with the following message:
-</p>
-<pre>
- results {"num":1, "more":false, "items":[{
- "id": 17, "title": "Ever17 -the out of infinity-", "original": null,
- "released": "2002-08-29", "languages": ["en","ja","ru","zh"],
- "platforms": ["drc","ps2","psp","win"],"anime": []
- }]}
-</pre>
-<p>
- Note that the actual result from the server can (and likely will) be formatted
- differently and that the order of the members may not be the same. What each
- member means and what possible values they can have differs per type and is
- documented below.
-</p>
-
-:SUBSUB:get vn
-<p>The following members are returned from a 'get vn' command:</p>
-<table style="margin: 5px 2%; width: 95%">
- <thead><tr>
- <td style="width: 80px">Member</td>
- <td style="width: 50px">Flag</td>
- <td style="width: 90px">Type</td>
- <td style="width: 40px">null</td>
- <td>Description</td>
- </tr></thead>
- <tr class="odd">
- <td>id</td>
- <td>-</td>
- <td>integer</td>
- <td>no</td>
- <td>Visual novel ID</td>
- </tr>
- <tr>
- <td>title</td>
- <td>basic</td>
- <td>string</td>
- <td>no</td>
- <td>Main title</td>
- </tr>
- <tr class="odd">
- <td>original</td>
- <td>basic</td>
- <td>string</td>
- <td>yes</td>
- <td>Original/official title.</td>
- </tr>
- <tr>
- <td>released</td>
- <td>basic</td>
- <td>date (string)</td>
- <td>yes</td>
- <td>Date of the first release.</td>
- </tr>
- <tr class="odd">
- <td>languages</td>
- <td>basic</td>
- <td>array of strings</td>
- <td>no</td>
- <td>Can be an empty array when nothing has been released yet.</td>
- </tr>
- <tr>
- <td>orig_lang</td>
- <td>basic</td>
- <td>array of strings</td>
- <td>no</td>
- <td>Language(s) of the first release. Can be an empty array.</td>
- </tr>
- <tr class="odd">
- <td>platforms</td>
- <td>basic</td>
- <td>array of strings</td>
- <td>no</td>
- <td>Can be an empty array when unknown or nothing has been released yet.</td>
- </tr>
- <tr>
- <td>aliases</td>
- <td>details</td>
- <td>string</td>
- <td>yes</td>
- <td>Aliases, separated by newlines.</td>
- </tr>
- <tr class="odd">
- <td>length</td>
- <td>details</td>
- <td>integer</td>
- <td>yes</td>
- <td>Length of the game, 1-5</td>
- </tr>
- <tr>
- <td>description</td>
- <td>details</td>
- <td>string</td>
- <td>yes</td>
- <td>Description of the VN. Can include formatting codes as described in <a href="/d9.3">d9.3</a>.</td>
- </tr>
- <tr class="odd">
- <td>links</td>
- <td>details</td>
- <td>object</td>
- <td>no</td>
- <td>
- Contains the following members:<br />
- "wikipedia", string, name of the related article on the English Wikipedia.<br />
- "encubed", string, the URL-encoded tag used on <a href="http://novelnews.net/">encubed</a>.<br />
- "renai", string, the name part of the url on <a href="http://renai.us/">renai.us</a>.<br />
- All members can be <b>null</b> when no links are available or known to us.
- </td>
- </tr>
- <tr>
- <td>image</td>
- <td>details</td>
- <td>string</td>
- <td>yes</td>
- <td>HTTP link to the VN image.</td>
- </tr>
- <tr class="odd">
- <td>image_nsfw</td>
- <td>details</td>
- <td>boolean</td>
- <td>no</td>
- <td>Whether the VN image is flagged as NSFW or not.</td>
- </tr>
- <tr>
- <td>anime</td>
- <td>anime</td>
- <td>array of objects</td>
- <td>no</td>
- <td>
- (Possibly empty) list of anime related to the VN, each object has the following members:<br />
- "id", integer, <a href="http://anidb.net/">AniDB</a> ID<br />
- "ann_id", integer, <a href="http://animenewsnetwork.com/">AnimeNewsNetwork</a> ID<br />
- "nfo_id", string, <a href="http://animenfo.com/">AnimeNfo</a> ID<br />
- "title_romaji", string<br />
- "title_kanji", string<br />
- "year", integer, year in which the anime was aired<br />
- "type", string<br />
- All members except the "id" can be <b>null</b>. Note that this data is courtesy of AniDB,
- and may not reflect the latest state of their information due to caching.
- </td>
- </tr>
- <tr class="odd">
- <td>relations</td>
- <td>relations</td>
- <td>array of objects</td>
- <td>no</td>
- <td>
- (Possibly empty) list of related visual novels, each object has the following members:<br />
- "id", integer<br />
- "relation", string, relation to the VN<br />
- "title", string, (romaji) title<br />
- "original", string, original/official title, can be <b>null</b><br />
- "official", boolean.
- </td>
- </tr>
- <tr>
- <td>tags</td>
- <td>tags</td>
- <td>array of arrays</td>
- <td>no</td>
- <td>
- (Possibly empty) list of tags linked to this VN. Each tag is represented as
- an array with three elements:<br />
- tag id (integer),<br />
- score (number between 0 and 3),<br />
- spoiler level (integer, 0=none, 1=minor, 2=major)<br />
- Only tags with a positive score are included. Note that this list may be
- relatively large - more than 50 tags for a VN is quite possible.<br />
- General information for each tag is available in the <a href="/d14.2">tags
- dump</a>. Keep in mind that it is possible that a tag has only recently been
- added and is not available in the dump yet, though this doesn't happen
- often.
- </td>
- </tr>
- <tr class="odd">
- <td>popularity</td>
- <td>stats</td>
- <td>number</td>
- <td>no</td>
- <td>Between 0 (unpopular) and 100 (most popular).</td>
- </tr>
- <tr>
- <td>rating</td>
- <td>stats</td>
- <td>number</td>
- <td>no</td>
- <td>Bayesian rating, between 1 and 10.</td>
- </tr>
- <tr class="odd">
- <td>votecount</td>
- <td>stats</td>
- <td>integer</td>
- <td>no</td>
- <td>Number of votes.</td>
- </tr>
- <tr>
- <td>screens</td>
- <td>screens</td>
- <td>array of objects</td>
- <td>no</td>
- <td>
- (Possibly empty) list of screenshots, each object has the following members:<br />
- "image", string, URL of the full-size screenshot<br />
- "rid", integer, release ID<br />
- "nsfw", boolean<br />
- "height", integer, height of the full-size screenshot<br />
- "width", integer, width of the full-size screenshot
- </td>
- </tr>
- <tr class="odd">
- <td>staff</td>
- <td>staff</td>
- <td>array of objects</td>
- <td>no</td>
- <td>
- (Possibly empty) list of staff related to the VN, each object has the following members:<br />
- "sid", integer, staff ID<br />
- "aid", integer, alias ID<br />
- "name", string<br />
- "original", string, possibly null<br />
- "role", string<br />
- "note", string, possibly null
- </td>
- </tr>
-</table>
-<p>Sorting is possible on the following fields: id, title, released, popularity, rating, votecount.</p><br />
-
-<p>'get vn' accepts the following filter expressions:</p>
-<table style="margin: 5px 2%; width: 95%">
- <thead><tr>
- <td style="width: 80px">Field</td>
- <td style="width: 90px">Value</td>
- <td style="width: 90px">Operators</td>
- <td>&nbsp;</td>
- </tr></thead>
- <tr class="odd">
- <td>id</td>
- <td>integer<br />array of integers</td>
- <td>= != &gt; &gt;= &lt; &lt;=<br />= !=</td>
- <td>
- When you need to fetch info about multiple VNs, it is recommended to do so
- in one command using an array of integers as value. e.g. (id = [7,11,17]).
- </td>
- </tr>
- <tr>
- <td>title</td>
- <td>string</td>
- <td>= != ~</td>
- <td>&nbsp;</td>
- </tr>
- <tr class="odd">
- <td>original</td>
- <td>null<br />string</td>
- <td>= !=<br />= != ~</td>
- <td>&nbsp;</td>
- </tr>
- <tr>
- <td>firstchar</td>
- <td>null<br />string</td>
- <td>= !=<br />= !=</td>
- <td>
- Filter by the first character of the title, similar to the
- <a href="http://vndb.org/v/all">VN browser interface</a>. The character
- must either be a lowercase 'a' to 'z', or null to match all titles not
- starting with an alphabetic character.
- </td>
- </tr>
- <tr class="odd">
- <td>released</td>
- <td>null<br />date (string)</td>
- <td>= !=<br />= != &gt; &gt;= &lt; &lt;=</td>
- <td>
- Note that matching on partial dates (released = "2009") doesn't do what
- you want, use ranges instead, e.g. (released &gt; "2008" and released &lt;= "2009").
- </td>
- </tr>
- <tr>
- <td>platforms</td>
- <td>null<br />string<br />array of strings</td>
- <td><br />= !=</td>
- <td>&nbsp;</td>
- </tr>
- <tr class="odd">
- <td>languages</td>
- <td>null<br />string<br />array of strings</td>
- <td><br />= !=</td>
- <td>&nbsp;</td>
- </tr>
- <tr>
- <td>orig_lang</td>
- <td>string<br />array of strings</td>
- <td>= !=</td>
- <td>&nbsp;</td>
- </tr>
- <tr class="odd">
- <td>search</td>
- <td>string</td>
- <td>~</td>
- <td>
- This is not an actual field, but performs a search on the titles of the visual
- novel and its releases. Note that the algorithm of this search may change and
- that it can use a different algorithm than the search function on the website.
- </td>
- </tr>
- <tr>
- <td>tags</td>
- <td>int<br />array of ints</td>
- <td>= !=</td>
- <td>
- Find VNs by tag. When providing an array of ints, the '=' filter will return
- VNs that are linked to any (not all) of the given tags, the '!=' filter will
- return VNs that are not linked to any of the given tags. You can combine
- multiple tags filters with 'and' and 'or' to get the exact behavior you
- need.<br />
- This filter may used cached data, it may take up to 24 hours
- before a VN will have its tag updated with respect to this filter.<br />
- VNs that are linked to childs of the given tag are also included.<br />
- Be warned that this filter ignores spoiler settings, fetch the tags
- associated with the returned VN to verify the spoiler level.
- </td>
- </tr>
-</table>
-
-:SUBSUB:get release
-<p>Returned members:</p>
-<table style="margin: 5px 2%; width: 95%">
- <thead><tr>
- <td style="width: 80px">Member</td>
- <td style="width: 50px">Flag</td>
- <td style="width: 90px">Type</td>
- <td style="width: 40px">null</td>
- <td>Description</td>
- </tr></thead>
- <tr class="odd">
- <td>id</td>
- <td>-</td>
- <td>integer</td>
- <td>no</td>
- <td>Release ID</td>
- </tr>
- <tr>
- <td>title</td>
- <td>basic</td>
- <td>string</td>
- <td>no</td>
- <td>Release title (romaji)</td>
- </tr>
- <tr class="odd">
- <td>original</td>
- <td>basic</td>
- <td>string</td>
- <td>yes</td>
- <td>Original/official title of the release.</td>
- </tr>
- <tr>
- <td>released</td>
- <td>basic</td>
- <td>date (string)</td>
- <td>yes</td>
- <td>Release date</td>
- </tr>
- <tr class="odd">
- <td>type</td>
- <td>basic</td>
- <td>string</td>
- <td>no</td>
- <td>"complete", "partial" or "trial"</td>
- </tr>
- <tr>
- <td>patch</td>
- <td>basic</td>
- <td>boolean</td>
- <td>no</td>
- <td>&nbsp;</td>
- </tr>
- <tr class="odd">
- <td>freeware</td>
- <td>basic</td>
- <td>boolean</td>
- <td>no</td>
- <td>&nbsp;</td>
- </tr>
- <tr>
- <td>doujin</td>
- <td>basic</td>
- <td>boolean</td>
- <td>no</td>
- <td>&nbsp;</td>
- </tr>
- <tr class="odd">
- <td>languages</td>
- <td>basic</td>
- <td>array of strings</td>
- <td>no</td>
- <td>&nbsp;</td>
- </tr>
- <tr>
- <td>website</td>
- <td>details</td>
- <td>string</td>
- <td>yes</td>
- <td>Official website URL</td>
- </tr>
- <tr class="odd">
- <td>notes</td>
- <td>details</td>
- <td>string</td>
- <td>yes</td>
- <td>Random notes, can contain formatting codes as described in <a href="/d9.3">d9.3</a></td>
- </tr>
- <tr>
- <td>minage</td>
- <td>details</td>
- <td>integer</td>
- <td>yes</td>
- <td>Age rating, 0 = all ages.</td>
- </tr>
- <tr class="odd">
- <td>gtin</td>
- <td>details</td>
- <td>string</td>
- <td>yes</td>
- <td>JAN/UPC/EAN code. This is actually an integer, but formatted as a string to avoid an overflow on 32bit platforms.</td>
- </tr>
- <tr>
- <td>catalog</td>
- <td>details</td>
- <td>string</td>
- <td>yes</td>
- <td>Catalog number.</td>
- </tr>
- <tr class="odd">
- <td>platforms</td>
- <td>details</td>
- <td>array of strings</td>
- <td>no</td>
- <td>Empty array when platform is unknown.</td>
- </tr>
- <tr>
- <td>media</td>
- <td>details</td>
- <td>array of objects</td>
- <td>no</td>
- <td>
- Objects have the following two members:<br />
- "medium", string<br />
- "qty", integer, the quantity. <b>null</b> when it is not applicable for the medium.<br />
- An empty array is returned when the media are unknown.
- </td>
- </tr>
- <tr class="odd">
- <td>resolution</td>
- <td>details</td>
- <td>string</td>
- <td>yes</td>
- <td></td>
- </tr>
- <tr>
- <td>voiced</td>
- <td>details</td>
- <td>integer</td>
- <td>yes</td>
- <td>1 = Not voiced, 2 = Only ero scenes voiced, 3 = Partially voiced, 4 = Fully voiced</td>
- </tr>
- <tr class="odd">
- <td>animation</td>
- <td>details</td>
- <td>array of integers</td>
- <td>no</td>
- <td>
- The array has two integer members, the first one indicating the story
- animations, the second the ero scene animations. Both members can be null
- if unknown or not applicable.<br />
- <br />
- When not null, the number indicates the following: 1 = No animations, 2 =
- Simple animations, 3 = Some fully animated scenes, 4 = All scenes fully
- animated.
- </td>
- </tr>
- <tr>
- <td>vn</td>
- <td>vn</td>
- <td>array of objects</td>
- <td>no</td>
- <td>
- Array of visual novels linked to this release. Objects have the following members:
- id, title and original. These are the same as the members of the "get vn" command.
- </td>
- </tr>
- <tr class="odd">
- <td>producers</td>
- <td>producers</td>
- <td>array of objects</td>
- <td>no</td>
- <td>
- (Possibly empty) list of producers involved in this release. Objects have the following members:<br />
- "id", integer<br />
- "developer", boolean,<br />
- "publisher", boolean,<br />
- "name", string, romaji name<br />
- "original", string, official/original name, can be <b>null</b><br />
- "type", string, producer type
- </td>
- </tr>
-</table>
-<p>Sorting is possible on the 'id', 'title' and 'released' fields.</p><br />
-
-<p>Accepted filters:</p>
-<table style="margin: 5px 2%; width: 95%">
- <thead><tr>
- <td style="width: 80px">Field</td>
- <td style="width: 90px">Value</td>
- <td style="width: 90px">Operators</td>
- <td>&nbsp;</td>
- </tr></thead>
- <tr class="odd">
- <td>id</td>
- <td>integer<br />array of integers</td>
- <td>= != &gt; &gt;= &lt; &lt;=<br />= !=</td>
- <td>&nbsp;</td>
- </tr>
- <tr>
- <td>vn</td>
- <td>integer<br />array of integers</td>
- <td>= !=</td>
- <td>Find releases linked to the given visual novel ID.</td>
- </tr>
- <tr class="odd">
- <td>producer</td>
- <td>integer</td>
- <td>=</td>
- <td>Find releases linked to the given producer ID.</td>
- </tr>
- <tr>
- <td>title</td>
- <td>string</td>
- <td>= != ~</td>
- <td>&nbsp;</td>
- </tr>
- <tr class="odd">
- <td>original</td>
- <td>null<br />string</td>
- <td>= !=<br />= != ~</td>
- <td>&nbsp;</td>
- </tr>
- <tr>
- <td>released</td>
- <td>null<br />date (string)</td>
- <td>= !=<br />= != &gt; &gt;= &lt; &lt;=</td>
- <td>Note about released filter for the vn type also applies here.</td>
- </tr>
- <tr class="odd">
- <td>patch</td>
- <td>boolean</td>
- <td>=</td>
- <td>&nbsp;</td>
- </tr>
- <tr>
- <td>freeware</td>
- <td>boolean</td>
- <td>=</td>
- <td>&nbsp;</td>
- </tr>
- <tr class="odd">
- <td>doujin</td>
- <td>boolean</td>
- <td>=</td>
- <td>&nbsp;</td>
- </tr>
- <tr>
- <td>type</td>
- <td>string</td>
- <td>= !=</td>
- <td>&nbsp;</td>
- </tr>
- <tr class="odd">
- <td>gtin</td>
- <td>int</td>
- <td>= !=</td>
- <td>Value can also be escaped as a string (if you risk an integer overflow otherwise)</td>
- </tr>
- <tr>
- <td>catalog</td>
- <td>string</td>
- <td>= !=</td>
- <td>&nbsp;</td>
- </tr>
- <tr class="odd">
- <td>languages</td>
- <td>string<br />array of strings</td>
- <td>= !=</td>
- <td>&nbsp;</td>
- </tr>
- <tr class="odd">
- <td>platforms</td>
- <td>string<br />array of strings</td>
- <td>= !=</td>
- <td>&nbsp;</td>
- </tr>
-</table>
-
-:SUBSUB:get producer
-<p>Returned members:</p>
-<table style="margin: 5px 2%; width: 95%">
- <thead><tr>
- <td style="width: 80px">Member</td>
- <td style="width: 50px">Flag</td>
- <td style="width: 90px">Type</td>
- <td style="width: 40px">null</td>
- <td>Description</td>
- </tr></thead>
- <tr class="odd">
- <td>id</td>
- <td>-</td>
- <td>integer</td>
- <td>no</td>
- <td>Producer ID</td>
- </tr>
- <tr>
- <td>name</td>
- <td>basic</td>
- <td>string</td>
- <td>no</td>
- <td>(romaji) producer name</td>
- </tr>
- <tr class="odd">
- <td>original</td>
- <td>basic</td>
- <td>string</td>
- <td>yes</td>
- <td>Original/official name</td>
- </tr>
- <tr>
- <td>type</td>
- <td>basic</td>
- <td>string</td>
- <td>no</td>
- <td>Producer type</td>
- </tr>
- <tr class="odd">
- <td>language</td>
- <td>basic</td>
- <td>string</td>
- <td>no</td>
- <td>Primary language</td>
- </tr>
- <tr>
- <td>links</td>
- <td>details</td>
- <td>object</td>
- <td>no</td>
- <td>
- External links, object has the following members:<br />
- "homepage", official homepage,<br />
- "wikipedia", title of the related article on the English wikipedia.<br />
- Both values can be <b>null</b>.
- </td>
- </tr>
- <tr class="odd">
- <td>aliases</td>
- <td>details</td>
- <td>string</td>
- <td>yes</td>
- <td>List of alternative names, separated by a newline</td>
- </tr>
- <tr>
- <td>description</td>
- <td>details</td>
- <td>string</td>
- <td>yes</td>
- <td>Description/notes of the producer, can contain formatting codes as described in <a href="/d9.3">d9.3</a></td>
- </tr>
- <tr class="odd">
- <td>relations</td>
- <td>relations</td>
- <td>array of objects</td>
- <td>no</td>
- <td>
- (possibly empty) list of related producers, each object has the following members:<br />
- "id", integer, producer ID,<br />
- "relation", string, relation to the current producer,<br />
- "name", string,<br />
- "original", string, can be <b>null</b>
- </td>
- </tr>
-</table>
-<p>Sorting is possible on the 'id' and 'name' fields.</p><br />
-
-<p>The following filters are recognised:</p>
-<table style="margin: 5px 2%; width: 95%">
- <thead><tr>
- <td style="width: 80px">Field</td>
- <td style="width: 90px">Value</td>
- <td style="width: 90px">Operators</td>
- <td>&nbsp;</td>
- </tr></thead>
- <tr class="odd">
- <td>id</td>
- <td>integer<br />array of integers</td>
- <td>= != &gt; &gt;= &lt; &lt;=<br />= !=</td>
- <td>&nbsp;</td>
- </tr>
- <tr>
- <td>name</td>
- <td>string</td>
- <td>= != ~</td>
- <td>&nbsp;</td>
- </tr>
- <tr class="odd">
- <td>original</td>
- <td>null<br />string</td>
- <td>= !=<br />= != ~</td>
- <td>&nbsp;</td>
- </tr>
- <tr>
- <td>type</td>
- <td>string</td>
- <td>= !=</td>
- <td>&nbsp;</td>
- </tr>
- <tr class="odd">
- <td>language</td>
- <td>string<br />array of strings</td>
- <td>= !=</td>
- <td>&nbsp;</td>
- </tr>
- <tr>
- <td>search</td>
- <td>string</td>
- <td>~</td>
- <td>Not an actual field. Performs a search on the name, original and aliases fields.</td>
- </tr>
-</table>
-
-:SUBSUB:get character
-<p>Returned members:</p>
-<table style="margin: 5px 2%; width: 95%">
- <thead><tr>
- <td style="width: 80px">Member</td>
- <td style="width: 50px">Flag</td>
- <td style="width: 90px">Type</td>
- <td style="width: 40px">null</td>
- <td>Description</td>
- </tr></thead>
- <tr class="odd">
- <td>id</td>
- <td>-</td>
- <td>integer</td>
- <td>no</td>
- <td>Character ID</td>
- </tr>
- <tr>
- <td>name</td>
- <td>basic</td>
- <td>string</td>
- <td>no</td>
- <td>(romaji) name</td>
- </tr>
- <tr class="odd">
- <td>original</td>
- <td>basic</td>
- <td>string</td>
- <td>yes</td>
- <td>Original (kana/kanji) name</td>
- </tr>
- <tr>
- <td>gender</td>
- <td>basic</td>
- <td>string</td>
- <td>yes</td>
- <td>"m" (male), "f" (female) or "b" (both)</td>
- </tr>
- <tr class="odd">
- <td>bloodt</td>
- <td>basic</td>
- <td>string</td>
- <td>yes</td>
- <td>Blood type, "a", "b", "ab" or "o"</td>
- </tr>
- <tr>
- <td>birthday</td>
- <td>basic</td>
- <td>array</td>
- <td>no</td>
- <td>
- Array of two numbers: day of the month (1-31) and the month (1-12). Either can be null.
- </td>
- </tr>
- <tr class="odd">
- <td>aliases</td>
- <td>details</td>
- <td>string</td>
- <td>yes</td>
- <td>Alternative names, separated with a newline.</td>
- </tr>
- <tr>
- <td>description</td>
- <td>details</td>
- <td>string</td>
- <td>yes</td>
- <td>Description/notes, can contain formatting codes as described in <a href="/d9.3">d9.3</a>. May also include [spoiler] tags!</td>
- </tr>
- <tr class="odd">
- <td>image</td>
- <td>details</td>
- <td>string</td>
- <td>yes</td>
- <td>HTTP link to the character image. Always (supposed to be) SFW.</td>
- </tr>
- <tr>
- <td>bust</td>
- <td>meas</td>
- <td>integer</td>
- <td>yes</td>
- <td>cm</td>
- </tr>
- <tr class="odd">
- <td>waist</td>
- <td>meas</td>
- <td>integer</td>
- <td>yes</td>
- <td>cm</td>
- </tr>
- <tr>
- <td>hip</td>
- <td>meas</td>
- <td>integer</td>
- <td>yes</td>
- <td>cm</td>
- </tr>
- <tr class="odd">
- <td>height</td>
- <td>meas</td>
- <td>integer</td>
- <td>yes</td>
- <td>cm</td>
- </tr>
- <tr>
- <td>weight</td>
- <td>meas</td>
- <td>integer</td>
- <td>yes</td>
- <td>kg</td>
- </tr>
- <tr class="odd">
- <td>traits</td>
- <td>traits</td>
- <td>array of arrays</td>
- <td>no</td>
- <td>(Possibly empty) list of traits linked to this character. Each trait is
- represented as an array of two elements: The trait id (integer) and the
- spoiler level (integer, 0-2). General information for each trait is
- available in the <a href="/d14.3">traits dump</a>.</td>
- </tr>
- <tr>
- <td>vns</td>
- <td>vns</td>
- <td>array of arrays</td>
- <td>no</td>
- <td>List of VNs linked to this character. Each VN is an array of 4 elements:
- VN id, release ID (0 = "all releases"), spoiler level (0-2) and the role
- (string).<br />
- Available roles: "main", "primary", "side" and "appears".</td>
- </tr>
- <tr class="odd">
- <td>voiced</td>
- <td>voiced</td>
- <td>array of objects</td>
- <td>no</td>
- <td>List of voice actresses (staff) that voiced this character, per VN. Each
- staff/VN is represented as a object with the following members:<br />
- "id", integer, staff ID<br />
- "aid", integer, the staff alias ID being used<br />
- "vid", integer, VN id<br />
- "note", string<br />
- The same voice actor may be listed multiple times if this entry is
- character to multiple visual novels. Similarly, the same visual novel may
- be listed multiple times if this character has multiple voice actors in the
- same VN.
- </td>
- </tr>
-</table>
-<p>Sorting is possible on the 'id' and 'name' fields.</p><br />
-
-<p>The following filters are recognised:</p>
-<table style="margin: 5px 2%; width: 95%">
- <thead><tr>
- <td style="width: 80px">Field</td>
- <td style="width: 90px">Value</td>
- <td style="width: 90px">Operators</td>
- <td>&nbsp;</td>
- </tr></thead>
- <tr class="odd">
- <td>id</td>
- <td>integer<br />array of integers</td>
- <td>= != &gt; &gt;= &lt; &lt;=<br />= !=</td>
- <td>&nbsp;</td>
- </tr>
- <tr>
- <td>name</td>
- <td>string</td>
- <td>= != ~</td>
- <td>&nbsp;</td>
- </tr>
- <tr class="odd">
- <td>original</td>
- <td>null<br />string</td>
- <td>= !=<br />= != ~</td>
- <td>&nbsp;</td>
- </tr>
- <tr>
- <td>search</td>
- <td>string</td>
- <td>~</td>
- <td>Not an actual field. Performs a search on the name, original and aliases fields.</td>
- </tr>
- <tr class="odd">
- <td>vn</td>
- <td>integer<br />array of integers</td>
- <td>=</td>
- <td>Find characters linked to the given visual novel ID(s). Note that this
- may also include characters that are normally hidden by spoiler settings.
- </td>
- </tr>
- <tr>
- <td>traits</td>
- <td>int<br />array of ints</td>
- <td>= !=</td>
- <td>
- Find chars by traits. When providing an array of ints, the '=' filter will return
- chars that are linked to any (not all) of the given traits, the '!=' filter will
- return chars that are not linked to any of the given traits. You can combine
- multiple trait filters with 'and' and 'or' to get the exact behavior you
- need.<br />
- This filter may used cached data, it may take up to 24 hours
- before a char entry will have its traits updated with respect to this filter.<br />
- Chars that are linked to childs of the given trait are also included.<br />
- Be warned that this filter ignores spoiler settings, fetch the traits
- associated with the returned char to verify the spoiler level.
- </td>
- </tr>
-</table>
-
-
-:SUBSUB:get staff
-<p>
-Unlike other database entries, staff have more than one unique identifier.<br />
-There is the main 'staff ID', which uniquely identifies a person and is what
-the staff pages on the site represent.<br />
-Additionally, every staff name and alias also has its own unique identifier,
-which is referenced from other database entries to identify which alias was
-used. This identifier is generally hidden on the site and aliases do not have
-their own page, but the IDs are exposed in this API in order to facilitate
-linking between VNs/characters and staff.<br />
-<br />
-Returned members:</p>
-<table style="margin: 5px 2%; width: 95%">
- <thead><tr>
- <td style="width: 80px">Member</td>
- <td style="width: 50px">Flag</td>
- <td style="width: 90px">Type</td>
- <td style="width: 40px">null</td>
- <td>Description</td>
- </tr></thead>
- <tr class="odd">
- <td>id</td>
- <td>-</td>
- <td>integer</td>
- <td>no</td>
- <td>Staff ID</td>
- </tr>
- <tr>
- <td>name</td>
- <td>basic</td>
- <td>string</td>
- <td>no</td>
- <td>Primary (romaji) staff name</td>
- </tr>
- <tr class="odd">
- <td>original</td>
- <td>basic</td>
- <td>string</td>
- <td>yes</td>
- <td>Primary original name</td>
- </tr>
- <tr>
- <td>gender</td>
- <td>basic</td>
- <td>string</td>
- <td>yes</td>
- <td></td>
- </tr>
- <tr class="odd">
- <td>language</td>
- <td>basic</td>
- <td>string</td>
- <td>no</td>
- <td>Primary language</td>
- </tr>
- <tr>
- <td>links</td>
- <td>details</td>
- <td>object</td>
- <td>no</td>
- <td>
- External links, object has the following members:<br />
- "homepage", official homepage,<br />
- "wikipedia", title of the related article on the English wikipedia.<br />
- "twitter", name of the twitter account.<br />
- "anidb", <a href="http://anidb.net/">AniDB</a> creator ID.<br />
- All values can be <b>null</b>.
- </td>
- </tr>
- <tr class="odd">
- <td>description</td>
- <td>details</td>
- <td>string</td>
- <td>yes</td>
- <td>Description/notes of the staff, can contain formatting codes as described in <a href="/d9.3">d9.3</a></td>
- </tr>
- <tr>
- <td>aliases</td>
- <td>aliases</td>
- <td>array of arrays</td>
- <td>no</td>
- <td>
- List of names and aliases. Each name is represented as an array with the
- following elements: Alias ID, name (romaji) and the original name.<br />
- This list also includes the "primary" name.
- </td>
- </tr>
- <tr class="odd">
- <td>main_alias</td>
- <td>aliases</td>
- <td>integer</td>
- <td>no</td>
- <td>ID of the alias that is the "primary" name of the entry</td>
- </tr>
- <tr>
- <td>vns</td>
- <td>vns</td>
- <td>array of objects</td>
- <td>no</td>
- <td>
- List of visual novels that this staff entry has been credited in (excluding
- character voicing). Each vn is represented as an object with the following
- members:<br />
- "id", integer, visual novel id<br />
- "aid", integer, alias ID of this staff entry<br />
- "role", string<br />
- "note", string, may be null if unset<br />
- The same VN entry may appear multiple times if the staff has been credited
- for multiple roles.
- </td>
- </tr>
- <tr class="odd">
- <td>voiced</td>
- <td>voiced</td>
- <td>array of objects</td>
- <td>no</td>
- <td>
- List of characters that this staff entry has voiced. Each object has the
- following members:<br />
- "id", integer, visual novel id<br />
- "aid", integer, alias ID of this staff entry<br />
- "cid", integer, character ID<br />
- "note", string, may be null if unset<br />
- The same VN entry may appear multiple times if the staff has been credited
- for multiple characters. Similarly, the same character may appear multiple
- times if it has been linked to multiple VNs.
- </td>
- </tr>
-</table>
-<p>Sorting is possible on the 'id' field.</p><br />
-
-<p>The following filters are recognised:</p>
-<table style="margin: 5px 2%; width: 95%">
- <thead><tr>
- <td style="width: 80px">Field</td>
- <td style="width: 90px">Value</td>
- <td style="width: 90px">Operators</td>
- <td>&nbsp;</td>
- </tr></thead>
- <tr class="odd">
- <td>id</td>
- <td>integer<br />array of integers</td>
- <td>= != &gt; &gt;= &lt; &lt;=<br />= !=</td>
- <td>&nbsp;</td>
- </tr>
- <tr>
- <td>aid</td>
- <td>integer<br />array of integers</td>
- <td>=<br />=</td>
- <td>&nbsp;</td>
- </tr>
- <tr>
- <td>search</td>
- <td>string</td>
- <td>~</td>
- <td>Searched through all aliases, both the romanized and original names.</td>
- </tr>
-</table>
-
-
-:SUBSUB:get user
-<p>Returned members:</p>
-<table style="margin: 5px 2%; width: 95%">
- <thead><tr>
- <td style="width: 80px">Member</td>
- <td style="width: 50px">Flag</td>
- <td style="width: 90px">Type</td>
- <td style="width: 40px">null</td>
- <td>Description</td>
- </tr></thead>
- <tr class="odd">
- <td>id</td>
- <td>basic</td>
- <td>integer</td>
- <td>no</td>
- <td>User ID</td>
- </tr>
- <tr>
- <td>username</td>
- <td>basic</td>
- <td>string</td>
- <td>no</td>
- <td></td>
- </tr>
-</table>
-<p>The returned list is always sorted on the 'id' field.</p><br />
-
-<p>The following filters are recognised:</p>
-<table style="margin: 5px 2%; width: 95%">
- <thead><tr>
- <td style="width: 80px">Field</td>
- <td style="width: 90px">Value</td>
- <td style="width: 90px">Operators</td>
- <td>&nbsp;</td>
- </tr></thead>
- <tr class="odd">
- <td>id</td>
- <td>integer<br />array of integers</td>
- <td>=</td>
- <td>The special value '0' is recognized as the currently logged in user.</td>
- </tr>
- <tr>
- <td>username</td>
- <td>string<br />array of strings</td>
- <td>= != ~<br />=</td>
- <td></td>
- </tr>
-</table>
-
-
-:SUBSUB:get votelist
-<p>Returned members:</p>
-<table style="margin: 5px 2%; width: 95%">
- <thead><tr>
- <td style="width: 80px">Member</td>
- <td style="width: 50px">Flag</td>
- <td style="width: 90px">Type</td>
- <td style="width: 40px">null</td>
- <td>Description</td>
- </tr></thead>
- <tr class="odd">
- <td>uid</td>
- <td>basic</td>
- <td>integer</td>
- <td>no</td>
- <td>User ID</td>
- </tr>
- <tr>
- <td>vn</td>
- <td>basic</td>
- <td>integer</td>
- <td>no</td>
- <td>Visual Novel ID</td>
- </tr>
- <tr class="odd">
- <td>vote</td>
- <td>basic</td>
- <td>integer</td>
- <td>no</td>
- <td>In the range of 10 (lowest) to 100 (highest). These are displayed on the site as a fractional number between 1 and 10.</td>
- </tr>
- <tr>
- <td>added</td>
- <td>basic</td>
- <td>integer</td>
- <td>no</td>
- <td>Unix timestamp of when this vote has been added.</td>
- </tr>
-</table>
-<p>The returned list is always sorted on the 'vn' field.</p><br />
-
-<p>The following filters are recognised:</p>
-<table style="margin: 5px 2%; width: 95%">
- <thead><tr>
- <td style="width: 80px">Field</td>
- <td style="width: 90px">Value</td>
- <td style="width: 90px">Operators</td>
- <td>&nbsp;</td>
- </tr></thead>
- <tr class="odd">
- <td>uid</td>
- <td>integer</td>
- <td>=</td>
- <td>The special value '0' is recognized as the currently logged in user.</td>
- </tr>
- <tr>
- <td>vn</td>
- <td>integer<br />array of integers</td>
- <td>= != &gt; &lt; &gt;= &lt;=<br />= !=</td>
- <td>Visual novel ID.</td>
- </tr>
-</table>
-<p>
- Note: It's possible that a user has voted on a VN that has been deleted. The
- vote is still included this list, but a 'get vn' command on its id will not
- return anything.<br />
- Note#2: This command will not return any results for users who have their vote
- list hidden from the public in their preferences, except when the user itself
- has logged into the API.
-</p>
-
-:SUBSUB:get vnlist
-<p>Returned members:</p>
-<table style="margin: 5px 2%; width: 95%">
- <thead><tr>
- <td style="width: 80px">Member</td>
- <td style="width: 50px">Flag</td>
- <td style="width: 90px">Type</td>
- <td style="width: 40px">null</td>
- <td>Description</td>
- </tr></thead>
- <tr class="odd">
- <td>uid</td>
- <td>basic</td>
- <td>integer</td>
- <td>no</td>
- <td>User ID</td>
- </tr>
- <tr>
- <td>vn</td>
- <td>basic</td>
- <td>integer</td>
- <td>no</td>
- <td>Visual Novel ID</td>
- </tr>
- <tr class="odd">
- <td>status</td>
- <td>basic</td>
- <td>integer</td>
- <td>no</td>
- <td>0=Unknown, 1=playing, 2=finished, 3=stalled, 4=dropped.</td>
- </tr>
- <tr>
- <td>added</td>
- <td>basic</td>
- <td>integer</td>
- <td>no</td>
- <td>Unix timestamp of when this item has been added.</td>
- </tr>
- <tr class="odd">
- <td>notes</td>
- <td>basic</td>
- <td>string</td>
- <td>yes</td>
- <td>User-set notes</td>
- </tr>
-</table>
-<p>The returned list is always sorted on the 'vn' field.</p><br />
-
-<p>The following filters are recognised:</p>
-<table style="margin: 5px 2%; width: 95%">
- <thead><tr>
- <td style="width: 80px">Field</td>
- <td style="width: 90px">Value</td>
- <td style="width: 90px">Operators</td>
- <td>&nbsp;</td>
- </tr></thead>
- <tr class="odd">
- <td>uid</td>
- <td>integer</td>
- <td>=</td>
- <td>The special value '0' is recognized as the currently logged in user.</td>
- </tr>
- <tr>
- <td>vn</td>
- <td>integer<br />array of integers</td>
- <td>= != &gt; &lt; &gt;= &lt;=<br />= !=</td>
- <td>Visual novel ID.</td>
- </tr>
-</table>
-<p>The notes mentioned under 'get votelist' also apply here.</p>
-
-:SUBSUB:get wishlist
-<p>Returned members:</p>
-<table style="margin: 5px 2%; width: 95%">
- <thead><tr>
- <td style="width: 80px">Member</td>
- <td style="width: 50px">Flag</td>
- <td style="width: 90px">Type</td>
- <td style="width: 40px">null</td>
- <td>Description</td>
- </tr></thead>
- <tr class="odd">
- <td>uid</td>
- <td>basic</td>
- <td>integer</td>
- <td>no</td>
- <td>User ID</td>
- </tr>
- <tr>
- <td>vn</td>
- <td>basic</td>
- <td>integer</td>
- <td>no</td>
- <td>Visual Novel ID</td>
- </tr>
- <tr class="odd">
- <td>priority</td>
- <td>basic</td>
- <td>integer</td>
- <td>no</td>
- <td>0=high, 1=medium, 2=low, 3=blacklist.</td>
- </tr>
- <tr>
- <td>added</td>
- <td>basic</td>
- <td>integer</td>
- <td>no</td>
- <td>Unix timestamp of when this item has been added.</td>
- </tr>
-</table>
-<p>The returned list is always sorted on the 'vn' field.</p><br />
-
-<p>The following filters are recognised:</p>
-<table style="margin: 5px 2%; width: 95%">
- <thead><tr>
- <td style="width: 80px">Field</td>
- <td style="width: 90px">Value</td>
- <td style="width: 90px">Operators</td>
- <td>&nbsp;</td>
- </tr></thead>
- <tr class="odd">
- <td>uid</td>
- <td>integer</td>
- <td>=</td>
- <td>The special value '0' is recognized as the currently logged in user.</td>
- </tr>
- <tr>
- <td>vn</td>
- <td>integer<br />array of integers</td>
- <td>= != &gt; &lt; &gt;= &lt;=<br />= !=</td>
- <td>Visual novel ID.</td>
- </tr>
-</table>
-<p>The notes mentioned under 'get votelist' also apply here.</p>
-
-
-:SUB:The 'set' command
-<p>
- The set command can be used to modify stuff in the database. It can only be
- used when logged in as a user. The command has the following syntax:
-</p>
-<pre>
- set <b class="standout">type id fields</b>
-</pre>
-<p>
- Here, <i>type</i> is similar to the type argument to the 'get' command,
- <i>id</i> is the (integer) identifier of the database entry to change, and
- <i>fields</i> is an object with the fields to set or modify. If the
- <i>fields</i> object is not present, the set command works as a 'delete'. The
- interpretation of the <i>id</i> and <i>fields</i> arguments depend on the
- <i>type</i>, and are documented in the sections below.<br />
- <br />
- But before that, let me present some examples to get a feel on what the
- previous paragraph meant. The following example adds a '10' vote on <a
- href="/v17">v17</a>, or changes the vote to a 10 if a previous vote was
- already present:
-</p>
-<pre>
- set votelist 17 {"vote":100}
-</pre>
-<p>And here's how to remove the previous vote:</p>
-<pre>
- set votelist 17
-</pre>
-<p>
- 'set' replies with a simple 'ok' on success, or with an 'error' (see below) on
- failure. Note that, due to my laziness, no error is currently returned if the
- identifier does not exist. So voting on a VN that does not exist will return
- an 'ok', but no vote is actually added. This behaviour may change in the
- future. Note that this API doesn't care whether the VN has been deleted or
- not, so you can manage votes and stuff for deleted VNs (Which isn't very
- helpful, because 'get vn' won't return a thing for deleted VNs).
-</p>
-
-:SUBSUB:set votelist
-<p>
- This command facilitates adding, removing and modifying votes. The
- <i>identifier</i> argument is the visual novel ID, and the following fields
- are recognized:
-</p>
-<table style="margin: 5px 2%; width: 95%">
- <thead><tr>
- <td style="width: 80px">Field</td>
- <td style="width: 90px">Type</td>
- <td>Description</td>
- </tr></thead>
- <tr class="odd">
- <td>vote</td>
- <td>integer</td>
- <td>Same as the 'vote' member returned by 'get votelist', in the range 10 to 100. This field has no default; it must always be present.</td>
- </tr>
-</table>
-<p>
- The 'added' member returned by 'get votelist' is, as its name implies, only
- set when the vote is added. Changing an existing vote will not update the
- 'added' field.
-</p>
-
-:SUBSUB:set vnlist
-<p>
- This command facilitates adding, removing and modifying your VN list. The
- <i>identifier</i> argument is the visual novel ID, and the following fields
- are recognized:
-</p>
-<table style="margin: 5px 2%; width: 95%">
- <thead><tr>
- <td style="width: 80px">Field</td>
- <td style="width: 90px">Type</td>
- <td>Description</td>
- </tr></thead>
- <tr class="odd">
- <td>status</td>
- <td>integer</td>
- <td>Same as the 'status' member returned by 'get vnlist'. Default: 0</td>
- </tr>
- <tr>
- <td>notes</td>
- <td>string</td>
- <td>Same as the 'notes' member returned by 'get vnlist'. An empty string is considered equivalent to 'null'. A newline is currently not allowed because the web interface won't handle them well. Default: null.</td>
- </tr>
-</table>
-<p>
- Sames notes about the 'added' member for 'set votelist' applies here.<br />
- Also note that, when removing a vnlist item, any releases associated with the
- VN will be removed from the users' list as well. The release list
- functionality is not currently exposed to the API, so this will only be
- visible when the web interface is used.
-</p>
-
-:SUBSUB:set wishlist
-<p>
- This command facilitates adding, removing and modifying VNs from your
- wishlist. The <i>identifier</i> argument is the visual novel ID, and the
- following fields are recognized:
-</p>
-<table style="margin: 5px 2%; width: 95%">
- <thead><tr>
- <td style="width: 80px">Field</td>
- <td style="width: 90px">Type</td>
- <td>Description</td>
- </tr></thead>
- <tr class="odd">
- <td>priority</td>
- <td>integer</td>
- <td>Same as the 'priority' member returned by 'get wishlist'.</td>
- </tr>
-</table>
-<p>
- Sames notes about the 'added' member for 'set votelist' applies here.<br />
-</p>
-
-
-
-:SUB:The 'error' response
-<p>
- Every command to the server can receive an 'error' response, this response has one
- argument: a JSON object containing at least a member named "id", which identifies
- the error, and a "msg", which contains a human readable message explaining what
- went wrong. Other members are also possible, depending on the value of "id".
- Example error message:
-</p>
-<pre>
- error {"id":"parse", "msg":"Invalid command or argument"}
-</pre>
-<p>
- Note that the value of "msg" is not directly linked to the error identifier:
- the message explains what went wrong in more detail, there are several
- different messages for the same id. The following error identifiers are currently
- defined:
-</p>
-<dl>
- <dt>parse</dt><dd>Syntax error, unknown command or invalid argument type.</dd>
- <dt>missing</dt><dd>A JSON object argument is missing a required member. The name of which is given in the additional "field" member.</dd>
- <dt>badarg</dt><dd>A JSON value is of the wrong type or in the wrong format. The name of the incorrect field is given in a "field" member.</dd>
- <dt>needlogin</dt><dd>Need to be logged in to issue this command.</dd>
- <dt>throttled</dt><dd>
- You have used too many server resources within a short time, and need to wait
- a bit before sending the next command. The type of throttle is given in the
- "type" member, and the "minwait" and "fullwait" members tell you how long you
- need to wait before sending the next command and when you can start bursting
- again (this is the recommended waiting time), respectively. Both values are in
- seconds, with a precision of 0.1 seconds.
- </dd>
- <dt>auth</dt><dd>(login) Incorrect username/password combination.</dd>
- <dt>loggedin</dt><dd>(login) Already logged in. Only one successful login command can be issues on one connection.</dd>
- <dt>gettype</dt><dd>(get) Unknown type argument to the 'get' command.</dd>
- <dt>getinfo</dt><dd>(get) Unknown info flag to the 'get' command. The name of the unrecognised flag is given in an additional "flag" member.</dd>
- <dt>filter</dt><dd>(get) Unknown filter field or invalid combination of field/operator/argument type. Includes three additional members: "field", "op" and "value" of the incorrect expression.</dd>
- <dt>settype</dt><dd>(set) Unknown type argument to the 'set' command.</dd>
-</dl>
-
-
-
-:SUB:Change Log
-<p>
- This section lists the changes made in each version of the VNDB code.
- Check out the <a href="/t/an">announcements board</a> for more information about updates.
- <br /><br />
-</p>
-<b>2018-02-07</b>
-<ul>
- <li>The 'aliases' member for "get producer" is now uses newline as separation rather than a comma</li>
-</ul>
-<b>2017-08-14</b>
-<ul>
- <li>Add 'uid' field to "get votelist/vnlist/wishlist" commands</li>
- <li>Add 'vn' filter to the same commands</li>
- <li>The 'uid' filter for these commands is now optional, making it possible to find all list entries for a particular VN</li>
-</ul>
-<b>2017-06-21</b>
-<ul>
- <li>Add "resolution", "voiced", "animation" members to "get release" command</li>
- <li>Add "platforms" filter to "get release" command</li>
- <li>Accept arrays for the "vn" filter to the "get release" command</li>
- <li>Add "search" filter to "get staff"</li>
-</ul>
-<b>2017-05-22</b>
-<ul>
- <li>Add "vns" and "voiced" flags to "get staff" command</li>
- <li>Add "voiced" flag to "get character" command</li>
-</ul>
-<b>2017-04-28</b> <b class="grayedout">because screw version numbers</b>
-<ul>
- <li>Add "get staff" command</li>
- <li>Add "staff" flag to "get vn" command</li>
-</ul>
-<b>2.27</b>
-<ul>
- <li>Add "username" filter to "get user"</li>
- <li>Add "traits" filter to "get character"</li>
-</ul>
-<b>2.25</b>
-<ul>
- <li>Add "tags" filter to "get vn"</li>
- <li>Increased connection limit per IP from 5 to 10</li>
- <li>Increased command limit from 100 to 200 commands per 10 minutes</li>
- <li>Added support for TLS</li>
- <li>Added "screens" flag and member to "get vn"</li>
- <li>Added "vns" flag and member to "get character"</li>
- <li>Allow sorting "get vn" on popularity, rating and votecount</li>
- <li>Added basic "get user" command</li>
- <li>Added "official" field to "get vn relations"</li>
-</ul>
-<b>2.23</b>
-<ul>
- <li>Added new 'dbstats' command</li>
- <li>Added new 'get' types: character, votelist, vnlist and wishlist</li>
- <li>Added 'set' command, with types: votelist, vnlist and wishlist</li>
- <li>New error id: 'settype'</li>
- <li>Added "tags" flag and member to "get vn"</li>
- <li>Added "stats" flag to "get vn"</li>
- <li>Added "firstchar" filter to "get vn"</li>
- <li>Added "vn" filter to "get character"</li>
-</ul>
-<b>2.15</b>
-<ul>
- <li>Fixed a bug with the server not allowing extra whitespace after a "get .. " command</li>
- <li>Allow non-numbers as "clientver" for the login command</li>
- <li>Added "image_nsfw" member to "get vn"</li>
- <li>Added "results" option to the "get .. {<options>}"</li>
- <li>Increased the maximum number of results for the "get .." command to 25</li>
- <li>Added "orig_lang" member and filter to the "get vn .." command</li>
- <li>Throttle the commands and sqltime per IP instead of per user</li>
- <li>Removed the limit on the number of open sessions per user</li>
- <li>Allow the API to be used without logging in with a username/password</li>
-</ul>
-<b>2.12</b>
-<ul>
- <li>Added "image" member to "get vn"</li>
- <li>A few minor fixes in some error messages</li>
- <li>Switched to a different (and faster) search algorithm for "get vn .. (search ~ ..)"</li>
-</ul>
-