As an anonymous user, you can only add new data. If you would like to also modify existing data, please create an account and indicate your languages on your user page.

Help:OmegaWiki API

From OmegaWiki
(Redirected from omegawiki api)
Jump to: navigation, search

This page describes the elements of the API specific to OmegaWiki. All the functionalities of the standard MediaWiki API are also available.

Contents

[edit] Obtaining data

[edit] ow_define

Returns the definition of a DefinedMeaning in a specified language. Also returns the translation in that language.

Parameters:

  • dm, defined_meaning_id corresponding to the concept to define
  • lang, language_id of the definition to display

The following example defines DM DefinedMeaning:word_(6551) (word) in English (lang=85):

http://www.omegawiki.org/api.php?action=ow_define&lang=85&dm=6551&format=jsonfm

[edit] Modifying data

Modifying data requires that the user has a bot flag. Either login manually with your bot account, or use the API login function.

[edit] ow_add_syntrans

Adds a translation to a given DM.

Parameters:

  • e, spelling of the word to add
  • lang, language_id of the word to add
  • dm, defined_meaning_id to which the word should be added
  • im, identical_meaning (0 or 1)

The following example adds "word" for English (lang=85) as a translation for DM DefinedMeaning:word_(6551):

http://www.omegawiki.org/api.php?action=ow_add_syntrans&e=word&lang=85&dm=6551&im=1

Personal tools
Namespaces

Variants
Actions
Navigation
Contributing
Toolbox
  • What links here
  • Related changes
  • Special pages
  • Printable version