How do I get a invoice url through api?

How do I get a invoice url through api?

Hello! I am trying to see how I can generate a url for an invoice via api to create a button on CRM to generate a link.