                let {{ param_name }}: {{ rust_ty }} = {
                    let val = _metadata.get({{ idx }}).ok_or_else(|| napi::Error::new(napi::Status::InvalidArg, "missing metadata parameter at index {{ idx }}"))?;
                    {{ extraction }}
                };
