How to Set Up Your .well-known/ucp Manifest
A step-by-step guide to manually creating the UCP discovery file for your store (and why you probably shouldn't do it manually).
The heart of the Universal Commerce Protocol is a single JSON file.
Just like robots.txt tells a crawler what it can do, ucp.json tells an agent what it can buy.
You technically can create this file manually. Here is how (and why it's difficult).
The Manual Way (For Developers)
The file must live at https://yourdomain.com/.well-known/ucp and return a specific JSON structure:
{
"ucp_version": "1.0.0",
"meta": {
"name": "My Coffee Store",
"description": "Premium rigorous beans."
},
"endpoints": {
"search": "https://yourdomain.com/wp-json/ucp/v1/search",
"product": "https://yourdomain.com/wp-json/ucp/v1/product/{id}",
"cart": "https://yourdomain.com/wp-json/ucp/v1/cart"
}
}
The Problem with Manual Setup
While creating the file is easy, maintaining the endpoints is hard.
- Dynamic Inventory: If an agent queries your
/searchendpoint, you need to return real-time stock levels. A static JSON file can't do that. - CORS Headers: Your server MUST return
Access-Control-Allow-Origin: *. If you forget this, the AI agent (which runs on OpenAI's servers) will be blocked by your browser security policies. - Security: If you expose these endpoints manually, you are responsible for sanitizing every input. One SQL injection from a malicious bot could wipe your database.
The Automated Way (Recommended)
This is why we built UCP-Connect.
Instead of editing JSON files and configuring Nginx headers, you simply install the plugin. We handle:
- Auto-generation of
/.well-known/ucp - Real-time inventory syncing
- Security shielding against malicious agents
How to Check if it's Working
If you have installed the specific UCP-Connect plugin:
- Open your browser.
- Go to
yourstore.com/.well-known/ucp. - You should see the JSON output automatically.
Don't reinvent the protocol. Use the standard.