api:wiki_pages
Table of Contents
* 01. "Record field format":#dtext-record* 02. "Derived field format":#dtext-record
* 03. "Associated attributes":#dtext-associations
* 04. "Index":#dtext-index
* 05. "Show":#dtext-show
* 06. "Create":#dtext-create
* 07. "Update":#dtext-update
* 08. "Delete":#dtext-delete
* 09. "Revert":#dtext-revert
* 10. "See also":#dtext-see-also
The following includes the details of how to interface with the wiki page 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]
title[/td][td]string[/td]
[td][/td]
[/tr]
[tr]
[td]
body[/td][td]string[/td]
[td][/td]
[/tr]
[tr]
[td]
other_names[/td][td]array[/td]
[td]strings[/td]
[/tr]
[tr]
[td]
is_deleted[/td][td]boolean[/td]
[td][/td]
[/tr]
[tr]
[td]
locked[/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]
h4#derived. Derived field format
These are values which are not part of the actual record, but instead are derived from calculations and record lookups on the fly.
[table]
[thead]
[tr]
[th]Name[/th]
[th]Type[/th]
[th]Details[/th]
[th]Notes[/th]
[/tr]
[/thead]
[tbody]
[tr]
[td]
category_name[/td][td]string[/td]
[td][0,1,3,4,5,null][/td]
[td]It is the
category of the "associated tag":[#dtext-associations] if it exists, otherwise it is null.[/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]
tag[/td][td]tag[/td]
[td]single[/td]
[td]optional[/td]
[td][/td]
[/tr]
[tr]
[td]
artist[/td][td]artist[/td]
[td]single[/td]
[td]optional[/td]
[td][/td]
[/tr]
[tr]
[td]
dtext_links[/td][td]dtext link[/td]
[td]multiple[/td]
[td]optional[/td]
[td][/td]
[/tr]
[/tbody]
[/table]
h4#nomenclature. Nomenclature
* Plural form: "wiki_pages"
** Used in the URL pathname
* Singular form: "wiki_page"
** Used for write parameters (Help:API Write Requests)
* Versions: API:Wiki page versions
h4#index. Index
[table]
[tbody]
[tr]
[td]HTTP Method[/td]
[td]GET[/td]
[/tr]
[tr]
[td]Base URL[/td]
[td]
/wiki_pages.json[/td][/tr]
[tr]
[td]Type[/td]
[td]read request[/td]
[/tr]
[tr]
[td]Description[/td]
[td]The default order is updated at 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
**
title**
body* Array syntax
**
other_names* Boolean syntax
**
is_deleted**
is_locked* Chaining syntax
**
tag**
artist**
dtext_links
h6#special-search-parameters. Special search parameters
*
body_matches - Case-insensitive wildcard searching on the body text field.*
title_normalize - Normalized case-insensitive wildcard searching on the title text field.*
other_names_match - Case-insensitive wildcard search on any of the other names.*
linked_to - All wiki pages that link to the given wiki title.*
not_linked_to - All wiki pages that do not link to the given wiki title.*
hide_deleted - Hides all deleted wikis (boolean syntax).** Shortcut for
search[is_deleted]=false*
other_names_present - Shows wikis based on the presence of other names (boolean syntax).** Shortcut for
search[other_name_count]=>0 (TRUE) and search[other_name_count]=0 (FALSE)*
order - Sets the order of results.**
title - Alphabetical order on the title.**
post_count - Orders by post count.
h4#show. Show
[table]
[tbody]
[tr]
[td]HTTP Method[/td]
[td]GET[/td]
[/tr]
[tr]
[td]Base URL[/td]
[td]
/wiki_pages/$id.json[/td][/tr]
[tr]
[td]Type[/td]
[td]read request[/td]
[/tr]
[tr]
[td]Description[/td]
[td]
$id is the wiki page ID or title.[/td][/tr]
[/tbody]
[/table]
h4#create. Create
[table]
[tbody]
[tr]
[td]HTTP Method[/td]
[td]POST[/td]
[/tr]
[tr]
[td]Base URL[/td]
[td]
/wiki_pages.json[/td][/tr]
[tr]
[td]Type[/td]
[td]write request[/td]
[/tr]
[/tbody]
[/table]
h5#create-parameters. Create parameters
* Required:
**
title* Optional
**
body**
other_names - Uses URL array parameter format.**
other_names_string - Space delimited list of post IDs.**
is_deleted**
is_locked
h4#update. Update
[table]
[tbody]
[tr]
[td]HTTP Method[/td]
[td]PUT/PATCH[/td]
[/tr]
[tr]
[td]Base URL[/td]
[td]
/wiki_pages/$id.json[/td][/tr]
[tr]
[td]Type[/td]
[td]write request[/td]
[/tr]
[tr]
[td]Description[/td]
[td]
$id is the wiki page ID or title.[/td][/tr]
[/tbody]
[/table]
h5#update-parameters. Update parameters
Accepts the "same parameters":[#dtext-create-parameters] as the "create wiki page action":[#dtext-create]. All parameters are optional.
h4#delete. Delete
[table]
[tbody]
[tr]
[td]HTTP Method[/td]
[td]DELETE[/td]
[/tr]
[tr]
[td]Base URL[/td]
[td]
/wiki_pages/$id.json[/td][/tr]
[tr]
[td]Type[/td]
[td]write request[/td]
[/tr]
[tr]
[td]Description[/td]
[td]
$id is the wiki page ID or title.[/td][/tr]
[/tbody]
[/table]
Note: This action can also be accomplished using the "update wiki page action":[#dtext-update] by setting
is_deleted to true.
h4#revert. Revert
[table]
[tbody]
[tr]
[td]HTTP Method[/td]
[td]PUT[/td]
[/tr]
[tr]
[td]Base URL[/td]
[td]
/wiki_pages/$id/revert.json[/td][/tr]
[tr]
[td]Type[/td]
[td]write request[/td]
[/tr]
[tr]
[td]Description[/td]
[td]
$id is the wiki page ID or title.[/td][/tr]
[/tbody]
[/table]
h5#revert-parameters. Revert parameters
* Required:
** version_id - The wiki page version ID to revert to.
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]