From other replies to this question, I understand that using the 'Get Participant Data' and 'context.firstname', 'context,customField1' etc. should be used to retrieve the attributes. However, I am receiving a 'variable reference not valid' error when using context. as an expression in the attribute name.
When you set the Attribute Name in your Get Participant Data, if you define it as/via Literal, it would be context.firstname
If you define it as/via Expression, this would be: "context.firstname"
Given the error you are reporting, I assume you have used Expression and context.firstname (which is incorrect).
I have just realized there was a typo/error in the blog I wrote (if this is what you used) regarding firstname and lastname.
These two attributes are managed specifically on widgets side. So it would be context.firstName and context.lastName.