IReportClient RepClient = new ReportClient("****************************************");
try
{
string tableURI = RepClient.GetURI("my_mail", "Data", "Reports");
Dictionary<string, string> ImportConfig = new Dictionary<string, string>();
ImportConfig.Add("ZOHO_ON_IMPORT_ERROR", "ABORT");
ImportConfig.Add("ZOHO_CREATE_TABLE", "TRUE");
ImportConfig.Add("ZOHO_AUTO_IDENTIFY", "TRUE");
Dictionary<string, string> ImportRes = RepClient.ImportData(
tableURI, ZohoReportsConstants.APPEND, "C:\\CTR_Data\\tests.json", ImportConfig);
Console.WriteLine("Zoho Token: " + ZReports.ReportClient.AuthToken.ToString() + DateTime.Now );
Console.WriteLine("Zoho URL: " + tableURI+ " " + DateTime.Now + "=================>");
Console.WriteLine("Zoho Parameters "+"{" + string.Join(",", ImportConfig.Select(kv => kv.Key + "=" + kv.Value).ToArray())+" " + DateTime.Now + "}");
}
catch (Exception ex)
{
Console.WriteLine(ex.ToString());
Console.WriteLine(ZReports.ReportClient.AuthToken.ToString());
}
I always get Server bad request 400,