parse-community / parse-community/parse-server-api-mail-adapter
Extra values are not present in callback payload
Nobody has claimed this yet.
- Dominant language
- JavaScript
- Stars
- 27
- Forks
- 21
- Avg merge
- 56m
- Merged PRs (30d)
- 1
Description
New Issue Checklist
- I am not disclosing a vulnerability.
- I am not just asking a question.
- I have searched through existing issues.
- I can reproduce the issue with the latest version.
Issue Description
When additional properties are defined in sendMail(options), they aren't present in the payload of the callback.
Steps to reproduce
Parse.Cloud.sendEmail({
templateName: 'testTemplate',
placeholders: {
name: 'Test',
},
recipient: 'testmail@domain.com',
extra: {
testKey: 'testValue'
}
})
Actual Outcome
config.emailAdapter = {
module: 'parse-server-api-mail-adapter',
options: {
sender: '..',
templates: { ... },
apiCallback: async ({ payload, locale }) => {
console.log(payload)
})
}
}
output:
{
from: '...',
to: '...',
subject: 'Test\n',
text: '...',
html: '<html>\n' +
' <body>\n' +
' <p>Test</p>\n' +
' </body>\n' +
'</html>\n'
}
Expected Outcome
The properties set in extra should be present somehow.
Failing Test Case / Pull Request
Environment
- API Mail Adapter version:
3.1.1 - Parse Server version:
6.4.0
Logs
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start at the sendMail(options) flow and the apiCallback({ payload, locale }) entry point, reproducing the issue with Parse.Cloud.sendEmail and an extra.testKey value. Trace how the payload is assembled and determine a consistent representation for the extra properties; done means those properties are available in the callback payload without changing existing fields.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript
- Domain
- api, backend
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 35/100