Adding id in relations JSON