encode

full version that accepts ubyte[] as payload and JSONValue tree as header fields

Meta