Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions src/ForceToolkitForNET/ForceClient.cs
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,13 @@ public Task<QueryResult<T>> QueryAllAsync<T>(string query)
return _jsonHttpClient.HttpGetAsync<QueryResult<T>>(string.Format("queryAll/?q={0}", Uri.EscapeDataString(query)));
}

public Task<T> ExecuteReportAsync<T>(string reportName)
{
if (string.IsNullOrEmpty(reportName)) throw new ArgumentNullException("reportName");

return _jsonHttpClient.HttpGetAsync<T>(string.Format("analytics/reports/{0}?includeDetails=true", reportName));
}

public async Task<T> ExecuteRestApiAsync<T>(string apiName)
{
if (string.IsNullOrEmpty(apiName)) throw new ArgumentNullException("apiName");
Expand Down
1 change: 1 addition & 0 deletions src/ForceToolkitForNET/IForceClient.cs
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ public interface IForceClient: IDisposable
Task<QueryResult<T>> QueryContinuationAsync<T>(string nextRecordsUrl);
Task<QueryResult<T>> QueryAllAsync<T>(string query);
Task<T> QueryByIdAsync<T>(string objectName, string recordId);
Task<T> ExecuteReportAsync<T>(string reportName);
Task<T> ExecuteRestApiAsync<T>(string apiName);
Task<T> ExecuteRestApiAsync<T>(string apiName, object inputObject);
Task<SuccessResponse> CreateAsync(string objectName, object record);
Expand Down