I want to change API url in every 10 days for ex - url is http://localhost3000/api/invoice/1-2-22 and starting date is 1 Feb 2022 then after 10 days change url like this http://localhost3000/api/invoice/11-2-22 Then date start from 11 Feb 2022 and change url after 10 day url like this http://localhost3000/api/invoice/21-2-22
Using JavaScript (NodeJS)
You can use URL Parameters to add the date as a URL Segment, and in the handler you can validate the date and if it's invalid you can return a 404 response.
app.get('/hello/:date', (req,res) = >{
//access date using req.params.date
//validate date here and return response accordingly
});