Skip to main content

Model classes for the Marktlokation ID Identification API by EDI@Energy (manually fixed)

Project description

MaLo Ident Python Models

License: MIT Python Versions (officially) supported Pypi status badge Unittests status badge Coverage status badge Linting status badge Black status badge

This package provides mostly autogenerated pydantic-based model classes for the MaLo ident API.

We also maintain a C#/.NET Version of this data model.

It does not provide you with an HTTP client.

Installation

Install it from PyPI

pip install maloident

Then use it:

from maloident.v1.models import ResultNegative

my_json = {
    "decisionTree": "E_0594",
    "responseCode": "A10",
    "reason": "Ich bin ein Freitext.",
    "networkOperator": 9900987654321,
}
result = ResultNegative.model_validate(my_json)

The request payload type for the Lieferant➡️Netzbetreiber identification request is maloident.models.IdentificationParameter.

See the tests for more examples.

Project Structure

This project is based on datamodel-code-generator. Most of the classes are autogenerated from the openapi.yml which can be found on SwaggerHub.

Note that we fixed some errors in the official OpenAPI spec. Our changes are mentioned at the beginning of the openapi.yml file.

https://github.com/Hochfrequenz/malo-ident-python-models/blob/3cfe0aea3cff051303ef5e513d06ab6c5741f21a/openapi/openapi.yml#L4-L10

After updating the openapi.yml file, use

tox -e codegen

to re-generate the model classes.

Contribute

You are very welcome to contribute to this template repository by opening a pull request against the main branch.

Project details


Download files

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

Source Distribution

maloident-2024.7.3.6.tar.gz (19.4 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

maloident-2024.7.3.6-py3-none-any.whl (9.4 kB view details)

Uploaded Python 3

File details

Details for the file maloident-2024.7.3.6.tar.gz.

File metadata

  • Download URL: maloident-2024.7.3.6.tar.gz
  • Upload date:
  • Size: 19.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/5.1.1 CPython/3.12.7

File hashes

Hashes for maloident-2024.7.3.6.tar.gz
Algorithm Hash digest
SHA256 ccf1bd1d434a961cfd67a149a692d47f203a98e16240151852522c79bbe6f8ad
MD5 c9eec30029ff7359dc8fdc20a78adf23
BLAKE2b-256 97957c35c24aa482eb0055e3cc79eff27a479a1dd82c85bbbf9e2f381d99da11

See more details on using hashes here.

Provenance

The following attestation bundles were made for maloident-2024.7.3.6.tar.gz:

Publisher: python-publish.yml on Hochfrequenz/malo-ident-python-models

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file maloident-2024.7.3.6-py3-none-any.whl.

File metadata

  • Download URL: maloident-2024.7.3.6-py3-none-any.whl
  • Upload date:
  • Size: 9.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/5.1.1 CPython/3.12.7

File hashes

Hashes for maloident-2024.7.3.6-py3-none-any.whl
Algorithm Hash digest
SHA256 1c7e69b501a85025fa25d1e892c35beac31092773a22d23151077c71bf7028db
MD5 8b6eb4b0c45b9609e60d7606b3d674a7
BLAKE2b-256 884bbf23b0b7918a15209ed70dd37e9491a9d27f393cc04d63d23b69a67222f9

See more details on using hashes here.

Provenance

The following attestation bundles were made for maloident-2024.7.3.6-py3-none-any.whl:

Publisher: python-publish.yml on Hochfrequenz/malo-ident-python-models

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page