[API] Specify optional mail notification

Specifies:
* [#4128](https://community.openproject.org/work_packages/4128)
* [#17009](https://community.openproject.org/work_packages/17009) (dup)

Note that this PR was branched from https://github.com/opf/openproject/pull/2078 to avoid inconsistencies regarding link usage...

I will rebase this onto dev as soon as #2078 was merged.