Pomoc MediaWiki API

To jest automatycznie wygenerowana strona dokumentacji MediaWiki API. Dokumentacja i przykłady: https://www.mediawiki.org/wiki/API

prop=templates (tl)

(main | query | templates)
  • Ten moduł wymaga praw odczytu.
  • Ten moduł może być użyty jako generator.
  • Źródło: MediaWiki
  • Licencja: GPL-2.0+

Returns all pages transcluded on the given pages.

Parametry:
tlnamespace

Show templates in this namespaces only.

Wartości (oddziel za pomocą |): 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 100, 101, 102, 103, 104, 105, 106, 107, 110, 111
tllimit

Ile szablonów zwrócić?

Nie więcej niż 500 (5000 dla botów) dozwolone.
Type: integer or max
Domyślnie: 10
tlcontinue

When more results are available, use this to continue.

tltemplates

Only list these templates. Useful for checking whether a certain page uses a certain template.

Oddziel wartości za pomocą |. Maksymalna liczba wartości to 50 (500 dla botów).
tldir

The direction in which to list.

Jedna z następujących wartość: ascending, descending
Domyślnie: ascending
Przykłady:
Get the templates used on the page Main Page.
api.php?action=query&prop=templates&titles=Main%20Page [open in sandbox]
Get information about the template pages used on Main Page.
api.php?action=query&generator=templates&titles=Main%20Page&prop=info [open in sandbox]
Get pages in the Użytkownik and Szablon namespaces that are transcluded on the page Main Page.
api.php?action=query&prop=templates&titles=Main%20Page&tlnamespace=2|10 [open in sandbox]