I try to transform long url to short url and using "shortener" API on Google Apps Script, but still get "Forbidden" message. I have created "API Key" at google cloud platform, anything else? thanks.
google's sample code link: https://developers.google.com/apps-script/advanced/url-shortener?hl=vi
function shortenerUrl(){
var url = UrlShortener.Url.insert(
{
longUrl: "http://www.example.com"
});
Logger.log('Shortened URL is "%s".', url);`enter code here`
}