How to set manifest V3 file when popup use fetch in firefox ver115?

When pasting code here, place triple backticks (```) on the line above and below the code, that will activate code format.

Regarding the issue - sadly, in MV3 in Firefox the host permissions needs to be manually granted by user:

You can use this API to ask user to grant the permissions: