This code is repeated here:

https://github.com/mozilla-b2g/gaia/pull/17139/files#diff-af7a3fb259f614cb38f498ee6deedb0dR490

we could extract it to a `buildSendOptions` or something similar no?