Jump to content
MediaWiki

Extension:WikimediaCampaignEvents

From mediawiki.org
MediaWiki extensions manual
WikimediaCampaignEvents
Release status: stable
Implementation Special page
Description Provides Wikimedia specific features for the CampaignEvents extension.
Author(s) Connection Team
Compatibility policy Snapshots releases along with MediaWiki. Master is not backward compatible.
Database changes Yes
Tables wikimedia_campaign_events_grant
License GNU General Public License 2.0 or later
Download
Help Help:Extension:WikimediaCampaignEvents
  • $wgWikimediaCampaignEventsFluxxOauthUrl
  • $wgWikimediaCampaignEventsSparqlEndpoint
  • $wgWikimediaCampaignEventsFluxxClientSecret
  • $wgWikimediaCampaignEventsFluxxClientID
  • $wgWikimediaCampaignEventsFluxxBaseUrl
Translate the WikimediaCampaignEvents extension if it is available at translatewiki.net
Issues Open tasks · Report a bug

Provides Wikimedia-specific features for the CampaignEvents extension. In particular, adds support for grants, and communicates with fluxx.io's grant management software. Organizers can associate their Grant ID with Event Registration data, so that it is easier to analyze the impact of their events.

Installation

[edit ]
  • Download and move the extracted WikimediaCampaignEvents folder to your extensions/ directory.
    Developers and code contributors should install the extension from Git instead, using:
    cdextensions/
    gitclonehttps://gerrit.wikimedia.org/r/mediawiki/extensions/WikimediaCampaignEvents
    
  • Add the following code at the bottom of your LocalSettings.php file:
    wfLoadExtension( 'WikimediaCampaignEvents' );
    
  • Run the update script which will automatically create the necessary database tables that this extension needs.
  • Add the credentials for the Fluxx API to your LocalSettings.php
  • Yes Done – Navigate to Special:Version on your wiki to verify that the extension is successfully installed.

Dependencies

[edit ]

Configuration

[edit ]
Setting name Default value Description
$wgWikimediaCampaignEventsFluxxOauthUrl 'https://wmf.fluxx.io/oauth/token' Oauth URL for the Fluxx API.
$wgWikimediaCampaignEventsFluxxBaseUrl 'https://wmf.fluxx.io/api/rest/v2/' Base URL of the Fluxx API.
$wgWikimediaCampaignEventsFluxxClientID null Client ID to use for the Fluxx API.
$wgWikimediaCampaignEventsFluxxClientSecret null Client secret to use for the Fluxx API.
$wgWikimediaCampaignEventsSparqlEndpoint 'https://query-main.wikidata.org/sparql' The URL of the primary SPARQL endpoint.

API

[edit ]

Documentation of all the API endpoints is available.

Integration with the Wikidata Query Service

[edit ]

The extension integrates with the Wikidata Query Service to show a list of all WikiProjects on Special:AllEvents. This functionality is implemented via the WikiProjectIDLookup class, which is based on SparqlClient.

WikiProjects are stored in the main stash for up to one week. However, the list is regenerated as soon as the value is older than one hour. All the value regenerations happen in a deferred update that does not block the main request: the user might be served a stale value while the fresh list is regenerated asynchronously.

Note that, if nobody visits the Special:AllEvents page for a whole week, the list of WikiProjects would expire, and an error would be shown upon loading the page. A data update should be enqueued at the same time, so the data should become available again shortly afterwards.

See also

[edit ]
This extension is being used on one or more Wikimedia projects. This probably means that the extension is stable and works well enough to be used by such high-traffic websites. Look for this extension's name in Wikimedia's CommonSettings.php and InitialiseSettings.php configuration files to see where it's installed. A full list of the extensions installed on a particular wiki can be seen on the wiki's Special:Version page.

AltStyle によって変換されたページ (->オリジナル) /