{"id":15017725,"url":"https://github.com/jfilter/mw-category-members","last_synced_at":"2025-04-12T12:33:44.291Z","repository":{"id":52266227,"uuid":"148014456","full_name":"jfilter/mw-category-members","owner":"jfilter","description":"Using MediaWiki's API, retrieve pages that belong to a given category","archived":false,"fork":false,"pushed_at":"2022-12-08T07:44:11.000Z","size":21,"stargazers_count":4,"open_issues_count":1,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-04-06T14:10:00.172Z","etag":null,"topics":["mediawiki","mediawiki-api","python","wikipedia","wikipedia-api"],"latest_commit_sha":null,"homepage":"https://www.mediawiki.org/wiki/API:Categorymembers","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/jfilter.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2018-09-09T10:22:32.000Z","updated_at":"2025-03-03T16:18:20.000Z","dependencies_parsed_at":"2022-09-12T03:21:59.343Z","dependency_job_id":null,"html_url":"https://github.com/jfilter/mw-category-members","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jfilter%2Fmw-category-members","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jfilter%2Fmw-category-members/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jfilter%2Fmw-category-members/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jfilter%2Fmw-category-members/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/jfilter","download_url":"https://codeload.github.com/jfilter/mw-category-members/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248566660,"owners_count":21125699,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["mediawiki","mediawiki-api","python","wikipedia","wikipedia-api"],"created_at":"2024-09-24T19:50:54.320Z","updated_at":"2025-04-12T12:33:44.271Z","avatar_url":"https://github.com/jfilter.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# mw-category-members [![Build Status](https://travis-ci.com/jfilter/mw-category-members.svg?branch=master)](https://travis-ci.com/jfilter/mw-category-members) [![PyPI](https://img.shields.io/pypi/v/mw-category-members.svg)](https://pypi.org/project/mw-category-members/) [![PyPI - Python Version](https://img.shields.io/pypi/pyversions/mw-category-members.svg)](https://pypi.org/project/mw-category-members/)\n\nUsing MediaWiki's API: retrieve pages that belong to a given category\n\n## Installation\n\n`pip install mw_category_members`\n\n## Usage\n\n```python\nimport category_members\n\nresults = category_members.retrieve('Category:Presidents_of_the_United_States')\nfor r in results:\n    print(r['name'], r['link'])\n```\n\n### Arguments\n\n```python\ndef retrieve(cat_name, mw_instance='https://en.wikipedia.org', types=['page', 'subcat', 'file'], clean_subcat_names=False):\n```\n\n-   cat_name: Category name e.g. 'Category:Presidents_of_the_United_States'.\n-   mw_instance: Which MediaWiki instance to use (the URL 'origin'). Defaults to 'https://en.wikipedia.org'.\n-   types: Which types of pages to retrieve. Defaults to `['page', 'subcat', 'file']`.\n-   clean_subcat_names: If `True`, removes the e.g. 'Category:' prefix of the titles. Defaults to `False`.\n\n### Returns\n\nArray of pages where a page is a dictionary of `{'name': 'some name', 'link': 'some absolute link'}`.\n\n## License\n\nMIT.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjfilter%2Fmw-category-members","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjfilter%2Fmw-category-members","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjfilter%2Fmw-category-members/lists"}