scrapewise_delete_customer_schema
Permanently remove a JSON-Schema document owned by the authenticated customer.
The path is rooted at `/customer/{id}` to make the customer-scope explicit;
deleting a global schema requires admin tooling outside the MCP surface.
**Destructive operation.** Once deleted, any AI_CONF scrapers that reference
this schema will fail at runtime with a missing-schema error — they need to
be reattached to a different schema (or deleted) BEFORE the schema is removed.
PR-4b will split this op into `scrapewise_delete_customer_schema_preview` +
`scrapewise_delete_customer_schema_commit` so an agent can show a "scrapers
using this schema" preview before committing the deletion. For now, this is
an immediate single-call delete.
Args:
- id (string, path param, required): the schema's MongoDB ObjectId. Get
from scrapewise_list_customer_schema.
Returns:
204 No Content on success. The body is empty by design — the only meaningful
response is the HTTP status. To verify deletion, call
scrapewise_list_customer_schema and confirm the id is no longer present.
Examples:
- Use when: "delete my unused 'old-product-v1' schema" — fetch via list,
copy id, call this op
- Use when: cleaning up after migrating scrapers to a new schema version —
make sure NO scrapers still reference the old id before deleting
- Don't use when: you only want to stop using a schema temporarily →
schemas have no soft-disable; consider versioning instead
- Don't use when: PR-4b destructive split is available → prefer the
_preview / _commit pair, which surfaces affected-scraper count first
Error Handling:
- 204 No Content on successful delete.
- 401 Unauthorized if no Firebase JWT or API key.
- 404 (CustomerError envelope) if no schema with that id exists or it's
not owned by the authenticated customer.
- 500 INTERNAL with `correlationId` if persistence fails mid-delete.[runtime hint] This tool returns JSON-as-text — its response shape is dynamic (per-scraper itemsConfig, file binary, etc.) so the MCP outputSchema is omitted. Do not rely on the presence of any specific field in the response; treat the result as a string-or-object blob and parse defensively.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"id": "<id>"
},
"name": "scrapewise_delete_customer_schema"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| id | Yes | the schema's MongoDB ObjectId. Get from scrapewise_list_customer_schema. |