Q: Script to import from Pipedrive to google sheets for last 20 days

Hi. The id of the sheet is wrong. Take a look at Google Script’s documentation: https://developers.google.com/apps-script/reference/spreadsheet/spreadsheet-app#openById(String)