semvec/pypi-packages huggingface dataset:
ccs-digitalmarketplace-content-loader 13.17.0
Digital Marketplace Content Loader
Requires Python: <3.15,>=3.11

Digital Marketplace Content Loader
==================================

![Python 3.11](https://img.shields.io/badge/python-3.11-blue.svg)
![Python 3.12](https://img.shields.io/badge/python-3.12-blue.svg)
![Python 3.13](https://img.shields.io/badge/python-3.13-blue.svg)
![Python 3.14](https://img.shields.io/badge/python-3.14-blue.svg)
[![PyPI version](https://badge.fury.io/py/ccs-digitalmarketplace-content-loader.svg)](https://badge.fury.io/py/ccs-digitalmarketplace-content-loader)

## What's in here?

Content loader for Digital Marketplace.

Originally was part of [Digital Marketplace Utils](https://github.com/Crown-Commercial-Service/digitalmarketplace-utils).


## Running the tests

Install Python dependencies

```
make bootstrap
invoke requirements-dev
```

Run the tests

```
invoke test
```

## Releasing a new version

To update the package version, edit the `__version__ = ...` string in `dmcontent/__init__.py`,
once merged the new version will be released and published to [PyPI](https://pypi.org/project/digitalmarketplace-content-loader/) by [Github Actions](./.github/workflows).

When changing a major version number consider adding a record to the `CHANGELOG.md` with a
description of the change and an example of the upgrade process for the client apps.

## Pre-commit hooks

This project has a [pre-commit hook][pre-commit hook] to do some general file checks and check the `pyproject.toml`.
Follow the [Quick start][pre-commit quick start] to see how to set this up in your local checkout of this project.

## Licence

Unless stated otherwise, the codebase is released under [the MIT License][mit].
This covers both the codebase and any sample code in the documentation.

The documentation is [&copy; Crown copyright][copyright] and available under the terms
of the [Open Government 3.0][ogl] licence.

[mit]: LICENCE
[copyright]: http://www.nationalarchives.gov.uk/information-management/re-using-public-sector-information/uk-government-licensing-framework/crown-copyright/
[ogl]: http://www.nationalarchives.gov.uk/doc/open-government-licence/version/3/

[pre-commit hook]: https://pre-commit.com/
[pre-commit quick start]: https://pre-commit.com/#quick-start
ansiblelint-package-sort 0.2.0
Custom Ansible-lint rule which ensure package lists in package manager modules are sorted.
Requires Python: >=3.10

************************
ansiblelint-package-sort
************************

Ansible-lint rule for package list sorting.

This package provides a custom Ansible Lint rule that ensures package lists
in package manager modules are sorted alphabetically. The rule checks tasks
that use various package management modules and verifies that their package
lists are properly sorted.

The rule supports the following package manager modules:

* ansible.builtin.apt
* ansible.builtin.dnf
* ansible.builtin.dnf5
* ansible.builtin.package
* ansible.builtin.yum

License
#######
* Copyright 2026 M. Farzalipour Tabriz, Max Planck Institute for Physics (MPP)

All rights reserved.

This software may be modified and distributed under the terms of the GNU Lesser General Public License (LGPL). See the ``LICENSE`` file for details.
pincer-sdk 0.1.2
Pincer SDK for Python - Reference implementation for x402 protocol
Requires Python: >=3.11

# Pincer SDK for Python

**Simple, machine-native payments for the AI economy.**

The Pincer SDK is a lightweight wrapper for the **x402 protocol**, specifically designed to handle **Post-Pay Rebates** and sponsored access. It enables API providers (Sellers) to monetize their services while allowing sponsors (Merchants) to subsidize the cost for high-intent agents.

---

## 🚀 Quick Start

### Installation

```bash
pip install pincer-sdk
```

### 1. For Sellers: Protect your API

Sellers use Pincer to verify x402 payments and identify active sponsors using the built-in middleware.

```python
from src.pincer_sdk import PincerClient
from src.pincer_sdk.middleware import PincerPaymentMiddleware
from x402.server import x402ResourceServer

client = PincerClient(
    base_url="https://your-pincer-url.com",
    api_key="your_api_key"
)

# Initialize standard x402 server with Pincer facilitator
server = x402ResourceServer(client.facilitator())

# Add Pincer middleware to your FastAPI app
app.add_middleware(PincerPaymentMiddleware, routes=routes, server=server)

# Your FastAPI route
@app.get("/premium-data")
async def get_data(request: Request):
    # Payment is already verified here!
    # Sponsors are automatically injected into the request state
    payment = getattr(request.state, "payment", None)
    sponsors = getattr(payment, "sponsors", []) if payment else []

    return {
        "data": "Premium content",
        "applied_sponsors": sponsors
    }
```

### 2. For Merchants: Report Conversions

Merchants notify Pincer when a transaction occurs to trigger user rebates.

```python
from pincer_sdk import PincerClient

async with PincerClient(
    base_url="https://pincer.zeabur.app",  # URL is now required
    webhook_secret="your_secret"
) as pincer:
    await pincer.report_conversion(
        session_id="sess-123",
        user_address="0x...",
        purchase_amount=25.0,
        merchant_id="my-store"
    )
```

## 🏗 Why Pincer SDK?

The Pincer SDK enhances the base `x402` experience by:

- **Injecting Sponsorship Data**: Automatically capturing sponsor offers during the verification phase.
- **Simplifying Webhooks**: Providing signed conversion reporting for merchants out of the box.
- **Managing Identity**: Properly handling session IDs across the payment lifecycle.

## 📄 License

MIT