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.0.1.tar.gz
(16.4 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
ucpify-1.0.1-py3-none-any.whl
(20.2 kB
view details)
File details
Details for the file ucpify-1.0.1.tar.gz.
File metadata
- Download URL: ucpify-1.0.1.tar.gz
- Upload date:
- Size: 16.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.14.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
6fbe56056375255e7bcbbf6f784b4d52b6e654230e26c70d279c7f8bf0703453
|
|
| MD5 |
cb0b0996b37198d0fb73c8ba984bd499
|
|
| BLAKE2b-256 |
8bc61b161e6765de7cc93819d0b858a9465badc812660b4454242663159edff2
|
File details
Details for the file ucpify-1.0.1-py3-none-any.whl.
File metadata
- Download URL: ucpify-1.0.1-py3-none-any.whl
- Upload date:
- Size: 20.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.14.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
bfd0d8c0f56518b031020b1b10ff4b8c51c29edf0f4de77125509136e199aa46
|
|
| MD5 |
41d9bd1aedda1ddce6da17acd3a7d94f
|
|
| BLAKE2b-256 |
e4be5e8ac120e161f71624ba466b6a5d3f4c7e2c3dded7a4a60e95b34e970000
|