I'm trying to use the Transactional Messaging API (https://developer.salesforce.com/docs/atlas.en-us.noversion.mc-apis.meta/mc-apis/transactional-messaging-api.htm) to create a password reset e-mail that could be triggered by an API call from outside SFMC. I managed to successfully create a send definition for a simple e-mail and trigger it, but I'm having trouble with something more complex.
According to https://developer.salesforce.com/docs/atlas.en-us.mc-apis.meta/mc-apis/sendMessageSingleRecipient.htm, it is possible to pass recipient attributes in an API call. ("Information used to personalize the message for the recipient. Written as key:value pairs. The attributes match profile attributes, content attributes, or triggered send data extension attributes.") How to actually use this information to personalize the message? If I want to pass values like:
"attributes": {
"user_code": "value"
}
How do I actually use "user_code" in the e-mail? Putting in %%user_code%% in the content makes my create send definition POST request (https://developer.salesforce.com/docs/atlas.en-us.mc-apis.meta/mc-apis/createSendDefinition.htm) fail with MCMS_UTM_Validation_email_does_not_pass_validation.