I require help creating a VBA program to access an application called ZohoSheets API. I'm getting an error: "Invalid data for found for parameter [method]" (it may look like a typing mistake, but this is the response I've got).
I've tried various example code I've found on this website. I haven't been able to get any of it to work. Example (I've placed the xxx's as placeholders. They weren't used during runtime.):
Option Explicit
Sub ZohoSheets()
Dim XMLHTTP
Dim URL As String
Dim parameters As String
Set XMLHTTP = CreateObject("MSXML2.XMLHTTP.6.0")
parameters = "method=worksheet.list"
URL = "https://sheet.zoho.com/api/v2/xxxx"
XMLHTTP.Open "POST", URL, False
XMLHTTP.setRequestHeader "Authorization", "Zoho-oauthtoken 1000.xxx.xxx"
XMLHTTP.send parameters
MsgBox XMLHTTP.responsetext
End Sub
This is what I received: {"error_message":"Invalid data for found for the parameter [method]", "error_code:":2878}
Please help. Thanks!
methodparameter. (CC @QHarr)