---
title: "Purge rows by URL pattern"
method: POST
path: "/webdbs/collections/{collection_id}/purge"
tags: ["webdbs"]
---

# Purge rows by URL pattern

`POST /webdbs/collections/{collection_id}/purge`

Permanently deletes matching rows, change history, and saved pages.

## Path parameters

- `collection_id` string, required — Collection ID.

## Request body

- WebdbsPurgeRequest — Selects rows to permanently delete by URL.
  - `url_match` string[], required — URL patterns for rows to permanently delete. Supports exact URLs, `*`, `**`, and `:name` path values.
  - `tags` string[] — Optional tags for tracking usage. Up to 20 tags, each 1 to 50 characters.

## Response `202`

Purge queued

- WebdbsRunQueuedResponse — Confirms that a collection run was queued.
  - `collection_id` string, required — Collection ID.
  - `run_id` string, required — Queued run ID.
  - `queued` boolean, required — Whether the run was queued.
  - `key_metadata` object — API key usage for this request.
    - `credits_consumed` integer, required — The number of credits consumed by this request.
    - `credits_remaining` integer, required — The number of credits remaining for your organization after this request.

## Other responses

- `400` — Bad request
- `401` — Unauthorized
- `404` — Not found

---

[API](https://skmtc.net/context/apis/context-dev.md) · [All operations](https://skmtc.net/context/apis/context-dev/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/context/context-dev/versions/3c6a01ba967f/schema)
