Skip to main content

Python XML Binding

Project description

Naive XML Bindings for python

xsData is a complete XML data binding library for python allowing developers to access and use XML documents as simple objects rather than using DOM.

It ships with a code generator for XML Schema definitions and WSDL 1.1 with SOAP 1.1 bindings. It produces simple dataclasses with type hints in order to reduce the learning curve for users that have to write the binding models manually.

The included xml parser and serializer are highly optimized and adaptable with handlers based on native python and lxml. The parser configuration offers the ability to skip unknown properties and to process xinclude statements.

xsData is constantly tested against the W3C XML Schema 1.1 test suite.

Check the documentation demos or our W3C XML Schema 1.1 test runner and the samples repo for more ✨✨✨


  • Generate data models for XML Schema 1.0 and 1.1 definitions.
  • Generate data models for WSDL 1.1 and SOAP 1.1 bindings.
  • Support qualified elements/attributes, enumerations and inner classes.
  • Preserve embedded documentation and references.
  • Data binding for XML and JSON documents.
  • Pluggable code writer that supports python dataclasses and PlantUML class diagrams.

Changelog: 21.3 (2021-03-04)

  • Added constant name convention config #407
  • Added naming schemes screaming snake case and original case
  • Updated xsi:lookup on xs:any derived elements #315
  • Updated fields restriction inheritance #417
  • Updated cli to allow package override from arguments #416
  • Updated code generation to merge duplicate global types earlier #406
  • Fixed docstrings issue breaking python syntax #403
  • Fixed bindings for nillable content without workarounds #408
  • Fixed resolver to apply aliases on extensions and choice fields #414
  • Fixed schema models limiting xs:appinfo occurrences #420
  • Decoupled core systems from click and lxml

Notice: In the next release installation profiles will be introduced that will turn the cli, lxml and soap features optional.

Project details

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Files for xsdata, version 21.3
Filename, size File type Python version Upload date Hashes
Filename, size xsdata-21.3-py3-none-any.whl (135.8 kB) File type Wheel Python version py3 Upload date Hashes View
Filename, size xsdata-21.3.tar.gz (220.5 kB) File type Source Python version None Upload date Hashes View

Supported by

Pingdom Pingdom Monitoring Google Google Object Storage and Download Analytics Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN DigiCert DigiCert EV certificate StatusPage StatusPage Status page