I currently have a custom event set up to capture user log in through Auth0 using Amplitude’s HTTP API. When I inspect the event in Users and Sessions I can see that it captured standard user properties like user id, device id, country, ect. I was wondering if it’s possible for me to send any custom data with this event. This is the code I wrote:
exports.onExecutePostLogin = async (event, api) => {
const fetch = require('node-fetch');
const response = await fetch('https://api2.amplitude.com/2/httpapi', {
method: 'POST',
headers: {
'Content-Type': 'application/json',
'Accept': '*/*'
},
body: JSON.stringify({
"api_key": event.secrets.API_KEY,
"events": s{
"event_type": "User log in"
}]
})
})
Let’s just say for an example I wanted to capture the user email or log in time, would it be possible for me to capture this information? Currently, when I add a key value pair to the events array in the body like `email: myemail@gmail.com` this information isn’t captured.