Skip to main content

Generate UCP-compliant servers for merchants from a simple schema

Project description

ucpify (Python)

Generate UCP-compliant (Universal Commerce Protocol) servers for merchants from a simple schema.

Installation

pip install -e .

Quick Start

# Initialize a sample merchant config
ucpify init

# Edit merchant-config.json to add your products, shipping, payments

# Start the UCP server
ucpify serve merchant-config.json

CLI Commands

# Create sample configuration
ucpify init --output my-store.json

# Validate configuration
ucpify validate my-store.json

# Start server
ucpify serve my-store.json --port 8080

Programmatic Usage

from ucpify import create_flask_app, MerchantConfig, Item, ShippingOption

config = MerchantConfig(
    name="My Store",
    domain="http://localhost:3000",
    currency="USD",
    items=[
        Item(id="prod_1", title="Widget", price=1999)
    ],
    shipping_options=[
        ShippingOption(id="standard", title="Standard", price=500)
    ]
)

app = create_flask_app(config)
app.run(port=3000)

License

MIT

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

ucpify-1.2.0.tar.gz (21.3 kB view details)

Uploaded Source

Built Distribution

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

ucpify-1.2.0-py3-none-any.whl (25.3 kB view details)

Uploaded Python 3

File details

Details for the file ucpify-1.2.0.tar.gz.

File metadata

  • Download URL: ucpify-1.2.0.tar.gz
  • Upload date:
  • Size: 21.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.2

File hashes

Hashes for ucpify-1.2.0.tar.gz
Algorithm Hash digest
SHA256 78d51130e1b7368feb37429271bce749262d326296a115159da0701ef7206f42
MD5 f777979e4348e4b06a6b3e12b102f883
BLAKE2b-256 badebe6966d77ae976fc8782a7235b8fe97cffec15c28718198b9dbb6afd5570

See more details on using hashes here.

File details

Details for the file ucpify-1.2.0-py3-none-any.whl.

File metadata

  • Download URL: ucpify-1.2.0-py3-none-any.whl
  • Upload date:
  • Size: 25.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.2

File hashes

Hashes for ucpify-1.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 a016467ec100aeef62f0a10f20e11e96f17a677b2951ed62b3e4b75b9ffc0c37
MD5 36db857c62d470fac9b1ebfae4c34f93
BLAKE2b-256 e6ac312a48e0dcd0ebeb391dd7f937edc3a8a174d7a0a3c8846ea5355f4fd5cc

See more details on using hashes here.

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