v3.0.0+
Status: | effective |
Progress: | 100% |
Version: | 3.0.0+ |
English
The semantic API modules (SMW API) are provided by Semantic MediaWiki and related extensions enabling external components or data services to access semantically annotated information stored in the Semantic MediaWiki database via several available interfaces using a standardized HTTP request.
The semantic API modules allow to select and retrieve, i.e. read annotated information stored on the wiki. If information has to be written to the wiki then the regular MediaWiki API-modules available for editing must be used. This is to ensure that the corresponding wiki page is updated the same way as when one would edit on-wiki. Moreover this also makes sure that no information accessible via a wiki page revision is lost.
API modules[edit]
Active modules
Help page | Description | Provided by | Since |
---|---|---|---|
API module "ask" | Allows to do ask queries | Semantic MediaWiki | 1.7.0 |
API module "askargs" | Allows to do ask queries with as little ask query specific syntax as possible | Semantic MediaWiki | 1.7.0 |
API module "smwbrowse" | Allows to search for properties, categories and concepts | Semantic MediaWiki | 3.0.0 |
API module "smwinfo" | Allows to access statistical data and information about the usage of Semantic MediaWiki | Semantic MediaWiki | 1.6.0 |
API module "smwtask" | Allows to invoke and execute internal Semantic MediaWiki tasks | Semantic MediaWiki | 3.0.0 |
API module "compoundquery" | Allows to do compounded ask queries | Semantic Compound Queries | 1.0.0 |
Deprecated modules
Help page | Description | Provided by | Since |
---|---|---|---|
API module "browsebyproperty" | Allows to fetch information about a property or a list of properties | Semantic MediaWiki | 2.4.0 |
API module "browsebysubject" | Allows to browse a subject, i.e. a page or subobject | Semantic MediaWiki | 1.9.0 |
Configuration parameters[edit]
- Manual page on configuration parameter
$wgCrossSiteAJAXdomains
(MediaWiki.org) − Allows to specify domains that may make cross-site Ajax requests to the MediaWiki API for Cross-origin resource sharing (CORS) - Manual page on configuration parameter
$wgEnableAPI
(MediaWiki.org) − Allows to enable direct access to the MediaWiki API through "api.php" (deprecated in MediaWiki 1.31 and removed in 1.32, i.e. the API cannot be disabled for reading.) - Manual page on configuration parameter
$wgEnableWriteAPI
(MediaWiki.org) − Allows the MediaWiki API to be used through "api.php" to perform write operations (page edits, uploads, etc.) when an authorized user accesses it (deprecated in MediaWiki 1.31 and removed in 1.32, i.e. the API cannot be disabled for writing.)
See also[edit]
- General README of the SMW API as provided via the source code
- Help page on Troubleshooting the SMW API
- Help page on Serialization (JSON) performed by the SMW API
- RFC concerning the SMW API on the SMW developer list, September 18, 2011
- Video of a related talk at SMWCon 2011 fall in Berlin