{
  "x402Version": 2,
  "id": 15244,
  "slug": "15244",
  "resource": "https://quantum.halowerk.com/v1/circuit-optimize",
  "description": "Cancels adjacent identical self-inverse gates on identical ordered targets and folds adjacent RX, RY or RZ rotations on identical targets. It preserves only these local identities; it does not commute gates, model hardware topology, synthesize arbitrary unitaries or prove global optimality.",
  "type": "http",
  "accepts": [
    {
      "scheme": "exact",
      "network": "eip155:8453",
      "payTo": "0x2880EdfFF13100677Bf97A3CBdF3Bc34771C4E5E",
      "asset": "0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913",
      "amount": "4000",
      "maxTimeoutSeconds": 300
    }
  ],
  "outputSchema": {
    "bazaar": {
      "info": {
        "input": {
          "body": {
            "gates": [
              {
                "gate": "H",
                "targets": [
                  0
                ]
              },
              {
                "gate": "H",
                "targets": [
                  0
                ]
              },
              {
                "angle_rad": 0.4,
                "gate": "RZ",
                "targets": [
                  1
                ]
              },
              {
                "angle_rad": -0.1,
                "gate": "RZ",
                "targets": [
                  1
                ]
              },
              {
                "gate": "CNOT",
                "targets": [
                  0,
                  2
                ]
              }
            ],
            "qubit_count": 3
          },
          "bodyType": "json",
          "method": "POST",
          "type": "http"
        }
      },
      "schema": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "properties": {
          "input": {
            "additionalProperties": false,
            "properties": {
              "body": {
                "additionalProperties": false,
                "properties": {
                  "gates": {
                    "items": {
                      "additionalProperties": false,
                      "properties": {
                        "angle_rad": {
                          "maximum": 1000000,
                          "minimum": -1000000,
                          "type": "number"
                        },
                        "gate": {
                          "enum": [
                            "X",
                            "Y",
                            "Z",
                            "H",
                            "CNOT",
                            "CZ",
                            "SWAP",
                            "RX",
                            "RY",
                            "RZ"
                          ],
                          "type": "string"
                        },
                        "targets": {
                          "items": {
                            "maximum": 127,
                            "minimum": 0,
                            "type": "integer"
                          },
                          "maxItems": 2,
                          "minItems": 1,
                          "type": "array",
                          "uniqueItems": true
                        }
                      },
                      "required": [
                        "gate",
                        "targets"
                      ],
                      "type": "object"
                    },
                    "maxItems": 10000,
                    "minItems": 1,
                    "type": "array"
                  },
                  "qubit_count": {
                    "maximum": 128,
                    "minimum": 1,
                    "type": "integer"
                  }
                },
                "required": [
                  "qubit_count",
                  "gates"
                ],
                "type": "object"
              },
              "bodyType": {
                "enum": [
                  "json",
                  "form-data",
                  "text"
                ],
                "type": "string"
              },
              "method": {
                "enum": [
                  "POST",
                  "PUT",
                  "PATCH"
                ],
                "type": "string"
              },
              "type": {
                "const": "http",
                "type": "string"
              }
            },
            "required": [
              "type",
              "method",
              "bodyType",
              "body"
            ],
            "type": "object"
          }
        },
        "required": [
          "input"
        ],
        "type": "object"
      }
    }
  },
  "tags": [
    "bazaar"
  ],
  "sourceHost": "quantum.halowerk.com",
  "lastUpdated": "2026-09-01T07:51:38.115Z",
  "quality": {
    "calls30d": 1,
    "uniquePayers30d": 1,
    "lastCalledAt": "2026-09-01T07:51:37.673Z"
  },
  "liveness": {},
  "verified": false,
  "featured": false,
  "provider": {
    "host": "quantum.halowerk.com",
    "manifest_name": "quantum.halowerk.com",
    "source": "cdp-mirror",
    "source_manifest_url": "https://api.cdp.coinbase.com/platform/v2/x402/discovery/resources",
    "submitted_at": "2026-09-18T22:00:31.484Z"
  }
}