> ## Documentation Index
> Fetch the complete documentation index at: https://docs.didit.me/llms.txt
> Use this file to discover all available pages before exploring further.

# Delete Rule

> Delete a CUSTOM rule. Deletion is immediate and permanent: the rule stops evaluating for new transactions and disappears from listings, while past rule runs on already-evaluated transactions keep their recorded results. Library rules cannot be deleted - uninstall them via the install endpoint instead (they can always be reinstalled from the library).

export const AgentPromptAccordion = ({prompt, title = "AI Agent Integration Prompt"}) => {
  const [copied, setCopied] = React.useState(false);
  const handleCopy = e => {
    e.stopPropagation();
    if (!prompt) return;
    navigator.clipboard.writeText(prompt.trim()).then(() => {
      setCopied(true);
      setTimeout(() => setCopied(false), 2000);
    });
  };
  const agents = ["Claude Code", "Codex", "Cursor", "Devin", "Windsurf", "GitHub Copilot"];
  return <div className="didit-agent-card">
      {}
      <div className="didit-agent-titlebar">
        <div className="didit-agent-dots" aria-hidden="true">
          <span className="didit-agent-dot didit-agent-dot-red"></span>
          <span className="didit-agent-dot didit-agent-dot-yellow"></span>
          <span className="didit-agent-dot didit-agent-dot-green"></span>
        </div>
        <span className="didit-agent-filename">{title}</span>
        <button type="button" className={`didit-agent-copy ${copied ? "didit-agent-copy-copied" : ""}`} onClick={handleCopy} title="Copy prompt to clipboard" aria-label={copied ? "Copied!" : "Copy prompt to clipboard"}>
          {copied ? <>
              <svg width="13" height="13" viewBox="0 0 16 16" fill="none">
                <path d="M3 8.5l3.5 3.5L13 4" stroke="currentColor" strokeWidth="2" strokeLinecap="round" strokeLinejoin="round" />
              </svg>
              <span>Copied</span>
            </> : <>
              <svg width="13" height="13" viewBox="0 0 16 16" fill="none">
                <rect x="5" y="5" width="9" height="9" rx="1.5" stroke="currentColor" strokeWidth="1.5" />
                <path d="M11 5V3.5A1.5 1.5 0 0 0 9.5 2h-6A1.5 1.5 0 0 0 2 3.5v6A1.5 1.5 0 0 0 3.5 11H5" stroke="currentColor" strokeWidth="1.5" />
              </svg>
              <span>Copy</span>
            </>}
        </button>
      </div>

      {}
      <pre className="didit-agent-body"><code>{prompt.trim()}</code></pre>

      {}
      <div className="didit-agent-footer">
        <span className="didit-agent-footer-label">Paste into</span>
        <div className="didit-agent-chips">
          {agents.map(name => <span key={name} className="didit-agent-chip">{name}</span>)}
        </div>
      </div>
    </div>;
};

<AgentPromptAccordion
  title="Delete Rule API Prompt"
  prompt={`Delete a CUSTOM transaction-monitoring rule.

Endpoint:
DELETE https://verification.didit.me/v3/transactions/rules/{rule_uuid}/

Authentication:
Use the x-api-key header with my Didit API key.

Behavior:
- 204 on success. Deletion is immediate and permanent: the rule stops evaluating for new transactions and disappears from listings. Rule runs already recorded on past transactions keep their results.
- Only CUSTOM rules can be deleted. A library preset returns 400 - uninstall it via DELETE /v3/transactions/rules/install/ instead (presets can always be reinstalled from the library).
- The freed title can be reused by a new rule.

Failure modes:
- 400 - the rule is a library preset.
- 404 - unknown rule uuid for this application.`}
/>


## OpenAPI

````yaml DELETE /v3/transactions/rules/{rule_uuid}/
openapi: 3.0.0
info:
  version: 3.0.0
  title: Didit Verification API
  description: Identity verification API. Authenticate with x-api-key header.
servers:
  - url: https://verification.didit.me
security: []
tags: []
paths:
  /v3/transactions/rules/{rule_uuid}/:
    parameters:
      - name: rule_uuid
        in: path
        required: true
        schema:
          type: string
          format: uuid
        description: The rule's uuid from list or create.
    delete:
      tags:
        - Transactions
      summary: Delete rule
      description: >-
        Delete a CUSTOM rule. Deletion is immediate and permanent: the rule
        stops evaluating for new transactions and disappears from listings,
        while past rule runs on already-evaluated transactions keep their
        recorded results. Library rules cannot be deleted - uninstall them via
        the install endpoint instead (they can always be reinstalled from the
        library).
      operationId: deleteTransactionRule
      responses:
        '204':
          description: Deleted.
        '400':
          description: The rule is a library preset - uninstall instead.
          content:
            application/json:
              schema:
                type: object
              example:
                detail: >-
                  Library rules cannot be deleted. Uninstall them via the rules
                  install endpoint instead.
        '404':
          description: No such rule on this application.
          content:
            application/json:
              schema:
                type: object
      security:
        - ApiKeyAuth: []
      x-codeSamples:
        - lang: curl
          label: curl
          source: >-
            curl -X DELETE
            'https://verification.didit.me/v3/transactions/rules/RULE_UUID/' \
              -H 'x-api-key: YOUR_API_KEY'
components:
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: header
      name: x-api-key

````