x12-edi-tools


Namex12-edi-tools JSON
Version 0.1.2 PyPI version JSON
download
home_pagehttps://github.com/copyleftdev/x12-edi-tools
SummaryA comprehensive set of tools for working with X12 EDI files
upload_time2024-07-30 14:20:27
maintainerNone
docs_urlNone
authorDon Johnson
requires_python>=3.7
licenseNone
keywords
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # X12 EDI Tools

![X12 EDI Tools Logo](logo.png)
![Python](https://img.shields.io/badge/Python-3.9+-blue?logo=python)



A comprehensive Python library for working with X12 EDI (Electronic Data Interchange) files, commonly used in healthcare for claims processing, eligibility verification, and other administrative transactions.

## Installation

Install the X12 EDI Tools library using pip:

```bash
pip install x12-edi-tools
```

## Key Components

### X12Parser
Parses X12 files into Python objects.

```python
from x12_edi_tools.x12_parser import X12Parser

parser = X12Parser()
parsed_data = parser.parse("path/to/x12_file.edi")
print(parsed_data)
```

### X12Generator
Generates X12 files from Python objects.

```python
from x12_edi_tools.x12_generator import X12Generator

generator = X12Generator()
x12_content = generator.generate(data_dict)
with open("output.edi", "w") as f:
    f.write(x12_content)
```

### X12Validator
Validates X12 files against standard formats and custom rules.

```python
from x12_edi_tools.x_12_validator import X12Validator

validator = X12Validator()
is_valid, errors = validator.validate("path/to/x12_file.edi")
if not is_valid:
    print("Validation errors:", errors)
```

### DentalClaimProcessor
Processes dental claims (837D transactions).

```python
from x12_edi_tools.dental_claim_processor import DentalClaimProcessor

processor = DentalClaimProcessor()
claims = processor.process("path/to/837D_file.edi")
for claim in claims:
    print(f"Claim ID: {claim.claim_id}, Patient: {claim.patient_name}")
```

### EligibilityChecker
Handles eligibility inquiries and responses (270/271 transactions).

```python
from x12_edi_tools.eligibility_checker import EligibilityChecker

checker = EligibilityChecker()
request = checker.create_270_request(patient_data)
response = checker.process_271_response(response_data)
print(f"Patient eligible: {response.is_eligible}")
```

### RemittanceAdviceParser
Parses remittance advice (835) transactions.

```python
from x12_edi_tools.remittance_advise_parser import RemittanceAdviceParser

parser = RemittanceAdviceParser()
remittance = parser.parse("path/to/835_file.edi")
print(f"Total paid: ${remittance.total_paid}")
```

### X12Converter
Converts X12 data to and from other formats like JSON and CSV.

```python
from x12_edi_tools.x_12_converter import X12Converter

converter = X12Converter()
json_data = converter.to_json("path/to/x12_file.edi")
csv_data = converter.to_csv("path/to/x12_file.edi")
```

### X12Encryptor
Encrypts and decrypts X12 data for secure transmission and storage.

```python
from x12_edi_tools.x_12_encryptor import X12Encryptor

encryptor = X12Encryptor("your-secret-key")
encrypted_data = encryptor.encrypt("path/to/x12_file.edi")
decrypted_data = encryptor.decrypt(encrypted_data)
```

### X12DatabaseIntegrator
Facilitates integration of X12 data with databases.

```python
from x12_edi_tools.x_12_database_integrator import X12DatabaseIntegrator

integrator = X12DatabaseIntegrator("database_connection_string")
integrator.store_transaction("path/to/x12_file.edi")
transactions = integrator.retrieve_transactions(date_range)
```

### X12Logger
Provides detailed logging of X12 operations for auditing and troubleshooting.

```python
from x12_edi_tools.x_12_logger import X12Logger

logger = X12Logger("path/to/log/directory")
logger.log_parse("837", "path/to/837_file.edi", parse_result)
logger.log_generate("835", "path/to/835_file.edi", generation_data)
```

## Contributing

Contributions are welcome! Please feel free to submit a Pull Request.

## Contact

Don Johnson - dj@codetestcode.io

Project Link: [https://github.com/donjohnson/x12-edi-tools](https://github.com/donjohnson/x12-edi-tools)

            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/copyleftdev/x12-edi-tools",
    "name": "x12-edi-tools",
    "maintainer": null,
    "docs_url": null,
    "requires_python": ">=3.7",
    "maintainer_email": null,
    "keywords": null,
    "author": "Don Johnson",
    "author_email": "dj@codetestcode.io",
    "download_url": "https://files.pythonhosted.org/packages/ad/8f/494edc0b8c5607d6ca02ea8baed94ca721adf429204c76d8818f00ee0356/x12_edi_tools-0.1.2.tar.gz",
    "platform": null,
    "description": "# X12 EDI Tools\n\n![X12 EDI Tools Logo](logo.png)\n![Python](https://img.shields.io/badge/Python-3.9+-blue?logo=python)\n\n\n\nA comprehensive Python library for working with X12 EDI (Electronic Data Interchange) files, commonly used in healthcare for claims processing, eligibility verification, and other administrative transactions.\n\n## Installation\n\nInstall the X12 EDI Tools library using pip:\n\n```bash\npip install x12-edi-tools\n```\n\n## Key Components\n\n### X12Parser\nParses X12 files into Python objects.\n\n```python\nfrom x12_edi_tools.x12_parser import X12Parser\n\nparser = X12Parser()\nparsed_data = parser.parse(\"path/to/x12_file.edi\")\nprint(parsed_data)\n```\n\n### X12Generator\nGenerates X12 files from Python objects.\n\n```python\nfrom x12_edi_tools.x12_generator import X12Generator\n\ngenerator = X12Generator()\nx12_content = generator.generate(data_dict)\nwith open(\"output.edi\", \"w\") as f:\n    f.write(x12_content)\n```\n\n### X12Validator\nValidates X12 files against standard formats and custom rules.\n\n```python\nfrom x12_edi_tools.x_12_validator import X12Validator\n\nvalidator = X12Validator()\nis_valid, errors = validator.validate(\"path/to/x12_file.edi\")\nif not is_valid:\n    print(\"Validation errors:\", errors)\n```\n\n### DentalClaimProcessor\nProcesses dental claims (837D transactions).\n\n```python\nfrom x12_edi_tools.dental_claim_processor import DentalClaimProcessor\n\nprocessor = DentalClaimProcessor()\nclaims = processor.process(\"path/to/837D_file.edi\")\nfor claim in claims:\n    print(f\"Claim ID: {claim.claim_id}, Patient: {claim.patient_name}\")\n```\n\n### EligibilityChecker\nHandles eligibility inquiries and responses (270/271 transactions).\n\n```python\nfrom x12_edi_tools.eligibility_checker import EligibilityChecker\n\nchecker = EligibilityChecker()\nrequest = checker.create_270_request(patient_data)\nresponse = checker.process_271_response(response_data)\nprint(f\"Patient eligible: {response.is_eligible}\")\n```\n\n### RemittanceAdviceParser\nParses remittance advice (835) transactions.\n\n```python\nfrom x12_edi_tools.remittance_advise_parser import RemittanceAdviceParser\n\nparser = RemittanceAdviceParser()\nremittance = parser.parse(\"path/to/835_file.edi\")\nprint(f\"Total paid: ${remittance.total_paid}\")\n```\n\n### X12Converter\nConverts X12 data to and from other formats like JSON and CSV.\n\n```python\nfrom x12_edi_tools.x_12_converter import X12Converter\n\nconverter = X12Converter()\njson_data = converter.to_json(\"path/to/x12_file.edi\")\ncsv_data = converter.to_csv(\"path/to/x12_file.edi\")\n```\n\n### X12Encryptor\nEncrypts and decrypts X12 data for secure transmission and storage.\n\n```python\nfrom x12_edi_tools.x_12_encryptor import X12Encryptor\n\nencryptor = X12Encryptor(\"your-secret-key\")\nencrypted_data = encryptor.encrypt(\"path/to/x12_file.edi\")\ndecrypted_data = encryptor.decrypt(encrypted_data)\n```\n\n### X12DatabaseIntegrator\nFacilitates integration of X12 data with databases.\n\n```python\nfrom x12_edi_tools.x_12_database_integrator import X12DatabaseIntegrator\n\nintegrator = X12DatabaseIntegrator(\"database_connection_string\")\nintegrator.store_transaction(\"path/to/x12_file.edi\")\ntransactions = integrator.retrieve_transactions(date_range)\n```\n\n### X12Logger\nProvides detailed logging of X12 operations for auditing and troubleshooting.\n\n```python\nfrom x12_edi_tools.x_12_logger import X12Logger\n\nlogger = X12Logger(\"path/to/log/directory\")\nlogger.log_parse(\"837\", \"path/to/837_file.edi\", parse_result)\nlogger.log_generate(\"835\", \"path/to/835_file.edi\", generation_data)\n```\n\n## Contributing\n\nContributions are welcome! Please feel free to submit a Pull Request.\n\n## Contact\n\nDon Johnson - dj@codetestcode.io\n\nProject Link: [https://github.com/donjohnson/x12-edi-tools](https://github.com/donjohnson/x12-edi-tools)\n",
    "bugtrack_url": null,
    "license": null,
    "summary": "A comprehensive set of tools for working with X12 EDI files",
    "version": "0.1.2",
    "project_urls": {
        "Homepage": "https://github.com/copyleftdev/x12-edi-tools"
    },
    "split_keywords": [],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "e1da35f50ed8b6627fb091c5d6708b9b568a3bdf7cbad55f2cffbd62e4f99305",
                "md5": "aab1156c5514fb47c6ec01ddbee6260a",
                "sha256": "947501f3505be00a41021aebd05461eb338b9ac3f76dcffe5733e82ede080f76"
            },
            "downloads": -1,
            "filename": "x12_edi_tools-0.1.2-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "aab1156c5514fb47c6ec01ddbee6260a",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.7",
            "size": 29289,
            "upload_time": "2024-07-30T14:20:26",
            "upload_time_iso_8601": "2024-07-30T14:20:26.210033Z",
            "url": "https://files.pythonhosted.org/packages/e1/da/35f50ed8b6627fb091c5d6708b9b568a3bdf7cbad55f2cffbd62e4f99305/x12_edi_tools-0.1.2-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "ad8f494edc0b8c5607d6ca02ea8baed94ca721adf429204c76d8818f00ee0356",
                "md5": "33a8c0c929353f737c85f0175f40ca66",
                "sha256": "36ca105b9802161a2cd23c4a4f5fd6185bdcad8afc031599722e2701ee7df55f"
            },
            "downloads": -1,
            "filename": "x12_edi_tools-0.1.2.tar.gz",
            "has_sig": false,
            "md5_digest": "33a8c0c929353f737c85f0175f40ca66",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.7",
            "size": 22941,
            "upload_time": "2024-07-30T14:20:27",
            "upload_time_iso_8601": "2024-07-30T14:20:27.850626Z",
            "url": "https://files.pythonhosted.org/packages/ad/8f/494edc0b8c5607d6ca02ea8baed94ca721adf429204c76d8818f00ee0356/x12_edi_tools-0.1.2.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-07-30 14:20:27",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "copyleftdev",
    "github_project": "x12-edi-tools",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": true,
    "lcname": "x12-edi-tools"
}
        
Elapsed time: 4.52808s