Valmiki Ramayana Ayodhya Kanda Sarga 5 Shloka 11
Original Shlokaइत्युक्त्वा स तदा राममुपवासं यतव्रतम्। मन्त्रवत्कारयामास वैदेह्या सहितं मुनिः।।2.5.11।।
1 source checked for this shloka
सः मुनिः that ascetic(Vasistha), इति thus, उक्त्वा having spoken, यतव्रतम् observing vow, वैदेह्या सहितम् together with Sita, रामम् Rama, तदा then, मन्त्रवत् in accompaniment with sacred hymns, उपवासम् fast, कारयामास made (to undertake).
The ascetic (Vasistha) having thus spoken to Rama made him undertake fast along with Sita in accompaniment with sacred hymns.