My google sheets apps script has a doGet() function which takes an HTTP get request and parses the query parameters and puts them in a spreadsheet.
When I tested the app with a get request, I got a '500 Internal Error message', I then tested the deployment and got the error message ' Exception: Unexpected error while getting the method or property openById on object SpreadsheetApp. (line 9, file "Code") '.
So, it's having a problem opening the sheet but I am certain I have the correct sheet ID looking at project settings. I thought it could be a google drive issue so I made an entirely new google account with a blank drive and a new spreadsheet but the same error appears!? I'm not sure what's going on here, so any help would be much appreciated! Code below:
https://github.com/Conwon99/4th-Year-Project/blob/main/GoogleAppsScript