{
  "openapi": "3.1.0",
  "info": {
    "title": "ahtml.dev",
    "version": "1.0.0"
  },
  "servers": [
    {
      "url": "https://ahtmljs.vercel.app"
    }
  ],
  "paths": {
    "/ahtml/": {
      "get": {
        "summary": "AHTML snapshot of /",
        "responses": {
          "200": {
            "description": "snapshot",
            "content": {
              "application/ahtml+text": {
                "schema": {
                  "type": "string"
                }
              },
              "application/ahtml+json": {
                "schema": {
                  "$ref": "#/components/schemas/Snapshot"
                }
              }
            }
          },
          "304": {
            "description": "not modified"
          }
        }
      }
    },
    "/ahtml/demo/products/mbp-14-m3": {
      "get": {
        "summary": "AHTML snapshot of /demo/products/mbp-14-m3",
        "responses": {
          "200": {
            "description": "snapshot",
            "content": {
              "application/ahtml+text": {
                "schema": {
                  "type": "string"
                }
              },
              "application/ahtml+json": {
                "schema": {
                  "$ref": "#/components/schemas/Snapshot"
                }
              }
            }
          },
          "304": {
            "description": "not modified"
          }
        }
      }
    },
    "/ahtml/demo/products/mbp-16-m3": {
      "get": {
        "summary": "AHTML snapshot of /demo/products/mbp-16-m3",
        "responses": {
          "200": {
            "description": "snapshot",
            "content": {
              "application/ahtml+text": {
                "schema": {
                  "type": "string"
                }
              },
              "application/ahtml+json": {
                "schema": {
                  "$ref": "#/components/schemas/Snapshot"
                }
              }
            }
          },
          "304": {
            "description": "not modified"
          }
        }
      }
    },
    "/ahtml/demo/products/aw-ultra-2": {
      "get": {
        "summary": "AHTML snapshot of /demo/products/aw-ultra-2",
        "responses": {
          "200": {
            "description": "snapshot",
            "content": {
              "application/ahtml+text": {
                "schema": {
                  "type": "string"
                }
              },
              "application/ahtml+json": {
                "schema": {
                  "$ref": "#/components/schemas/Snapshot"
                }
              }
            }
          },
          "304": {
            "description": "not modified"
          }
        }
      }
    },
    "/ahtml/demo/products/ipad-pro-m4": {
      "get": {
        "summary": "AHTML snapshot of /demo/products/ipad-pro-m4",
        "responses": {
          "200": {
            "description": "snapshot",
            "content": {
              "application/ahtml+text": {
                "schema": {
                  "type": "string"
                }
              },
              "application/ahtml+json": {
                "schema": {
                  "$ref": "#/components/schemas/Snapshot"
                }
              }
            }
          },
          "304": {
            "description": "not modified"
          }
        }
      }
    },
    "https://npmjs.com/package/@ahtmljs/next": {
      "get": {
        "summary": "Install via npm",
        "operationId": "install",
        "responses": {
          "200": {
            "description": "success"
          }
        },
        "x-ahtml-cost": {
          "category": "free"
        }
      }
    },
    "/api/waitlist": {
      "post": {
        "summary": "Join waitlist",
        "operationId": "join_waitlist",
        "responses": {
          "200": {
            "description": "success"
          }
        },
        "x-ahtml-cost": {
          "category": "free"
        },
        "x-ahtml-reversible": {
          "reversible": true,
          "policy": "unsubscribe"
        },
        "x-ahtml-side-effects": [
          "create_subscription",
          "send_email"
        ]
      }
    },
    "https://github.com/DibbayajyotiRoy/AHTML/tree/main/examples/benchmark": {
      "get": {
        "summary": "Run the benchmark locally",
        "operationId": "run_benchmark",
        "responses": {
          "200": {
            "description": "success"
          }
        },
        "x-ahtml-cost": {
          "category": "free"
        }
      }
    },
    "/spec": {
      "get": {
        "summary": "View v0.1 spec",
        "operationId": "view_spec",
        "responses": {
          "200": {
            "description": "success"
          }
        },
        "x-ahtml-cost": {
          "category": "free"
        }
      }
    },
    "/api/checkout": {
      "post": {
        "summary": "Buy now",
        "operationId": "purchase",
        "responses": {
          "200": {
            "description": "success"
          }
        },
        "x-ahtml-cost": {
          "amount": 1299,
          "currency": "USD",
          "category": "purchase"
        },
        "x-ahtml-reversible": {
          "reversible": true,
          "window": "P30D",
          "policy": "full_refund"
        },
        "x-ahtml-side-effects": [
          "charge_card",
          "email_buyer",
          "decrement_stock",
          "generate_receipt"
        ],
        "x-ahtml-confirmation": "required",
        "security": [
          {
            "bearer": []
          }
        ]
      }
    },
    "/api/cart/items": {
      "post": {
        "summary": "Add to cart",
        "operationId": "add_to_cart",
        "responses": {
          "200": {
            "description": "success"
          }
        },
        "x-ahtml-cost": {
          "category": "free"
        },
        "x-ahtml-reversible": {
          "reversible": true,
          "policy": "remove_from_cart"
        },
        "x-ahtml-side-effects": [
          "modify_session"
        ],
        "security": [
          {
            "bearer": []
          }
        ]
      }
    }
  },
  "components": {
    "schemas": {
      "Snapshot": {
        "$ref": "https://raw.githubusercontent.com/DibbayajyotiRoy/AHTML/main/packages/schema/src/schema.json"
      }
    },
    "securitySchemes": {
      "bearer": {
        "type": "http",
        "scheme": "bearer"
      }
    }
  }
}