{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/omniapps-ca/json-schema/omniapps-ca-dlqrequest-schema.json",
  "title": "DLQRequest",
  "x-generated": "2026-11-19",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/sairen-omniapps-ca-openapi.json#/components/schemas/DLQRequest",
  "properties": {
    "action": {
      "type": "string",
      "title": "Action",
      "description": "Action to perform: 'push', 'pop', 'peek', 'ack', 'nack', 'clear', 'stats'",
      "default": "push"
    },
    "queue_name": {
      "type": "string",
      "title": "Queue Name",
      "description": "Namespace queue name",
      "default": "default"
    },
    "task_id": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Task Id",
      "description": "Task ID for ack/nack or specific push"
    },
    "tool_name": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Tool Name",
      "description": "Name of the tool that encountered an error",
      "default": "unknown"
    },
    "error_message": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Error Message",
      "description": "Error message or exception string",
      "default": ""
    },
    "error_type": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Error Type",
      "description": "Exception class or category",
      "default": "UnknownError"
    },
    "payload": {
      "anyOf": [
        {
          "additionalProperties": true,
          "type": "object"
        },
        {
          "type": "null"
        }
      ],
      "title": "Payload",
      "description": "Original task payload/parameters"
    },
    "ttl_seconds": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ],
      "title": "Ttl Seconds",
      "description": "Time-to-live in seconds before automatic purge (max 86400)",
      "default": 3600
    },
    "max_retries": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ],
      "title": "Max Retries",
      "description": "Maximum retry attempts before marking dead",
      "default": 3
    },
    "limit": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ],
      "title": "Limit",
      "description": "Max items to return for peek",
      "default": 10
    },
    "error_detail": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Error Detail",
      "description": "Additional failure detail for nack",
      "default": ""
    }
  },
  "type": "object"
}