The JavaScript in your add-on will have access to the DOM, and global document and window objects, so getting the page URL is just document.location.href
You can also use "background scripts" instead of "content scripts", which are more powerful.
The easiest way to do IPC between an extension/add-on and a native app is probably running an HTTP server in the app and making requests within the extension. The extension may need special permissions to send requests to localhost.