Thanks for asking question! Could you please confirm if you have added Application Insights to your function app? As, Azure Static Web Apps provides an API through Azure Functions. The capabilities of Azure Functions are focused to a specific set of features that enable you to create an API for a web app and allow the web app to connect to API securely. As these features come with some constraints, which includes:
Logs are only available if you add Application Insights to your Functions app.
You may also refer to this blog might be helpful: GETTING LOGS FROM STATIC WEB APPS APIS
Reference: https://video2.skills-academy.com/en-us/azure/static-web-apps/apis#constraints
Please let us know if you have query on this.
Disclaimer: This response contains a reference to a third-party World Wide Web site. Microsoft is providing this information as a convenience to you.