package thalo:aggregate; world aggregate { export aggregate: interface { record event { event: string, payload: string, } record command { command: string, payload: string, } variant error { command(string), ignore(option), deserialize-command(string), deserialize-context(string), deserialize-event(string), serialize-event(string), } resource agg { constructor(id: string); apply: func(events: list) -> result<_, error>; handle: func(command: command) -> result, error>; } } }