How To Change From Index.php?dispatch=Products.view&product_Id=222 To Friendly Url(Seo)

Hope you are doing well

i don't know how to change the urn to SEO friendly link
for example i am trying to change these links to their respective seo name but i don't know how in storefronts

http://domain.com/index.php?sl=arthis should be http://domain.asia/ar/

another example for categories
http://domain.com/index.php?dispatch=categories.view&category_id=266
should be http://domain.com/en/audio/

another example for products

http://domain.com/index.php?dispatch=products.view&product_id=320
should be
http://domain.com/en/dls-cci500-40-carhifi-power-amplifier-550watts-rms-monoblock/

what i have now is the current path got it from runtime(Registry::get('config.current_url')) which is like

index.php?dispatch=products.view&product_id=320

so i want to get the corresponding seo url of this path

but the domain name i don't want because it's already pre-defined
because i customizing the hreflang to support subdomains so google's crawls can go through all the domains but, currently google redirecting to 301 error

so what i changed in test server are below
1. design/themes/responsive/templates/addons/seo/hooks/index/meta.post.tpl

2. app/addons/seo/func.php --- function name: fn_seo_dispatch_before_display
i just added the storefronts

so could you please advise