How to convert a $date to a $timestamp in an aggregation pipeline. (or any other means)

I’m stuck on the process of trying to convert a $date field to a $timestamp field in a collection.

I can add a $timestamp field manually on a new document, but I need help adding the $timestamp field to existing documents in my collection.

I’m using an aggregation pipeline (although I’m open to using queries or some other method instead) as follows:

[
{
$addFields:
/**
* Create the new field, creation_timestamp, and populate it with the value of an existing field, creation_date.
/
{
creation_timestamp: {
$toDate: “$creation_date”
}
}
},
{
$set:
/
*
* Convert the new field to Long data type, which correctly give us the Epoch time variant of the original creation_date field.
/
{
creation_timestamp: {
$convert: {
input: “$creation_timestamp”,
to: “long”,
onError: null,
onNull: null
}
}
}
},
{
$set:
/
*
* This is where it fails - $timestamp is unrecognized, same for Timestamp() and every other variant I’ve tried.
*/
{
creation_timestamp: {
$timestamp: {
t: 1729004300,
i: 1
}
}
}
}
]

So can anyone help me with an aggregation in Compass, or the Atlas collection viewer, that will convert the $date field of the $long field to a $timestamp data type?

Thanks!