--- id: pyxnat version: "1.6.4" license: BSD license_treatment: permissive maintenance: active --- # pyxnat — XNAT in Python License: permissive · Maintenance: active · Downloads: 401.7K/mo ## What it is and what it does pyxnat is a Python library that wraps the XNAT REST API, allowing researchers and developers to programmatically interact with XNAT servers—systems commonly used in neuroimaging and biomedical research to store, manage, and retrieve medical imaging data. It depends on requests for HTTP communication and lxml for XML parsing, which are core to XNAT's data exchange format. The package is classified as Beta and targets Python 3.9 and 3.10, with active maintenance and no known security vulnerabilities. Typically used in research workflows where imaging data needs to be queried, downloaded, or uploaded in bulk, or where imaging projects must be managed programmatically. It abstracts away the complexity of direct REST calls, offering a more Pythonic interface to XNAT's object hierarchy (projects, subjects, experiments, scans, resources). Use it for: - Batch download imaging datasets from an XNAT repository for local analysis pipelines. - Programmatically upload processed imaging results back to an XNAT server for archival and sharing. - Query and filter imaging projects by metadata to identify cohorts for research studies. - Automate routine data management tasks on XNAT servers without manual web interface interaction. - Integrate XNAT data access into reproducible research workflows and computational notebooks. ## Worth the install? AI-flagged interpretation of the facts above — verify before relying. pyxnat provides Python bindings to interact with XNAT (Extensible Neuroimaging Archive Toolkit) servers, enabling programmatic access to medical imaging data and project management through HTTP requests. Yes, if you work with XNAT servers in a research or clinical setting. The package is actively maintained, has no security vulnerabilities, and low install friction. It is the standard Python interface to XNAT and solves a real problem for anyone needing programmatic access to imaging archives. Not relevant if you do not use XNAT. ## Install pip install pyxnat uv add pyxnat poetry add pyxnat ## Installing pyxnat Before you install: Low friction installation with three stable runtime dependencies (lxml, requests, pathlib). Package is actively maintained with a recent release and no known vulnerabilities. License in practice: BSD license is permissive, allowing use in commercial and proprietary projects with minimal restrictions beyond attribution. Quickstart: pip install pyxnat import pyxnat xnat = pyxnat.Interface(server='http://xnat-server', user='username', password='password') project = xnat.select.project('PROJECT_ID') Requires an accessible XNAT server instance to connect to; authentication credentials needed. Verify before relying: - Whether pathlib is truly a runtime dependency or a standard library reference in the metadata. - Specific XNAT server version compatibility requirements beyond the general API. - Performance characteristics when working with large imaging datasets. ## Package facts - License: BSD (permissive) - Python support: unspecified - Install friction: low - Maintenance: active - Downloads: 401.7K/month (top 15,000 on PyPI) - Known vulnerabilities: none known ## Tags XNAT Python client, neuroimaging data access, medical imaging repository API, XNAT REST interface, biomedical data management Python, imaging archive integration, XNAT server interaction, medical-imaging, rest-api-client, research-data [View on SkillFed](https://skillfed.io/packages/pyxnat) · [View on PyPI](https://pypi.org/project/pyxnat/)