Xuda Marketplace API Reference
Xuda Marketplace API Reference
This reference covers the full method surface of Xuda Marketplace: the catalogue reads behind the public storefront, the buyer's install, purchase, retry and refund path, the seller's listing, publish and plan methods, the plugin publishing surface, and the two operator methods behind the review console. It is written for developers integrating with the Xuda plugin catalogue, and for anyone who needs to know exactly what each marketplace screen calls and what it does. Every method key, parameter name, type and required flag below is taken from the shipped method contract.
How To Call These Methods
Every method here is a CPI method. CPI methods are dispatched by name over the Xuda API and MCP layer, and the normal credential for that layer is the account API key. For the transport-level detail, including how requests are framed and how the MCP layer exposes methods, see /api-mcp-integration.
Read the availability line on each method before you write any code against it. The split for Marketplace is lopsided and you should know it up front:
- Six methods are reachable with a developer API key, and all six are plugin methods:
get_plugins,get_plugins_categories,get_app_plugins,install_plugin,uninstall_pluginandupload_plugin.get_pluginsandget_plugins_categoriesare additionally exposed over MCP. - Thirty-four methods are flagged private, which in this codebase means excluded from the API-key catalog and refused for API-key callers. They require a signed-in dashboard session, with the caller
uidinjected from that session. They are documented in full because they define the product's behavior, and because the marketplace catalogue itself is public even though the read method behind it is not key-reachable. - Two methods are operator methods surfaced only from the superuser review console.
Do not build against the private methods with an API key. They will be refused.
What The Availability Labels Mean
Every method below carries one explicit availability line. Read it first, because it tells you whether you can call the method from your own code today.
- Availability: API key means an external developer API key or the MCP layer can call it.
- Availability: Dashboard session means a signed-in user in the Xuda dashboard can call it, and an API key cannot. The account identity comes from the session, never from a parameter.
- Availability: Operator only means Xuda staff, listed here for completeness. Both operator methods are registered at admin clearance and are reached from the superuser route
/dashboard/admin/marketplace-review. No superuser check was found inside either method body, so the route gating is the practical restriction. - Availability: Public endpoint means no authentication at all. No Marketplace CPI method carries this label. The one unauthenticated surface the product has is the appeal form route, which is an HTTP route rather than a CPI method and is described under "Related Endpoints That Are Not CPI Methods".
Method Index
Catalogue and browsing
| Method | What It Does |
|---|---|
| marketplace_queries | The single read method behind the whole public catalogue: search, filter, sort, page and enrich. |
| get_marketplace_home_page | Assembles the marketplace home page from four popularity-sorted queries. |
| get_marketplace_listing_categories | Listing categories with their counts. |
| get_marketplace_ai_agent_categories | AI agent categories with their counts. |
| get_marketplace_ai_agent_subcategories | Subcategories under one AI agent category. |
| get_marketplace_ai_agent_industries | AI agent industries with their counts. |
Social layer
| Method | What It Does |
|---|---|
| marketplace_like | Records a like and increments the item's like counter. |
| marketplace_unlike | Removes this user's likes for an item and decrements the counter. |
| marketplace_follow | Follows a marketplace seller and increments their follower count. |
| marketplace_unfollow | Unfollows a seller and decrements their follower count. |
Install, purchase and provisioning
| Method | What It Does |
|---|---|
| install_marketplace_item | Installs a marketplace AI agent or component into the caller's workspace. |
| purchase_marketplace_listing | The buyer's checkout: a Stripe Connect charge plus a purchase record. |
| get_my_marketplace_purchases | The buyer's own purchase records and their setup state. |
| retry_marketplace_provision | Re-runs provisioning for a purchase whose setup failed. |
| cancel_refund_marketplace_purchase | Refunds and closes a purchase that was never delivered. |
| cancel_marketplace_purchase | Cancels a purchase without a refund. Registered on dev only. |
Seller plan
| Method | What It Does |
|---|---|
| get_marketplace_plan | Reads the account's seller tier, commission, allowance and slots used. |
| marketplace_set_plan | Switches the seller tier and moves the billing line for it. |
Listings
| Method | What It Does |
|---|---|
| get_account_marketplace_listings | Every listing this account owns, across all of its apps. |
| get_marketplace_listings | The listings belonging to one app. |
| create_marketplace_listing | Creates a listing for one app, at draft status. |
| update_marketplace_listing | Replaces a listing payload and sends it back to draft. |
| update_marketplace_listing_stat | The publish and pause control, and the entry point to the review gate. |
| delete_marketplace_listing | Soft-deletes a listing. |
| capture_vps_listing_image | Scrubs and freezes the disk image a Full Stack VPS listing sells. Dev only. |
| upload_component_screenshot | Saves the screenshot a component listing needs before it can go live. |
| update_app_marketplace | Saves app-level marketplace category and tags. Legacy. |
Plugins
| Method | What It Does |
|---|---|
| get_plugins | The public plugin catalogue, enriched with publisher and install counts. |
| get_plugins_categories | Plugin type facets with their counts. |
| get_app_plugins | Every plugin available to one application. |
| install_plugin | Installs a plugin into an application. |
| uninstall_plugin | Uninstalls a plugin from an application. |
| upload_plugin | Creates or updates a plugin record from an npm package or a hosted artifact. |
| publish_plugin | The owner-initiated marketplace visibility toggle for a plugin. |
| save_plugin_setup | Saves a plugin's per-app configuration. |
| get_plugin_setup | Reads a plugin's stored setup for one app. |
| get_plugin_files | Reads a plugin's file tree and dependency tree for one app. |
| archive_plugin | Archives a plugin owned by the calling account. |
| test_connection | Tests a database plugin's connection settings. |
Operator and dead registrations
| Method | What It Does |
|---|---|
| get_marketplace_review_queue | Lists the items awaiting a human decision. |
| marketplace_operator_decision | Approves or rejects one queued item. |
| query_items | Registered in config with no implementation anywhere. Do not call it. |
marketplace_queries
Marketplace Queries
The single read method behind the whole public catalogue. It runs search, filter, sort and paging across every marketplace document type, and enriches each row with the publisher's name, username and profile picture, whether the viewer has liked it, and for AI agents whether the viewer already has it installed. Passing _id returns one enriched document and records a view. Passing username without a docType returns that user's items across listings, components, projects, plugins and agents in one call. Rows whose owner is suspended or on a billing hold are dropped, and a paid item whose seller is no longer a valid seller is dropped. Only documents at stat === 3 are visible. Response caching is disabled (cache_control: no-store).
Availability: Dashboard session
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
docType |
string | No | One of marketplace_component, marketplace_project, marketplace_user, marketplace_listing, marketplace_plugin, marketplace_ai_agent, followers, following, liked, categories, all. Defaults to all. |
_id |
string | No | Fetch a single item by id and record a view. A value containing plugin is resolved against the plugin catalogue instead. |
search_string |
string | No | Case-insensitive regex match over name, description and tags (or listing name, description and keywords). |
sort_type |
string | No | trending (by views), recent (by date) or popular (by likes). Defaults to popular. |
pricing |
string | No | free (price equals 0) or paid (price greater than 0). Listings only. |
category |
string | No | Category filter. For plugins this maps to plugin_type. |
ui_engine |
array | No | Restricts components and agents to the listed UI frameworks. |
username |
string | No | Resolves a public username to a seller and scopes the query to them. |
user_id |
string | No | Scopes the query to one account id. |
app_id |
string | No | With prog_id, addresses one component or agent. |
prog_id |
string | No | With app_id, addresses one component or agent. |
listing_id |
string | No | With app_id, addresses one listing and records a view. |
limit |
number | No | Page size. Defaults to 99999. |
skip |
number | No | Rows to skip. Coerced to a number. |
uid |
string | No | Viewer account id, supplied by the session; drives the liked and installed flags. |
Notes
- Clearance is public but the method is flagged private, so it is a dashboard-session method. There is no
min_plangate. - Visibility is absolute: only documents at
stat === 3are ever returned, which is how anything unapproved, paused, drafted or rejected stays off the public shelf. - Views are deduped. A view is recorded once per viewer per item through a
marketplace_viewdocument, so repeated opens by the same account do not inflate the count. - Known gaps:
from_dashboardis accepted and never used, and thesubcategoryandindustryfilters the website sends for AI agents are not read by this method. Do not depend on either.
get_marketplace_home_page
Get Marketplace Home Page
One call that assembles the marketplace home page by running four marketplace_queries in sequence, each sorted by popularity and limited to 10 rows: AI agents, marketplace users (pros), components and listings.
Availability: Dashboard session
Parameters
This method takes no parameters.
Notes
- Cached for 600 seconds, so a newly published item can take up to ten minutes to appear on the home page even though it is already live.
- No
min_plangate.
get_marketplace_listing_categories
Get Marketplace Listing Categories
Returns marketplace listing categories with their counts, from the listing_categories_count reduce view at group_level: 1. This is the source for the category dropdown on the listing browse pages.
Availability: Dashboard session
Parameters
This method takes no parameters.
Notes
- Cached for 600 seconds.
- No
min_plangate.
get_marketplace_ai_agent_categories
Get Marketplace AI Agent Categories
Returns AI agent categories with their counts, from the marketplace_ai_agent_category_count reduce view at group_level: 1.
Availability: Dashboard session
Parameters
This method takes no parameters.
Notes
- Cached for 600 seconds.
- No
min_plangate.
get_marketplace_ai_agent_subcategories
Get Marketplace AI Agent Subcategories
Returns the subcategories with their counts under one parent AI agent category, read from the marketplace_ai_agent_subcategory_count view over the key range [agent_category, ''] to [agent_category, 'zzzzzzz'].
Availability: Dashboard session
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
agent_category |
string | Yes | Parent AI agent category to list subcategories for. |
Notes
- Cached for 600 seconds.
- No
min_plangate. - The subcategory facet can be read here, but
marketplace_queriesdoes not read asubcategoryfilter, so you cannot currently narrow a catalogue query by it.
get_marketplace_ai_agent_industries
Get Marketplace AI Agent Industries
Returns AI agent industries with their counts, from the marketplace_ai_agent_industry_count reduce view at group_level: 1.
Availability: Dashboard session
Parameters
This method takes no parameters.
Notes
- Cached for 600 seconds.
- No
min_plangate. - As with subcategories,
marketplace_queriesdoes not read anindustryfilter.
marketplace_like
Marketplace Like
Records a like from the calling user on a marketplace item and increments the item's like counter. Existence is resolved by selector over {docType: 'marketplace_like', uid} using the idx_marketplace_like_user index rather than a computed document id, so a previously deleted like can be re-created; the new like document gets a fresh random id. The find cache is busted before and after the write so the likes list and the hearts update immediately.
Availability: Dashboard session
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
_id |
string | Yes | The marketplace item id being liked. |
Notes
- Clearance is user, and the method is flagged private. No
min_plangate. - Not idempotent: a second like from the same user returns
-400with the messagealready liked. - Broadcast, so the write propagates across servers.
- The method's parameters are read from the request in code;
config.jsondeclares nofieldsentry for it.
marketplace_unlike
Marketplace Unlike
Removes every like document this user holds for the item, matching both the current like_id scheme and the legacy like_app_id plus like_prog_id scheme, then decrements the item's like count by however many were removed, never below zero.
Availability: Dashboard session
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
_id |
string | Yes | The marketplace item id being unliked. |
Notes
- Clearance is user. No
min_plangate. - Idempotent: it reports success whether or not a like was present.
- Broadcast.
marketplace_follow
Marketplace Follow
Creates a follow relationship from the calling user to another marketplace user, stored at the deterministic id <uid>_<follow_uid>_marketplace_follow, and increments the followed user's followers_count.
Availability: Dashboard session
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
follow_uid |
string | Yes | UID of the marketplace user to follow. |
Notes
- Clearance is user. No
min_plangate. - The deterministic document id makes a repeat follow safe to attempt, but it is reported rather than silently absorbed: an existing relationship returns
-400with the messagealready followed. followers_countis denormalized onto themarketplace_userdocument, which is what the public profile reads.
marketplace_unfollow
Marketplace Unfollow
Deletes the follow document and decrements the followed user's followers_count, never below zero.
Availability: Dashboard session
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
follow_uid |
string | Yes | UID of the marketplace user to unfollow. |
Notes
- Clearance is user. No
min_plangate. - Broadcast.
install_marketplace_item
Install Marketplace Item
Installs a marketplace AI agent or component into the caller's workspace. An AI agent must be live (stat 3) and its agent_visibility must be public; it is copied into the caller's default project with studio_meta recording the source project, source owner, installing user and marketplace id. A component is installed into the project named by project_id, or the caller's default project when none is given: the method resolves the component's full dependency graph (programs, tables, the project globals doc and required plugins), refuses the install with a named message when the target project is missing a required plugin, creates a "database" folder and a "programs" folder named after the item, and writes every document in.
Availability: Dashboard session
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
marketplace_id |
string | Yes | ID of the marketplace document to install. |
project_id |
string | No | Target project for a component install. Defaults to the caller's default project. |
Notes
- Clearance is user. No
min_plangate. - Reinstalling over a soft-deleted (
stat 4) copy is allowed. Reinstalling over a live copy returnsapp already installed. - A component install fails with a named error when the component needs a plugin the target project does not have. Install that plugin first, then retry.
- Broadcast.
- This is the free install path. It does not take payment and it is not the route for a paid listing; use
purchase_marketplace_listingfor that.
purchase_marketplace_listing
Purchase Marketplace Listing
The buyer's checkout. It requires the listing to exist and be live (stat 3), refuses a self-purchase, refuses a second purchase of a listing the buyer already owns, requires the seller to have a Stripe Connect account id and the buyer to have a Stripe customer with a card on file, and refuses an amount under the Stripe minimum of 50 cents. The platform cut is read from the seller's marketplace plan and defaults to 20 percent. A recurring listing creates a Stripe product plus a monthly subscription with application_fee_percent and transfer_data.destination set to the seller's connected account; a one-time listing is a single destination charge with application_fee_amount. A marketplace_purchase document is then written with the amount, price type, applied commission, charge and subscription ids, receipt URL, stat: 3 and provision_stat: 'pending', the listing's sales counter is incremented, and provisioning is dispatched asynchronously.
Availability: Dashboard session
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
listing_id |
string | Yes | The live marketplace listing to buy. |
Notes
- Clearance is user. No
min_plangate. Runs on thestripe_modulemicroservice. - One purchase per buyer per listing. A repeat call for a listing already owned is refused, which is what makes the checkout safe to retry.
- A subscription is created with
payment_behavior: 'error_if_incomplete', so a declined card fails loudly instead of leaving a half-open subscription. - The applied
commission_percentis recorded on the purchase document, so a later refund or report reads the rate that was actually charged rather than today's plan. - Provisioning is asynchronous and can fail. The purchase is real the moment the charge succeeds; watch
provision_staton the purchase record for the setup outcome. - Only
projectandmanaged_vpslistings have a provisioner. A purchase of a listing type nothing knows how to provision is marked failed with the messagenothing knows how to provision a "<type>" listing yet. - Payment never happens on the public marketing site. The website Purchase button sends a signed-in buyer to
/dashboard/marketplace/buy/<listing_id>, and a signed-out visitor to login first.
get_my_marketplace_purchases
Get My Marketplace Purchases
Returns the calling buyer's own marketplace purchase records, excluding cancelled ones (stat not equal to 4), up to 999 rows. This is the data behind the Billing "Marketplace purchases" card and behind the checkout screen's "you already own this" check.
Availability: Dashboard session
Parameters
This method takes no parameters. It is scoped to the session's uid.
Notes
- Clearance is user. No
min_plangate. Runs on thestripe_modulemicroservice. - Each row carries
provision_stat(pending,provisioning,doneorfailed),provision_attempts,provision_error,provisioned_refandprovisioned_kind, which is how a client renders the setup state and links to what was created. - The billing card polls this method every 5 seconds while a purchase is still setting up.
retry_marketplace_provision
Retry Marketplace Provision
Lets the buyer re-run provisioning for a purchase whose setup failed. It is guarded to the owning buyer, returns immediately when the purchase is already provisioned, and refuses once provision_attempts has reached the maximum of 3. The provision is dispatched in the background rather than awaited, because a project clone copies the database, studio documents and disk assets and runs npm install.
Availability: Dashboard session
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
purchase_id |
string | Yes | The marketplace purchase to retry provisioning for. |
Notes
- Clearance is user. No
min_plangate. - Three attempts is the hard ceiling. The fourth call is refused with "this purchase has used all of its automatic retries, contact support, or cancel it for a refund".
- Safe to call on an already-provisioned purchase: it returns without doing anything.
- The call returns as soon as the job is dispatched. Poll
get_my_marketplace_purchasesfor the outcome. A project clone waits up to 10 minutes and a VPS restore up to 30 minutes internally. - There is no automatic refund on a failed provision, by design. The retries come first.
cancel_refund_marketplace_purchase
Cancel + Refund Marketplace Purchase
The only refund route, and only for a purchase that was never delivered. It is guarded to the owning buyer, refuses when provision_stat is done, and otherwise issues a Stripe refund with reverse_transfer: true and refund_application_fee: true so the seller's share and the platform fee are both clawed back, cancels any subscription, and closes the record at stat 4.
Availability: Dashboard session
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
purchase_id |
string | Yes | The marketplace purchase to refund and close. |
Notes
- Clearance is user. No
min_plangate. Runs on thestripe_modulemicroservice. - A working purchase cannot be refunded here. It answers "this purchase is set up and running, delete what it created to stop billing".
- Billing for a healthy recurring purchase ends by deleting the provisioned resource. Deleting it cancels the underlying subscription through the internal
cancel_purchase_for_provisioned_refpath.
cancel_marketplace_purchase
Cancel Marketplace Purchase
Buyer-initiated cancel: cancels the underlying Stripe subscription when the listing was recurring and marks the purchase record stat 4 so it drops out of the Purchased view and a re-purchase becomes possible. No refund is issued.
Availability: Dashboard session
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
purchase_id |
string | Yes | The marketplace purchase to cancel. |
Notes
- Registered in
config_dev.jsononly, withdev_only: true. It is not present in the production config, so it is not callable on production today. - Clearance is user. No
min_plangate. Runs on thestripe_modulemicroservice. - On production the only exits from a purchase are deleting the provisioned resource, or the exhausted-retries refund through
cancel_refund_marketplace_purchase.
get_marketplace_plan
Get Marketplace Plan
Read-only summary of the account's Marketplace seller tier for the listings screen: the plan id and name, its monthly price, whether a tier was ever explicitly picked (activated), whether the account is an eligible seller (is_seller), the commission percentage, the listing types the tier can sell, how many listings currently occupy a slot, the tier's allowance (null when unlimited) and how many slots remain.
Availability: Dashboard session
Parameters
This method takes no parameters. It is scoped to the session's uid.
Notes
- Clearance is user. No
min_plangate. - An account that never picked a tier is treated as
marketplace_free. - Only a listing that is live, or submitted and waiting on review, occupies a slot. Drafts, paused listings and rejected listings cost nothing.
marketplace_set_plan
Marketplace Set Plan
Switches the account's seller tier. A move down is refused while it would strand listings, naming both numbers. A paid tier attaches or reprices one line item on the consolidated subscription through add_subscription_item; moving back to Free removes that line through remove_subscription_item rather than repricing it to zero. deactivate: true moves the account back to Free and deletes the marketplace_plan field entirely, so the module switch reads as off. Returns the same shape as get_marketplace_plan.
Availability: Dashboard session
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
plan_id |
string | Yes | marketplace_free, marketplace_starter, marketplace_growth or marketplace_scale. |
deactivate |
boolean | No | When true, ignores plan_id, moves to Free and unsets the stored plan. |
Notes
- Clearance is user. No
min_plangate. - A downgrade that would leave more listings on sale than the target tier allows is refused with a sentence naming the numbers, for example "You have 7 listings on sale and the Starter plan includes 5. Pause 2 first."
- One consolidated subscription line per account, not one per listing. Moving between paid tiers reprices the existing line rather than adding a second charge.
- The tier is not applied retroactively to listings already on sale. It refuses the next publish instead of taking anything down.
- In the production config as committed, the three paid tiers carry placeholder Stripe price ids, so a move to a paid tier on production may not be purchasable. See "The Seller Plan Ladder" below.
get_account_marketplace_listings
Get Account Marketplace Listings
Returns every listing this account owns across all of its apps and every status except deleted (stat not equal to 4), projecting the app id, owner, created and updated timestamps, status, status reason, publish status, the listing payload, views and likes, and best-effort enriching each row with the owning app's name. This is the data source for the standalone Marketplace management screen and for loading a listing into the edit form.
Availability: Dashboard session
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
limit |
number | No | Maximum rows. Defaults to 999. |
skip |
number | No | Rows to skip. |
Notes
- Clearance is user. No
min_plangate. - This is the seller's own view, so it returns drafts, paused, under-review and rejected listings, unlike
marketplace_querieswhich only ever returns live documents.
get_marketplace_listings
Get Marketplace Listings
Returns the listings belonging to one app, optionally narrowed to a single listing id, projecting app id, created date, status, the listing payload, the document id, the updated timestamp and the status reason. Per-app counterpart to get_account_marketplace_listings.
Availability: Dashboard session
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
app_id |
string | Yes | ID of the app whose listings are retrieved. |
listing_id |
string | No | Narrows the result to one listing. |
limit |
number | No | Maximum rows. Defaults to 999. |
skip |
number | No | Rows to skip. |
Notes
- Clearance is admin, and the method is flagged private. No
min_plangate.
create_marketplace_listing
Create Marketplace Listing
Creates a listing for one app. In order: it loads the app and its owner, refuses unless the owner is marketplace pro, refuses a listing type the seller's tier cannot sell (naming the cheapest tier that can and its price), runs the Xuda Verify seller_account gate, mints a deterministic listing id from the app id plus the listing name, and validates the payload. The listing is created at stat 2 (draft, not yet submitted). A managed_vps listing additionally turns on the backup access opt-in on the source server, because the seller's image-disclosure acknowledgement is that consent and the capture needs node-level access.
Availability: Dashboard session
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
app_id |
string | Yes | ID of the app the listing is created for. |
data |
object | Yes | Listing payload. |
data.listing_name |
string | Yes | Display name, 5 to 50 characters. |
data.listing_description |
string | Yes | Rich-text description, 500 to 3000 characters. |
data.listing_keywords |
array | Yes | At least 3 keywords. |
data.listing_category |
string | Yes | Listing category. |
data.listing_images |
array | Yes | At least one image. |
data.live_preview_link |
string | Yes | URL of a live, interactive preview. |
data.listing_price |
number | Yes | 5 to 100000. |
data.listing_price_type |
string | No | monthly (default) or one_time. |
data.listing_type |
string | No | project (default), ai_agent, instance or managed_vps. |
data.vps_image_acknowledged |
boolean | Conditional | Required when listing_type is managed_vps; the save is refused without it. |
data.vps_image_cleanup |
array | No | Cleanup action ids to run before the image capture. |
data.vps_region |
string | No | Region the seller built and tested the image in. |
data.vps_server_type |
string | No | Server slug the seller built the image on. |
Notes
- Clearance is admin, and the method is flagged private. Plan gate:
min_plan: agency, so an Agency membership is required in addition to whichever marketplace seller tier the account is on. - Seller eligibility gate: the owner must be marketplace pro, meaning
finance_activeis true, or the Stripe Connect account status isactive, or the account is a Xuda network ambassador. Without it the call returns "marketplace pro required: approved seller account or xuda ambassador". - Tier gate: the seller's marketplace tier decides which
listing_typevalues it may sell. Free and Starter cannot sellmanaged_vpsat all. - The listing id is derived from the app id plus the listing name, so re-creating a listing with the same name on the same app addresses the same document rather than making a second one.
- Validation is enforced server side, not just in the form: 3 or more keywords, a category, a live preview link, a description of 500 to 3000 characters, a name of 5 to 50 characters, a price between 5 and 100000, and at least one image.
- Creation never publishes. The listing lands at
stat 2and onlyupdate_marketplace_listing_statsubmits it for review. - Of the four listing types, only
projectis selectable in the shipped create UI.managed_vps,ai_agentandinstancerender as "Coming soon". - The Xuda Verify
seller_accountgate inside this method is inert today: its call throws and is swallowed by the surrounding handler, which logs "verify gate unavailable, allowing" and proceeds. - Broadcast.
update_marketplace_listing
Update Marketplace Listing
Replaces the listing's data payload, re-runs the same validation, resets the listing to stat 2 with stat_reason: 'Listing updated', and stamps the update timestamp. An edited listing therefore leaves the live shelf and must be published again.
Availability: Dashboard session
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
listing_id |
string | Yes | ID of the marketplace listing to update. |
data |
object | Yes | The full updated listing payload, same shape and same validation as on create. |
Notes
- Clearance is admin, and the method is flagged private. Plan gate:
min_plan: agency. datais a full replacement, not a patch. Send the complete payload every time, with the same fields and the same validation ascreate_marketplace_listing.- Editing always unpublishes. Expect to call
update_marketplace_listing_statwithstat: 1afterwards, and expect that publish to go through the review gate again. - Broadcast.
update_marketplace_listing_stat
Update Marketplace Listing Stat
The publish and pause control. stat 1 is a publish request: it re-checks marketplace pro, enforces the tier's live-listing cap over every listing except this one (so re-publishing an already-live listing is never refused by its own slot), runs the Managed VPS image gate when the listing type is managed_vps, then runs the AI publish gate. The gate decides the outcome, so a publish request can land on live (3), under review (2 with publish_stat 1) or rejected (6). stat 2 pauses the listing and stat 4 takes it down, both without a gate. Any other value returns "stat not supported".
Availability: Dashboard session
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
listing_id |
string | Yes | ID of the marketplace listing whose status is changed. |
stat |
number | Yes | 1 to request publish, 2 to pause, 4 to unpublish. |
Notes
- Clearance is admin, and the method is flagged private. Plan gate:
min_plan: agency. - A publish request is a request, not a state change. Read
publish_staton the returned listing to find out where it landed: 1 pending review, 2 under review after an appeal, 3 published, 6 rejected.statmirrors the same outcome so thestat === 3visibility filters keep hiding anything unapproved. - The tier's live-listing cap is enforced here, over every other listing that is live or awaiting review. Pausing another listing frees a slot immediately.
- A
managed_vpspublish is refused when the listing's disk image does not exist or is not restorable. The check reads the backup document's status, its PBSvolid, and whether the source server still exists, because each of those would otherwise charge a buyer and then fail. - The publish gate is short-circuited by a content hash, so an unchanged, already-approved item is not re-reviewed on every save.
- If the AI reviewer is unreachable, the item fails safe to manual review, never to published.
- Pausing and unpublishing are always allowed and never touch the gate.
delete_marketplace_listing
Delete Marketplace Listing
Soft-deletes a listing by loading it and setting stat to 4. The document is retained.
Availability: Dashboard session
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
listing_id |
string | Yes | ID of the marketplace listing to delete. |
Notes
- Clearance is admin, and the method is flagged private. No
min_plangate, unlike create, update and publish. - The delete is soft. The document stays in
xuda_marketplaceatstat 4, out of the public catalogue and out ofget_account_marketplace_listings. - Deleting a listing does not cancel purchases already made from it.
- Broadcast.
capture_vps_listing_image
Capture VPS Listing Image
Scrubs the seller's farm VPS and freezes it into the PBS archive that a Full Stack VPS listing sells. It requires ownership of both the listing and the server, requires the listing to be of type managed_vps, requires the server to be a Proxmox farm VPS with a vmid and to be active, then scrubs first (app_module.prepare_vps_image with for_marketplace: true, which forces the buyer-safety cleanups on server side) and captures second, because the image is a byte-for-byte copy and anything the scrub misses ships to every buyer permanently. It waits for the backup to reach a terminal state with a real archive handle, then stamps vps_image_backup_id, the capture timestamp and the source region and server slug onto the listing.
Availability: Dashboard session
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
app_id |
string | Yes | The farm VPS to image. Must belong to the calling user and be active. |
listing_id |
string | Yes | The managed_vps listing to attach the captured image to. Must belong to the calling user. |
cleanup_actions |
array | No | Optional cleanup action ids; the buyer-safety ones are forced on server-side regardless. |
Notes
- Registered in
config_dev.jsononly, withdev_only: true. It is not registered on production, so the Full Stack VPS sell flow dead-ends after the secret scan there, and the create UI marks that listing type "Coming soon" for exactly this reason. - Clearance is user, and the method is flagged private. Plan gate:
min_plan: agency. - It runs as a job with a 3,900,000 ms timeout and waits up to 60 minutes for the backup to become restorable. Progress is reported as "Capturing server image", "Server image captured" or "Server image capture failed".
- The scrub always runs before the capture, and the buyer-safety cleanups are forced server side whatever you pass in
cleanup_actions. - The seller must already have acknowledged the itemized image disclosure on the listing, because
data.vps_image_acknowledgedis required to save amanaged_vpslisting at all.
upload_component_screenshot
Upload Component Screenshot
Saves a base64 screenshot for a marketplace component into the project's studio Screenshots folder (creating that system folder if needed) under the filename marketplace_item_<app_id>_<prog_id>.jpg, and registers a public studio_drive document for it. The presence of this file is what allows a component's marketplace record to reach the live state.
Availability: Dashboard session
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
data |
string | Yes | Base64-encoded screenshot image string. |
prog_id |
string | Yes | ID of the component program the screenshot belongs to. |
app_id |
string | Yes | ID of the app the component belongs to. |
Notes
- Clearance is developer, and the method is flagged private. No
min_plangate. - A component without this screenshot cannot reach the live state, so this call is a prerequisite for a component appearing in the catalogue.
update_app_marketplace
Update App Marketplace
Saves the app-level marketplace metadata (app_category and app_tags) onto the app's master document under app_marketplace. It refuses a payload missing a category, missing tags, or carrying an empty tag list.
Availability: Dashboard session
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
app_id |
string | Yes | ID of the app whose marketplace metadata is being updated. |
data |
object | Yes | The metadata payload. |
data.app_category |
string | Yes | The app's marketplace category. |
data.app_tags |
array | Yes | At least one tag. |
Notes
- Clearance is admin, and the method is flagged private. No
min_plangate. - An empty tag list is refused with "Error - Must contain at least 1 tag".
- Treat this as legacy. Its only caller is a per-project marketplace tab that no dashboard route references.
- Broadcast, and security flagged.
get_plugins
Get Plugins
Returns the public plugin catalogue from the xuda_plugins all-plugins view. Only plugins at stat === 3 whose visibility is not private are returned to a caller other than their owner; an owner passing their own uid also sees their private and unapproved plugins. Each row is stripped of account_id, manifest, plugin_name, setup and stat, enriched with the publisher's marketplace user info (name, username, profile picture) and with an installs count read from the xuda_master plugins_installed reduce view, and its _id has the @xuda.io/ scope prefix removed.
Availability: API key
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
plugin_id |
string | No | Exact plugin id to fetch (used as the view key). |
id |
string | No | Unscoped plugin id; matched against @xuda.io/<id>. |
limit |
number | No | Maximum rows to return. Defaults to 9999. |
skip |
number | No | Rows to skip, for paging. Defaults to 0. |
category |
string | No | Filters on the plugin's plugin_type. |
tags |
array | No | Filters on the plugin's tags. |
stat |
number | No | Filters on the plugin lifecycle status. |
uid |
string | No | The caller's account id; lets an owner see their own non-public plugins. |
Notes
- Clearance is public and no
privateflag is set, so an API key can call it. Nomin_plangate. - Exposed over MCP.
- Cached for 600 seconds.
- The returned
_idis unscoped. Add the@xuda.io/prefix back when you pass a plugin name toinstall_plugin,publish_pluginor the other per-plugin methods. config.jsondeclares nofieldsentry for this method; the parameters above are the ones the implementation reads.
get_plugins_categories
Get Plugins Categories
Returns the plugin type facets with their counts, from the xuda_plugins plugins-by-plugin_type reduce view at group_level: 1. This is what builds the plugin category dropdown on the public marketplace.
Availability: API key
Parameters
This method takes no parameters.
Notes
- Clearance is public and no
privateflag is set, so an API key can call it. Nomin_plangate. - Exposed over MCP.
- Cached for 600 seconds.
get_app_plugins
Get App Plugins
Returns every plugin available to one application, walking the all-plugins view and skipping any plugin that belongs to another account and is either not approved (stat < 3) or explicitly private. Each returned plugin is annotated with has_depended_setup, which is true when the plugin declares a dependent_plugin_id, that dependency is installed on the app, and the dependency's own authorized_plugins list names this plugin.
Availability: API key
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
app_id |
string | Yes | Unique identifier of the application this request targets. |
plugin_type_filter |
string | No | Restricts the result to a single plugin type. |
uid |
string | No | Caller account id, used to decide which non-public plugins are visible. |
Notes
- Clearance is admin and no
privateflag is set, so an API key with admin clearance can call it. Nomin_plangate. has_depended_setupis the flag to read before callinginstall_pluginwithoutbypass_validation, because the install refuses a plugin whose declared dependency is not installed and authorized.
install_plugin
Install Plugin
Installs the named plugin into the given application: validates the plugin exists, refuses a paid plugin when validate_free is set, checks that any declared dependency is installed and has authorized this plugin, records the plugin under app_plugins_purchased on the app document (self-healing a legacy array shape into an object), marks the app as needing an update, runs the npm install into the app's plugin directory, and finally writes the plugin document plus its file tree into the app database.
Availability: API key
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
app_id |
string | Yes | Unique identifier of the application this request targets. |
plugin_name |
string | Yes | Name of the plugin to install. |
bypass_validation |
boolean | No | Skips the dependency installed/authorized checks. |
validate_free |
boolean | No | When true, refuses to install a plugin that carries a price. |
Notes
- Clearance is admin and no
privateflag is set, so an API key can call it. Nomin_plangate. - Broadcast, and location sensitive, so it runs on the app's own server.
- It runs a real npm install into the app's plugin directory. Expect it to take meaningfully longer than a document write.
validate_free: trueis the guard to use when you are installing on someone else's behalf and must not incur a plugin price.
uninstall_plugin
Uninstall Plugin
Uninstalls the named plugin from the given application.
Availability: API key
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
app_id |
string | Yes | Unique identifier of the application this request targets. |
plugin_name |
string | Yes | Name of the plugin to process. |
Notes
- Clearance is admin and no
privateflag is set, so an API key can call it. Nomin_plangate. - Broadcast, and location sensitive.
upload_plugin
Upload Plugin
Creates or updates a plugin record in xuda_plugins from an npm package or a Xuda-hosted artifact. It validates plugin_type against the allowed set (dbs, widget, graphics, library, platform, framework, util, ui), normalizes the tags, derives a human label from the package name, reads the npm manifest for the version and icon when the source is npm, installs the package, and validates it. If the upload is marked private or skip_publish_review is set, the plugin's marketplace lifecycle and visibility are carried forward unchanged and the review gate never runs; otherwise a non-trusted publisher's upload is put through the marketplace review gate and lands at publish_stat 3 (live), 6 (rejected) or 1 (under review). A trusted first-party publisher publishes straight to stat 3, public.
Availability: API key
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
app_id |
string | Yes | Unique identifier of the application this request targets. |
plugin_name |
string | Yes | The plugin package name. |
data.plugin_name |
string | Yes | The plugin package name inside the payload. |
data.plugin_type |
string | Yes | One of dbs, widget, graphics, library, platform, framework, util, ui. |
data.package_source |
string | No | npm (default) or xuda_hosted. |
data.package_url |
string | No | Required when package_source is xuda_hosted. |
data.visibility |
string | No | private keeps the plugin out of the marketplace and skips the review gate. |
data.skip_publish_review |
boolean | No | Same effect as a private upload: no review, no visibility change. |
data.plugin_description |
string | No | Description used on the marketplace listing and sent to the review gate. |
data.tags |
array or string | No | Tags, accepted as an array or a comma-separated string. |
data.price |
number | No | Plugin price, passed to the review gate. |
data.account_id |
string | No | Owner account; an update is refused when it does not match the stored owner. |
Notes
- The
privateflag is explicitlyfalse, so an API key can call it. Clearance is admin. Plan gate:min_plan: agency. - An update is refused when
data.account_iddoes not match the stored owner, so you cannot overwrite someone else's plugin record. - A private upload, or
skip_publish_review: true, carries the existing marketplace lifecycle and visibility forward untouched. Use that path for iterating on a plugin without re-entering review. - Code and npm version updates never change marketplace visibility on their own. Publishing is always a separate explicit action through
publish_plugin. - In
config.jsonthis entry declares its parameters at the top level of the method object rather than inside afieldsobject, unlike every other method here. The names above are the ones the implementation reads.
publish_plugin
Publish Plugin
The explicit, owner-initiated marketplace toggle for a plugin, deliberately decoupled from code and npm updates. visibility: 'private' unpublishes: the plugin stays usable by its owner at publish_stat 0, stat 2. visibility: 'public' first requires an active Stripe Connect seller account, and otherwise runs the marketplace review gate and lands at publish_stat 3 (live and public), 6 (rejected, back to private) or 1 (under review, private). A trusted first-party publisher bypasses the gate. Returns { publish_stat, visibility, publish_reason }.
Availability: Dashboard session
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
app_id |
string | Yes | Unique identifier of the application this request targets. |
plugin_name |
string | Yes | Scoped package name of the plugin to publish or unpublish. |
visibility |
string | Yes | public submits the plugin to marketplace review; private unpublishes it. |
Notes
- Clearance is user, and the method is flagged private. No
min_plangate. - Publishing without an active Stripe Connect seller account returns
-403with "A seller account is required to publish to the marketplace. Please set up your seller account first." - If the gate itself is unavailable the plugin fails safe to private and under review, never to public.
- Unpublishing is always allowed and never touches the gate. The plugin stays private and usable by its owner.
- Location sensitive.
- A plugin held at
publish_stat1 lives inxuda_pluginsand does not appear inget_marketplace_review_queue, which readsxuda_marketplaceonly.marketplace_operator_decisioncan still act on it by passingdb_name: 'xuda_plugins'.
save_plugin_setup
Save Plugin Setup
Saves a plugin's per-app setup object, its configuration, onto the plugin document inside the app database.
Availability: Dashboard session
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
app_id |
string | Yes | Unique identifier of the application this request targets. |
plugin_name |
string | Yes | Name of the plugin to process. |
data |
object | Yes | The setup payload to store. |
Notes
- Clearance is admin, and the method is flagged private. No
min_plangate. - Broadcast, and location sensitive.
get_plugin_setup
Get Plugin Setup
Returns a plugin's stored setup for one app, or the full plugin document when full_obj is set.
Availability: Dashboard session
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
app_id |
string | Yes | Unique identifier of the application this request targets. |
plugin_name |
string | Yes | Name of the plugin to process. |
full_obj |
boolean | No | Return the whole plugin document instead of just its setup. |
Notes
- Clearance is admin, and the method is flagged private. No
min_plangate. - A plugin that has never been set up on that app answers
code 2with an empty object rather than an error. Treat that as "not configured yet", not as a failure.
get_plugin_files
Get Plugin Files
Returns the plugin's file tree and dependency tree for one app, resolved from the app's plugin directory on disk.
Availability: Dashboard session
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
app_id |
string | Yes | Unique identifier of the application this request targets. |
plugin_name |
string | Yes | Name of the plugin to process. |
plugin_type |
string | No | Plugin type, used when resolving the tree. |
Notes
- Clearance is admin, and the method is flagged private. No
min_plangate.
archive_plugin
Archive Plugin
Archives a plugin by setting its stat to 4, refusing when the plugin does not belong to the calling account.
Availability: Dashboard session
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
app_id |
string | Yes | Unique identifier of the application this request targets. |
plugin_name |
string | Yes | Name of the plugin to process. |
Notes
- Clearance is admin, and the method is flagged private. No
min_plangate. - Ownership is enforced: a plugin belonging to another account is refused.
- Location sensitive.
test_connection
Test Connection
Tests a database plugin's connection using the supplied connection settings, resolving the plugin's dbs info for the app and running a live connection test against it.
Availability: Dashboard session
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
app_id |
string | Yes | Unique identifier of the application this request targets. |
plugin_name |
string | Yes | Name of the plugin whose connection is being tested. |
data |
object | Yes | Object holding the connection settings used to test the plugin connection. |
Notes
- Clearance is public, but the method is flagged private, so it is a dashboard-session method. No
min_plangate. - Returns
{code: 1, data: 'ok'}on success and-44with the driver error on failure.
get_marketplace_review_queue
Get Marketplace Review Queue
Lists the marketplace items awaiting a human decision, selecting on publish_stat in [1, 2]: 1 means the AI gate could not decide, 2 means an appeal was filed.
Availability: Operator only
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
limit |
number | No | Maximum rows. Defaults to 100. |
skip |
number | No | Rows to skip. Defaults to 0. |
Notes
- Clearance is admin, and the method is flagged private. No
min_plangate. - It queries
xuda_marketplaceonly, so a plugin held for review inxuda_pluginsdoes not appear in this queue even thoughmarketplace_operator_decisioncan act on one. - The practical restriction is the console route
/dashboard/admin/marketplace-review. No superuser check was found inside the method body itself.
marketplace_operator_decision
Marketplace Operator Decision
Resolves one queued item. Approving sets publish_stat and the mirrored stat to 3, clears the publish reason and the appeal token, and marks an open appeal upheld (appeal_stat 3). Rejecting sets 6, records the operator note or the AI reasons as the publish reason, mints an appeal token if there is none, and marks an open appeal denied (appeal_stat 4). Either way it records the deciding operator's email and timestamp on the approval object and notifies the owner.
Availability: Operator only
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
id |
string | Yes | ID of the marketplace or plugin item being reviewed. |
decision |
string | Yes | Operator decision, either approve or reject. |
db_name |
string | No | xuda_marketplace (default) or xuda_plugins. |
operator_uid |
string | No | The deciding operator's account id, resolved to an email for the audit trail. |
note |
string | No | Operator note, stored and used as the rejection reason shown to the seller. |
Notes
- Clearance is admin, and the method is flagged private. No
min_plangate. - Pass
db_name: 'xuda_plugins'to decide a plugin held for review, which is the only way to clear one because the queue method does not list them. - A rejection always leaves the seller a way back: it mints an appeal token when there is none, which is what the appeal link in the rejection email carries.
query_items
Query Items
Registered in config.json under marketplace_module with the description "Handles items.", but no export named query_items exists in the module. This is a dead registration. It is listed here only so that a reader who finds it in the method catalog knows not to build against it.
Availability: Dashboard session
Parameters
This method takes no parameters. No fields are declared for it and there is no implementation.
Notes
- Flagged private, no clearance set, no
min_plangate. - There is no working behavior behind this key. Do not call it.
The Seller Plan Ladder
The account's marketplace tier controls three things: how many listings stay on sale, which listing types may be sold, and the commission Xuda keeps on every sale. It is a separate ladder from the membership plan.
| Plan id | Name | Rank | Commission Xuda keeps | Live listings | Listing types allowed |
|---|---|---|---|---|---|
marketplace_free |
Free | 0 | 20% | 1 | project, ai_agent |
marketplace_starter |
Starter | 1 | 15% | 5 | project, ai_agent, instance |
marketplace_growth |
Grow | 2 | 10% | 20 | project, ai_agent, instance, managed_vps |
marketplace_scale |
Scale | 3 | 5% | unlimited | project, ai_agent, instance, managed_vps |
- Free is a real selling tier, not a trial. A seller can list one item, publish it, and be paid into their own Stripe account on Free, with Xuda keeping 20 percent.
- An account that never picked a tier is treated as
marketplace_free, and the charge path falls back to 20 percent for any seller whose plan is not a marketplace plan. - Only a listing that is live, or submitted and waiting on review, occupies a slot. Drafts, paused listings and rejected listings cost nothing, which is why pausing one listing is the immediate answer to hitting the cap.
- The cap is not retroactive. A seller already over it keeps everything on sale; only the next publish is refused, and an explicit downgrade that would strand listings is refused too.
- The commission is enforced at charge time from the seller's plan, independently of the tier's own billing status.
- The three paid tiers carry placeholder Stripe price ids in the production config as committed, so their monthly prices are not quoted here and a move to a paid tier on production may not be purchasable. The dev environment carries minted ids against Stripe test keys.
The membership gate is separate and additional. create_marketplace_listing, update_marketplace_listing, update_marketplace_listing_stat, capture_vps_listing_image and upload_plugin all carry min_plan: agency, which is the Agency tier of the membership ladder, rank 3 above Free, Pro and Team. A Free-seller-tier account still needs an Agency membership to create or publish a listing.
Seller eligibility is a third, separate gate. is_marketplace_pro is satisfied when the account has finance_active === true, or a Stripe Connect account status of active, or Xuda network ambassador status. Without it, create_marketplace_listing and a publish request both refuse with "marketplace pro required: approved seller account or xuda ambassador". Set the payout side up through Xuda Finance first.
Per-listing price limits. A listing price must be at least 5 and at most 100000, enforced at save. Stripe additionally rejects anything under 50 cents at charge time. Billing is monthly by default; listing_price_type: 'one_time' makes it a single charge. A listing's saved deploy configuration can add a separate per-deployment monthly hosting cost, which the buyer sees as its own line above the total.
The Publish Review Gate
Every publish request, for a listing, a component, an agent or a plugin, is screened before anything reaches the live state. The gate calls an AI reviewer that returns a structured verdict over ten named checks: bot activity, undisclosed commercial intent, harmful code, suspicious activity, malformed account name, spam, impersonation, prohibited content, plagiarism, and secrets or PII leakage.
Fixed thresholds decide what happens next:
| Situation | Outcome |
|---|---|
| Confidence 85 or above, no high-severity flag | Approved, published |
| Reject below confidence 60 | Downgraded to manual review |
| Any high-severity flag | Manual review, whatever the confidence |
| AI reviewer unreachable | Manual review. It never fails open to published |
| Account not in good standing | Rejected at confidence 100, whatever the model says |
Account standing is a hard override, not an input to the model. An account that is not at stat === 3, or is suspended, terminated, on a billing hold, or carries an abuse flag, cannot publish anything.
Lifecycle values you will read back. The publish lifecycle is tracked separately from the item's own stat and mirrored into it, so the stat === 3 visibility filters keep hiding anything unapproved.
publish_stat |
Meaning |
|---|---|
| 0 | Private or never published (plugins) |
| 1 | Pending review |
| 2 | Under review after an appeal |
| 3 | Published |
| 6 | Rejected |
Every item parked at manual review, and every appeal, also opens a real Xuda desk ticket. Tickets are deduped on the item id, so a re-running gate cannot pile them up.
Errors
Codes returned on the CPI envelope:
| Code | Where | Meaning |
|---|---|---|
-400 |
marketplace_like |
already liked. A like from this user already exists. |
-400 |
marketplace_follow |
already followed. The follow relationship already exists. |
-403 |
publish_plugin |
"A seller account is required to publish to the marketplace. Please set up your seller account first." |
-44 |
test_connection |
The database driver refused the connection; the driver error is returned with it. |
code 2 |
get_plugin_setup |
Not an error. The plugin has never been set up on that app, and an empty object is returned. |
code 1 |
test_connection |
Success, with data: 'ok'. |
Refusal messages you should handle by text, because they carry the remedy:
| Message | Raised by |
|---|---|
marketplace pro required: approved seller account or xuda ambassador |
create_marketplace_listing, update_marketplace_listing_stat |
| "You have N listings on sale and the |
marketplace_set_plan |
stat not supported |
update_marketplace_listing_stat with a value other than 1, 2 or 4 |
app already installed |
install_marketplace_item over a live copy |
Error - Must contain at least 1 tag |
update_app_marketplace |
| "this purchase has used all of its automatic retries, contact support, or cancel it for a refund" | retry_marketplace_provision |
| "this purchase is set up and running, delete what it created to stop billing" | cancel_refund_marketplace_purchase |
nothing knows how to provision a "<type>" listing yet |
Recorded on the purchase when no provisioner exists for the listing type |
Listing validation failures come back from create_marketplace_listing and update_marketplace_listing against these rules: a name of 5 to 50 characters, a description of 500 to 3000 characters, at least 3 keywords, a category, a live preview link, at least one image, and a price between 5 and 100000. A managed_vps listing additionally requires data.vps_image_acknowledged.
Rate Limits
There are no per-method rate limits on the marketplace CPI surface. The one rate-limited path is the public appeal route, POST /api/marketplace/appeal, which is rate limited at the router. The published limit was not part of the method contract, so no number is quoted here.
Several methods are cached instead, which is the practical throughput control on the read side:
| Method | Cache |
|---|---|
get_plugins, get_plugins_categories |
600 seconds |
get_marketplace_home_page |
600 seconds |
get_marketplace_listing_categories |
600 seconds |
get_marketplace_ai_agent_categories, get_marketplace_ai_agent_subcategories, get_marketplace_ai_agent_industries |
600 seconds |
marketplace_queries |
None. Responses are no-store |
Idempotency And Retry Rules
- Listing ids are deterministic. A listing id is minted from the app id plus the listing name, so creating the same-named listing on the same app addresses the same document instead of making a second one.
- Likes are not idempotent, unlikes are. A repeat
marketplace_likeanswers-400 already liked;marketplace_unlikereports success whether or not a like was present. - Follows are not idempotent. The document id is deterministic, but a repeat
marketplace_followanswers-400 already followed. - Views are deduped per viewer. One
marketplace_viewdocument per user per item, which is what makes the view count meaningful. - Purchases are one per buyer per listing. A second
purchase_marketplace_listingfor a listing the buyer already owns is refused, so the checkout is safe to retry. - Provisioning retries are capped at 3.
retry_marketplace_provisionrefuses the fourth attempt and points at the refund route. Calling it on an already-provisioned purchase returns immediately without doing anything. - The review gate short-circuits on a content hash. An unchanged, already-approved item is not re-reviewed on every save.
- Review tickets are deduped on the item id, so a re-running gate cannot open a second ticket for the same item.
- Installs are re-runnable over a soft-deleted copy but refused over a live one.
- Editing a listing always unpublishes it. Any update resets it to draft, so a publish call must follow, and that publish goes through the gate again.
Timeouts You Should Expect
| Operation | Wait |
|---|---|
| Project clone provision | up to 10 minutes |
| Managed VPS restore provision | up to 30 minutes |
| VPS image capture, waiting for a restorable backup | up to 60 minutes |
capture_vps_listing_image job timeout |
3,900,000 ms |
Purchase provisioning and provisioning retries are dispatched in the background and are not awaited by the calling method. Poll get_my_marketplace_purchases and read provision_stat for the outcome.
Webhooks
Marketplace publishes no inbound webhook of its own. Stripe events for marketplace charges and subscriptions are handled by the platform's general Stripe webhook path, not by a marketplace-specific endpoint.
Outbound, the product raises a marketplace notification category with three topics, each delivered by email and as an in-app banner:
| Topic | Fires when |
|---|---|
marketplace_item_approved |
An item is published, by the gate or by an operator |
marketplace_item_rejected |
An item is rejected, with the reasons and an appeal link |
marketplace_item_pending_review |
An item is parked for a human decision |
Operators are additionally emailed on every manual-review hold and every appeal. That email carries a customer card, an item card, the AI confidence, the reasons and a link into the review console.
There is no marketplace-specific cron. The catalogue is exposed to search engines through the sitemap generator, which emits sections for solutions, components, ai-agents, projects and pros, and through the server-rendered browse grid on the public site.
Related Endpoints That Are Not CPI Methods
POST /api/marketplace/appealis the public appeal endpoint behind the standalone page at/marketplace/appeal?token=...&item=.... It is rate limited and validatesitem_id(3 to 200 characters),reason(10 to 4000 characters) and an optional email. A successful appeal moves the item topublish_stat2, writes an appeal record, emails the operators and opens a desk ticket. It is an HTTP route, not a dispatchable CPI method, so it has no method key and cannot be called over the API or MCP layer.- Beyond that, the modules export internal functions used by the platform itself: the async provisioning worker fired by a purchase and by a retry, the cancel path that runs when a buyer deletes what a purchase created, the marketplace sync writers invoked from the studio change controller and the account and router modules, the gate primitives the plugin module reuses, and the runtime plugin helpers. No HTTP route reaches them, they are not part of any documented or supported surface, and they are not listed here.