api:tags
Table of Contents
* 01. "Record field format":#dtext-record* 02. "Associated attributes":#dtext-associations
* 03. "Nomenclature":#dtext-nomenclature
* 04. "Index":#dtext-index
* 05. "Show":#dtext-show
* 06. "Update":#dtext-update
* 07. "See also":#dtext-see-also
* 08. "External links":#dtext-external-links
The following includes the details of how to interface with the tag records through the API.
h4#record. Record field format
[table]
[thead]
[tr]
[th]Name[/th]
[th]Type[/th]
[th]Details[/th]
[/tr]
[/thead]
[tbody]
[tr]
[td]
id[/td][td]integer[/td]
[td]>0[/td]
[/tr]
[tr]
[td]
name[/td][td]string[/td]
[td][/td]
[/tr]
[tr]
[td]
category[/td][td]integer[/td]
[td]includes [0,1,3,4,5][/td]
[/tr]
[tr]
[td]
post_count[/td][td]integer[/td]
[td]>=0[/td]
[/tr]
[tr]
[td]
is_deprecated[/td][td]boolean[/td]
[td][/td]
[/tr]
[tr]
[td]
created_at[/td][td]timestamp[/td]
[td][/td]
[/tr]
[tr]
[td]
updated_at[/td][td]timestamp[/td]
[td][/td]
[/tr]
[/tbody]
[/table]
h5#category. Category
[table]
[thead]
[tr]
[th]Value[/th]
[th]Description[/th]
[/tr]
[/thead]
[tbody]
[tr]
[td]0[/td]
[td]General[/td]
[/tr]
[tr]
[td]1[/td]
[td]Artist[/td]
[/tr]
[tr]
[td]3[/td]
[td]Copyright[/td]
[/tr]
[tr]
[td]4[/td]
[td]Character[/td]
[/tr]
[tr]
[td]5[/td]
[td]Meta[/td]
[/tr]
[/tbody]
[/table]
h4#associations. Associated attributes
[table]
[thead]
[tr]
[th]Name[/th]
[th]Type[/th]
[th]Number[/th]
[th]Availability[/th]
[th]Details[/th]
[/tr]
[/thead]
[tbody]
[tr]
[td]
wiki_page[/td][td]wiki page[/td]
[td]single[/td]
[td]optional[/td]
[td]Wiki page whose title matches the tag name.[/td]
[/tr]
[tr]
[td]
artist[/td][td]artist[/td]
[td]single[/td]
[td]optional[/td]
[td]Artist whose name matches the tag name.[/td]
[/tr]
[tr]
[td]
antecedent_alias[/td][td]tag alias[/td]
[td]single[/td]
[td]optional[/td]
[td]Alias where the tag is the antecedent.[/td]
[/tr]
[tr]
[td]
consequent_aliases[/td][td]tag alias[/td]
[td]multiple[/td]
[td]optional[/td]
[td]Aliases where the tag is the consequent.[/td]
[/tr]
[tr]
[td]
antecedent_implications[/td][td]tag implication[/td]
[td]multiple[/td]
[td]optional[/td]
[td]Implications where the tag is the antecedent.[/td]
[/tr]
[tr]
[td]
consequent_implications[/td][td]tag implication[/td]
[td]multiple[/td]
[td]optional[/td]
[td]Implications where the tag is the consequent.[/td]
[/tr]
[tr]
[td]
dtext_links[/td][td]dtext link[/td]
[td]multiple[/td]
[td]optional[/td]
[td]Dtext links to the page whose title matches the tag name.[/td]
[/tr]
[/tbody]
[/table]
h4#nomenclature. Nomenclature
* Plural form: "tags"
** Used in the URL pathname
* Singular form: "tag"
** Used for write parameters (Help:API Write Requests)
* Versions: none
h4#index. Index
[table]
[tbody]
[tr]
[td]HTTP Method[/td]
[td]GET[/td]
[/tr]
[tr]
[td]Base URL[/td]
[td]
/tags.json[/td][/tr]
[tr]
[td]Type[/td]
[td]read request[/td]
[/tr]
[tr]
[td]Description[/td]
[td]The default order is ID descending.[/td]
[/tr]
[/tbody]
[/table]
h5#search-attributes. Search attributes
All of the following are standard attributes with all of their available formats and qualifiers.
* Number syntax
**
id**
category**
post_count**
created_at**
updated_at* Text syntax
**
name* Boolean syntax
**
is_deprecated* Chaining syntax
**
wiki_page**
artist**
antecedent_alias**
consequent_aliases**
antecedent_implications**
consequent_implications**
consequent_implications**
dtext_links
h5#special-search-parameters. Special search parameters
*
fuzzy_name_matches - Shows tags with names that are within a certain percentage of similarity.*
name_matches - Normalized wildcard search on the name field.*
name_normalize - Normalized wildcard search on the name field that supports multiple tags split by a comma ",".*
name_or_alias_matches - Normalized wildcard search on the name field that also checks for aliases where the search term is the antecedent.*
hide_empty - Shows only tags that have a post count greater than 0 (Help:Boolean syntax).
h5#search-order. Search order
Using the search parameter
order with one of the following values changes the order of the results.
*
name - Alphabetical order on the name.*
date - Orders by ID descending.*
count - Orders by post count.*
similarity - Orders by similarity to the search term.** Only when the
fuzzy_name_matches parameter is used.
h4#show. Show
[table]
[tbody]
[tr]
[td]HTTP Method[/td]
[td]GET[/td]
[/tr]
[tr]
[td]Base URL[/td]
[td]
/tags/$id.json[/td][/tr]
[tr]
[td]Type[/td]
[td]read request[/td]
[/tr]
[tr]
[td]Description[/td]
[td]
$id is the tag ID.[/td][/tr]
[/tbody]
[/table]
h4#update. Update
[table]
[tbody]
[tr]
[td]HTTP Method[/td]
[td]PUT/PATCH[/td]
[/tr]
[tr]
[td]Base URL[/td]
[td]
/tags/$id.json[/td][/tr]
[tr]
[td]Type[/td]
[td]write request[/td]
[/tr]
[tr]
[td]Description[/td]
[td]
$id is the tag ID.[/td][/tr]
[/tbody]
[/table]
h5#update-parameters. Update parameters
* Optional:
**
is_deprecated*** can only be set to
false by admins*** can only be set to
true if the tag has a wiki page, and either its post count is zero or the user is an admin**
category Restricted by user level*** Member+: < 50 posts
*** Builder+: < 1000 posts
*** Admin+: No limit
h4#see-also. See also
* Help:Common URL Parameters
* Help:API
h4#external-links. External links
[table]
[tbody]
[tr]
[td]Controller[/td]
[td]
[td][/td]
[/tr]
[tr]
[td]Model[/td]
[td]
[/tr]
[tr]
[td]Policy[/td]
[td]
[/tr]
[/tbody]
[/table]
Revision 2 by Anonymous at 2025-04-19 08:57:59.348223