I am filtering request URL in which I need to provide boolean value for regex check. I do not know whether it is possible to make such regex or I need to change URLs to follow patterns,
I got confused because I need a match for two like /cart/{orgSlug}/{cartNameSlug} & /cart/{id} where slug name must have at least one character and id must be only numeric.
I am taking care of getting the proper URL by splitting by ? & checking request method as a preliminary test.
/cart/{id}, I have gotcart\/[0-9]{1,5}