Hadithcore
Sahih Muslim, 1972 c
sahih

Jabir b. 'Abdullah reported:

We did not eat the flesh of sacrificed animals beyond three (days), but then Allah's Messenger (ﷺ) commanded us to make it a provision for journey and cat it (beyond three days).

حَدَّثَنَا إِسْحَاقُ بْنُ إِبْرَاهِيمَ، أَخْبَرَنَا زَكَرِيَّاءُ بْنُ عَدِيٍّ، عَنْ عُبَيْدِ اللَّهِ بْنِ عَمْرٍو، عَنْ زَيْدِ بْنِ أَبِي أُنَيْسَةَ، عَنْ عَطَاءِ بْنِ أَبِي رَبَاحٍ، عَنْ جَابِرِ بْنِ عَبْدِ اللَّهِ، قَالَ كُنَّا لاَ نُمْسِكُ لُحُومَ الأَضَاحِيِّ فَوْقَ ثَلاَثٍ فَأَمَرَنَا رَسُولُ اللَّهِ صلى الله عليه وسلم أَنْ نَتَزَوَّدَ مِنْهَا وَنَأْكُلَ مِنْهَا ‏.‏ يَعْنِي فَوْقَ ثَلاَثٍ ‏.‏

References2 variants
In-Book Reference
Book 35, Hadith 43
USC-MSA web (English) reference
Book 22, Hadith 4859 (deprecated numbering scheme)