pub async fn run<F, Fut>(init: F) -> Result<(), Error>Expand description
Starts the extension runtime, calling init with an ExtensionHandle.
This is the main entry point for an extension. The runtime runs until the
host disconnects or ExtensionHandle::shutdown is called.
use powhttp_sdk::{run, Error, ExtensionHandle};
#[tokio::main]
async fn main() -> Result<(), Error> {
run(async |handle: ExtensionHandle| {
Ok(())
}).await
}