Metadata-Version: 2.4
Name: lpdfio-lpdf
Version: 0.7.0
Summary: Python SDK for Lpdf — PDF as Code on every platform. You describe a document as code or XML. Lpdf renders a compact, pixel-perfect PDF — identical across platforms.
Project-URL: Homepage, https://lpdf.io
Project-URL: Repository, https://github.com/lpdfio/lpdf-python
Project-URL: Changelog, https://github.com/lpdfio/lpdf/releases
Author-email: "lpdf.io" <support@lpdf.io>
License: # Lpdf License
        
        Copyright © 2026 Codesense LLC
        
        License inquiries: license@lpdf.io
        
        ---
        
        ## Choosing Your License
        
        Lpdf is available under three license tiers: a free Community License for individuals and qualifying organizations, a Professional License for mid-size commercial use, and an Enterprise License for larger organizations. All license tiers receive the complete feature set — no capabilities are gated behind paid plans.
        
        ### Equal Features Across All Tiers
        
        Every user of Lpdf, regardless of license tier, has access to the same library, the same layout engine, the same adapters, and the same output quality. Licensing determines the terms of use, not the features available.
        
        ### Transitive Dependency
        
        If Lpdf is pulled in as an indirect dependency of another library or framework rather than used directly in your project, the Community License applies automatically, regardless of your organization's revenue.
        
        This exemption does not apply if the dependency was introduced, created, or controlled by the licensee's organization for the purpose of circumventing license requirements.
        
        ### Individuals and Open-Source Projects
        
        Personal use and open-source projects whose source code is publicly available under an OSI-approved license qualify for the Community License at no cost.
        
        ### Non-Profit Organizations
        
        Legally recognized non-profit organizations (including 501(c)(3) entities in the United States and equivalent status in other jurisdictions) qualify for the Community License regardless of operating budget.
        
        ### Small Businesses
        
        Companies and organizations whose total annual gross revenue did not exceed **1,000,000 USD** in the most recent 12-month fiscal year qualify for the Community License at no cost, including for commercial products and services.
        
        Organizations whose revenue crosses the 1,000,000 USD threshold have a **90-day grace period** following the close of their fiscal year to obtain a Professional or Enterprise license. During this grace period, continued use is permitted.
        
        ### Mid-Size Businesses
        
        Companies and organizations whose total annual gross revenue exceeded **1,000,000 USD** but did not exceed **10,000,000 USD** in the most recent 12-month fiscal year must obtain a Professional License to use Lpdf in production environments.
        
        "Production environment" means any environment in which the Software processes real user data or supports live business operations, including staging environments accessible by end users.
        
        ### Larger Businesses
        
        Companies and organizations whose total annual gross revenue exceeded **10,000,000 USD** in the most recent 12-month fiscal year must obtain an Enterprise License to use Lpdf in production environments.
        
        Organizations whose revenue crosses the 10,000,000 USD threshold have a **90-day grace period** following the close of their fiscal year to obtain an Enterprise license. During this grace period, continued use under a Professional License is permitted. The licensee remains subject to the terms of their existing Professional License and does not gain Enterprise rights until an Enterprise License is obtained.
        
        ### Supporting Lpdf
        
        Paid licenses directly fund the continued development, maintenance, and improvement of Lpdf. If your organization has grown beyond the Community threshold, purchasing a license is the most direct way to ensure Lpdf continues to exist and improve.
        
        ---
        
        ## Lpdf Community License
        
        *Applies to: individuals, open-source projects, non-profit organizations, and companies with annual gross revenue under 1,000,000 USD.*
        
        Permission is hereby granted, free of charge, to any person or qualifying organization obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
        
        The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. Any redistribution of the Software must be made under the terms of this Community License and may not be sublicensed under different terms.
        
        All modifications to the Software made by the licensee remain the intellectual property of the licensee. Codesense LLC claims no ownership over modifications unless they are voluntarily submitted as contributions to the Lpdf project under a separate Contributor License Agreement.
        
        If your organization's annual gross revenue exceeds 1,000,000 USD, your rights under this Community License are automatically terminated upon expiration of the 90-day grace period described above, and you must obtain a Professional or Enterprise license before continuing to use Lpdf in production.
        
        ### Governing Law
        
        This license is governed by and construed in accordance with the laws of the State of Texas, United States, without regard to its conflict of law provisions.
        
        ### Disclaimer of Warranty
        
        THE SOFTWARE IS PROVIDED "AS IS," WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, AND NONINFRINGEMENT. IN NO EVENT SHALL CODESENSE LLC OR ITS CONTRIBUTORS BE LIABLE FOR ANY CLAIM, DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES, OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF, OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. IN NO EVENT SHALL CODESENSE LLC'S TOTAL CUMULATIVE LIABILITY TO ANY PARTY EXCEED THE GREATER OF (A) THE FEES PAID BY THAT PARTY TO CODESENSE LLC IN THE TWELVE MONTHS PRECEDING THE CLAIM, OR (B) ONE HUNDRED US DOLLARS (USD 100).
        
        ---
        
        ## Lpdf Professional License
        
        *Applies to: companies and organizations with annual gross revenue exceeding 1,000,000 USD and not exceeding 10,000,000 USD.*
        
        ### Conduct
        
        Licensees agree not to make false statements of fact about Lpdf, Codesense LLC, or its contributors that are intended to cause material harm to the reputation of the project or the company. This clause does not restrict good-faith criticism, bug reports, public discussion of software deficiencies, or reviews based on the licensee's genuine experience.
        
        License rights may not be rented, leased, or transferred to any third party.
        
        ### License Grant
        
        Subject to payment of the applicable license fee, Codesense LLC grants the licensee a non-exclusive, worldwide, royalty-free license to:
        
        - Use, copy, modify, and integrate the Software into unlimited applications and projects
        - Distribute the Software as part of compiled or packaged commercial products
        - Deploy the Software across unlimited servers, environments, and infrastructure
        
        ### License Fees and Evaluation
        
        A license fee is required for use of Lpdf in production environments (as defined above). Evaluation and testing in non-production environments is permitted without a license for a period not exceeding 30 days.
        
        Upon payment, the licensee receives a perpetual license for the version of Lpdf current at the time of purchase, plus one year of updates, new features, and security patches. Continued access to new versions after the first year requires annual renewal. Cancellation of renewal does not affect the perpetual license for the version already held.
        
        ### Support
        
        Professional License holders receive email support from Codesense LLC with a target response time of 3 business days for standard inquiries. Support terms are further detailed at lpdf.io/support.
        
        ### Audit
        
        Codesense LLC may, upon 30 days' written notice and no more than once per calendar year, request a written certification from the licensee confirming their applicable license tier and annual gross revenue for the most recent fiscal year. The licensee agrees to provide such certification within 15 business days of the request.
        
        ### Ownership and Modifications
        
        Codesense LLC retains all ownership, copyright, and intellectual property rights in the Software at all times. This license grants rights to use the Software; it does not transfer ownership of any kind.
        
        All modifications to the Software made by the licensee remain the intellectual property of the licensee. Codesense LLC claims no ownership over licensee modifications unless they are voluntarily submitted as contributions to the Lpdf project under a separate Contributor License Agreement.
        
        ### Copyright
        
        All copies, modifications, and distributions of the Software must retain the original copyright notice. Licensees may not remove, alter, or obscure any copyright, trademark, or attribution notices included in the Software.
        
        ### Data and Privacy
        
        Codesense LLC does not collect, process, or retain any data that the licensee processes through the Software. All data processed by Lpdf remains solely within the licensee's infrastructure. For more information, see the Codesense LLC Privacy Policy at lpdf.io/privacy.
        
        ### Export Compliance
        
        The Software may be subject to export control laws and regulations, including the U.S. Export Administration Regulations (EAR) and sanctions programs administered by OFAC. The licensee is solely responsible for complying with all applicable export control and sanctions laws in connection with the licensee's use of the Software.
        
        ### Disclaimer of Warranty
        
        THIS SOFTWARE IS PROVIDED "AS IS," WITHOUT A WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, AND NONINFRINGEMENT. IN NO EVENT SHALL CODESENSE LLC OR ITS CONTRIBUTORS BE LIABLE FOR ANY CLAIM, DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES, OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF, OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. IN NO EVENT SHALL CODESENSE LLC'S TOTAL CUMULATIVE LIABILITY TO ANY PARTY EXCEED THE GREATER OF (A) THE FEES PAID BY THAT PARTY TO CODESENSE LLC IN THE TWELVE MONTHS PRECEDING THE CLAIM, OR (B) ONE HUNDRED US DOLLARS (USD 100).
        
        ### Governing Law and Dispute Resolution
        
        This license is governed by and construed in accordance with the laws of the State of Texas, United States, without regard to its conflict of law provisions.
        
        Any dispute arising out of or relating to this license or the Software shall be resolved by binding arbitration administered by the American Arbitration Association under its Commercial Arbitration Rules. The arbitration shall take place in Plano, Texas. Judgment on the award rendered by the arbitrator may be entered in any court of competent jurisdiction.
        
        Notwithstanding the foregoing, either party may seek injunctive or other equitable relief in any court of competent jurisdiction to prevent the actual or threatened infringement, misappropriation, or violation of a party's intellectual property rights.
        
        ---
        
        ## Lpdf Enterprise License
        
        *Applies to: companies and organizations with annual gross revenue exceeding 10,000,000 USD.*
        
        ### Conduct
        
        Licensees agree not to make false statements of fact about Lpdf, Codesense LLC, or its contributors that are intended to cause material harm to the reputation of the project or the company. This clause does not restrict good-faith criticism, bug reports, public discussion of software deficiencies, or reviews based on the licensee's genuine experience.
        
        License rights may not be rented, leased, or transferred to any third party, except as expressly permitted under the subsidiary grant below.
        
        ### License Grant
        
        Subject to payment of the applicable license fee, Codesense LLC grants the licensee a non-exclusive, worldwide, royalty-free license for an unlimited number of developers within the licensee's organization to:
        
        - Use, copy, modify, and integrate the Software into unlimited applications and projects
        - Distribute the Software as part of compiled or packaged commercial products
        - Deploy the Software across unlimited servers, environments, and infrastructure
        - Extend license rights to wholly owned subsidiaries and entities in which the licensee holds more than 50% ownership or voting control ("Controlled Entities"), provided such Controlled Entities are identified to Codesense LLC upon request and remain subject to the terms of this license
        
        ### License Fees and Evaluation
        
        A license fee is required for use of Lpdf in production environments (as defined above). Evaluation and testing in non-production environments is permitted without a license for a period not exceeding 30 days.
        
        Upon payment, the licensee receives a perpetual license for the version of Lpdf current at the time of purchase, plus one year of updates, new features, and security patches. Continued access to new versions after the first year requires annual renewal. Cancellation of renewal does not affect the perpetual license for the version already held.
        
        ### Support
        
        Enterprise License holders receive priority support from Codesense LLC. Supported response times and escalation procedures are defined in the Enterprise Support Policy at lpdf.io/support/enterprise. Custom SLA terms may be negotiated as part of a Master Service Agreement.
        
        ### Contract
        
        Enterprise licensees may request a Master Service Agreement (MSA) in place of the standard Terms of Service available at lpdf.io/terms. To initiate an MSA request, contact license@lpdf.io. The standard terms govern until a fully executed MSA is in place. Invoice billing is available upon request.
        
        ### Audit
        
        Codesense LLC may, upon 30 days' written notice and no more than once per calendar year, request a written certification from the licensee confirming their applicable license tier and annual gross revenue for the most recent fiscal year, and may request a list of Controlled Entities covered under the subsidiary grant. The licensee agrees to provide such certification within 15 business days of the request. For Enterprise licensees under an MSA, audit rights may be further defined therein.
        
        ### Ownership and Modifications
        
        Codesense LLC retains all ownership, copyright, and intellectual property rights in the Software at all times. This license grants rights to use the Software; it does not transfer ownership of any kind.
        
        All modifications to the Software made by the licensee remain the intellectual property of the licensee. Codesense LLC claims no ownership over licensee modifications unless they are voluntarily submitted as contributions to the Lpdf project under a separate Contributor License Agreement.
        
        ### Copyright
        
        All copies, modifications, and distributions of the Software must retain the original copyright notice. Licensees may not remove, alter, or obscure any copyright, trademark, or attribution notices included in the Software.
        
        ### Data and Privacy
        
        Codesense LLC does not collect, process, or retain any data that the licensee processes through the Software. All data processed by Lpdf remains solely within the licensee's infrastructure. For more information, see the Codesense LLC Privacy Policy at lpdf.io/privacy.
        
        ### Export Compliance
        
        The Software may be subject to export control laws and regulations, including the U.S. Export Administration Regulations (EAR) and sanctions programs administered by OFAC. The licensee is solely responsible for complying with all applicable export control and sanctions laws in connection with the licensee's use of the Software.
        
        ### Disclaimer of Warranty
        
        THIS SOFTWARE IS PROVIDED "AS IS," WITHOUT A WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, AND NONINFRINGEMENT. IN NO EVENT SHALL CODESENSE LLC OR ITS CONTRIBUTORS BE LIABLE FOR ANY CLAIM, DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES, OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF, OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. IN NO EVENT SHALL CODESENSE LLC'S TOTAL CUMULATIVE LIABILITY TO ANY PARTY EXCEED THE GREATER OF (A) THE FEES PAID BY THAT PARTY TO CODESENSE LLC IN THE TWELVE MONTHS PRECEDING THE CLAIM, OR (B) ONE HUNDRED US DOLLARS (USD 100).
        
        ### Governing Law and Dispute Resolution
        
        This license is governed by and construed in accordance with the laws of the State of Texas, United States, without regard to its conflict of law provisions.
        
        Any dispute arising out of or relating to this license or the Software shall be resolved by binding arbitration administered by the American Arbitration Association under its Commercial Arbitration Rules. The arbitration shall take place in Plano, Texas. Judgment on the award rendered by the arbitrator may be entered in any court of competent jurisdiction.
        
        Notwithstanding the foregoing, either party may seek injunctive or other equitable relief in any court of competent jurisdiction to prevent the actual or threatened infringement, misappropriation, or violation of a party's intellectual property rights.
        
        ---
        
        For license purchases and inquiries: license@lpdf.io
        
        Privacy Policy: lpdf.io/privacy | Terms of Service: lpdf.io/terms | Support: lpdf.io/support
License-File: LICENSE
Keywords: document,pdf,wasm,xml
Classifier: Development Status :: 4 - Beta
Classifier: Intended Audience :: Developers
Classifier: Programming Language :: Python :: 3
Classifier: Topic :: Software Development :: Libraries
Requires-Python: >=3.8
Description-Content-Type: text/markdown

<p align="center"><img src="lpdf-light.png" height="48" alt="Lpdf"></p>

# lpdfio-lpdf

**Python SDK for [Lpdf](https://lpdf.io) — PDF as Code on every platform**

You describe a document as code or XML. Lpdf renders a compact, pixel-perfect PDF — identical across platforms.

## Installation

```bash
pip install lpdfio-lpdf
```

## Usage

```python
from lpdf import L, NoAttr

engine = L.engine()

doc = L.document(DocumentAttr(size='letter', margin='48pt'), [
    L.section(NoAttr, [
        L.layout(NoAttr, [
            L.stack(StackAttr(gap='24pt'), [
                L.split(NoAttr, [
                    L.text(TextAttr(font_size='8pt', color='#888888'), ['ACME CORP']),
                    L.text(TextAttr(font_size='22pt', bold='true'), ['Project Proposal']),
                ]),
                L.divider(DividerAttr(thickness='xs')),
                L.text(TextAttr(font_size='13pt', bold='true'), ['Scope of Work']),
                L.flank(FlankAttr(gap='12pt', align='start'), [
                    L.text(TextAttr(color='#888888', width='24pt'), ['01']),
                    L.text(NoAttr, ['Discovery & Research']),
                ]),
            ]),
        ]),
    ]),
])

pdf = engine.render(doc)
```

## Requirements

- Python 3.8+
- [`wasmtime`](https://wasmtime.dev) CLI must be available in `PATH` (used to run the bundled WASI binary).

## Docs

[lpdf.io/docs/python](https://lpdf.io/docs/python)

--

Dual-licensed: Community License (free) and Commercial License (paid). See [LICENSE](LICENSE) for full terms.
