Hi @Mohamed Umair Mohamed Anhar ,
Thanks for reaching out.
I understand you are trying to protect the API using authorize attribute and getting 404 error.
This error usually comes when you are not providing valid access token. Did you try to decode your access token using jwt.ms have valid scopes?
To call the API, MSAL configuration has protectedResourceMap to make sure that your code adds the web API URI and the web API HTTP method, with the corresponding scopes. This configuration makes sure that MsalGuard is applied when Angular app tries to call the web API.
protectedResourceMap: new Map([
[protectedResources.testApi.endpoint, protectedResources.testAPI.scopes]
Hope this will help.
Thanks,
Shweta
--------------------------
Please remember to "Accept Answer" if answer helped you.