How to invoke portal API using scripting on portal hosted with Azure app service using OIDC/Connect Identity Provider?

Anyone knows how to invoke portal API using scripting on portal hosted with Azure app service using OIDC/Connect Identity Provider? Can’t seem to find any sample scripting not going through web browser instance.