Miyuu's Image Board

api:tag_aliases

Table of Contents* 1. "Record field format":#dtext-record
* 2. "Associated attributes":#dtext-associations
* 3. "Nomenclature":#dtext-nomenclature
* 4. "Index":#dtext-index
* 5. "Show":#dtext-show
* 6. "Delete":#dtext-delete
* 7. "See also":#dtext-see-also
* 08. "External links":#dtext-external-links

The following includes the details of how to interface with the tag alias 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]
antecedent_name
[/td]

[td]string[/td]

[td][/td]

[/tr]

[tr]

[td]
consequent_name
[/td]

[td]string[/td]

[td][/td]

[/tr]

[tr]

[td]
status
[/td]

[td]string[/td]

[td]includes [active, deleted, retired][/td]

[/tr]

[tr]

[td]
reason
[/td]

[td]string[/td]

[td]unused[/td]

[/tr]

[tr]

[td]
forum_topic_id
[/td]

[td]integer[/td]

[td]>0 or null[/td]

[/tr]

[tr]

[td]
forum_post_id
[/td]

[td]integer[/td]

[td]>0 or null[/td]

[/tr]

[tr]

[td]
creator_id
[/td]

[td]integer[/td]

[td]>0[/td]

[/tr]

[tr]

[td]
approver_id
[/td]

[td]integer[/td]

[td]>0 or null[/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]


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]

creator
[/td]

[td]user[/td]

[td]single[/td]

[td]required[/td]

[td]User that created the alias.[/td]

[/tr]

[tr]

[td]
approver
[/td]

[td]user[/td]

[td]single[/td]

[td]optional[/td]

[td]User that approved the alias.[/td]

[/tr]

[tr]

[td]
forum_topic
[/td]

[td]forum topic[/td]

[td]single[/td]

[td]optional[/td]

[td]Forum topic where the aliasas discussed.[/td]

[/tr]

[tr]

[td]
forum_post
[/td]

[td]forum post[/td]

[td]single[/td]

[td]optional[/td]

[td]Forum post which started the alias discussion.[/td]

[/tr]

[tr]

[td]
antecedent_tag
[/td]

[td]tag[/td]

[td]single[/td]

[td]required[/td]

[td]Tag of the antecedent.[/td]

[/tr]

[tr]

[td]
consequent_tag
[/td]

[td]tag[/td]

[td]single[/td]

[td]required[/td]

[td]Tag of the consequent.[/td]

[/tr]

[tr]

[td]
antecedent_wiki
[/td]

[td]wiki page[/td]

[td]single[/td]

[td]optional[/td]

[td]Wiki page of the antecedent.[/td]

[/tr]

[tr]

[td]
consequent_wiki
[/td]

[td]wiki page[/td]

[td]single[/td]

[td]optional[/td]

[td]Wiki page of the consequent.[/td]

[/tr]

[/tbody]

[/table]


h4#nomenclature. Nomenclature


* Plural form: "tag_aliases"

** Used in the URL pathname

* Singular form: "tag_alias"

** 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]

/tag_aliases.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


**
created_at


**
updated_at


* Text syntax

**
antecedent_name


**
consequent_name


* User syntax

**
creator


**
approver


* Chaining syntax

*
forum_topic


*
forum_post


h5#special-search-parameters. Special search parameters


*

name_matches
- Case-insensitive wildcard search on the antecedent name or consequent name fields.

*
status
- Case-insensitive search on the status field.

*
category
- Searches on the category of the consequent tag, with support for multiple categories being space-delimited.


h5#search-order. Search order


Using the search parameter

order
with one of the following values changes the order of the results.


*

created_at
- Orders by created_at descending.

*
updated_at
- Orders by updated_at descending.

*
name
- Alphabetical order on the antecedent, then alphabetical order on the consequent.

*
tag_count
- Orders by post count of the consequent tag, then alphabetical order on the antecedent, then alphabetical order on the consequent.

*
custom
- See here for more info.


h4#show. Show


[table]

[tbody]

[tr]

[td]HTTP Method[/td]

[td]GET[/td]

[/tr]

[tr]

[td]Base URL[/td]

[td]

/tag_aliases/$id.json
[/td]

[/tr]

[tr]

[td]Type[/td]

[td]read request[/td]

[/tr]

[tr]

[td]Description[/td]

[td]
$id
is the forum post ID.[/td]

[/tr]

[/tbody]

[/table]


h4#delete. Delete


[table]

[tbody]

[tr]

[td]HTTP Method[/td]

[td]DELETE[/td]

[/tr]

[tr]

[td]Base URL[/td]

[td]

/tag_aliases/$id.json
[/td]

[/tr]

[tr]

[td]Type[/td]

[td]write request[/td]

[/tr]

[tr]

[td]Description[/td]

[td]
$id
is the forum post ID.

Restricted to Admin+.[/td]

[/tr]

[/tbody]

[/table]


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][/td]

[/tr]

[tr]

[td]Model[/td]

[td]

[/td]

[/tr]

[tr]

[td]Policy[/td]

[td][/td]

[/tr]

[/tbody]

[/table