In MongoDB, the $add aggregation pipeline operator adds values together. Such values can be numbers, or they can be numbers and a date.
The $add operator accepts the values as arguments. The arguments can be any valid expression as long as they resolve to either all numbers or to numbers and a date.