I have a many to many relation using mongoose, that looks like this.
TeamSchema = new Schema name : String players: [{ type: ObjectId, ref: \'Player
Just use addToSet method:
team.players.addToSet(player) team.save()