Ajuda API da MediaWiki

Esta é uma página de documentação API do MediaWiki gerada automaticamente.

Documentação e exemplos: https://www.mediawiki.org/wiki/API

prop=categories (cl)

(main | query | categories)
  • This module requires read rights.
  • This module can be used as a generator.
  • Fonte: MediaWiki
  • Licença: GPL-2.0+

List all categories the pages belong to.

Parâmetros:
clprop

Which additional properties to get for each category:

sortkey
Adds the sortkey (hexadecimal string) and sortkey prefix (human-readable part) for the category.
timestamp
Adds timestamp of when the category was added.
hidden
Tags categories that are hidden with __HIDDENCAT__.
Valores (separar com |): sortkey, timestamp, hidden
clshow

Which kind of categories to show.

Valores (separar com |): hidden, !hidden
cllimit

Quantas categorias retornar.

No more than 500 (5 000 for bots) allowed.
Tipo: inteiro ou max
Padrão: 10
clcontinue

When more results are available, use this to continue.

clcategories

Only list these categories. Useful for checking whether a certain page is in a certain category.

Separe os valores com |. Maximum number of values is 50 (500 for bots).
cldir

The direction in which to list.

Um dos seguintes valores: ascending, descending
Padrão: ascending
Exemplos:
Get a list of categories the page Albert Einstein belongs to.
api.php?action=query&prop=categories&titles=Albert%20Einstein [abrir na página de testes]
Get information about all categories used in the page Albert Einstein.
api.php?action=query&generator=categories&titles=Albert%20Einstein&prop=info [abrir na página de testes]