Requires any of the roles: | SystemAdministrator, Manager, Customer |
All Verbs | /reports/call-outcome |
---|
import java.math.*;
import java.util.*;
import java.io.InputStream;
import net.servicestack.client.*;
public class dtos
{
public static class CallOutcomeReport extends ReportRequest
{
public String startDate = null;
public String endDate = null;
public String timeZoneId = null;
public String customerId = null;
public String specificState = null;
public Boolean includeArchivedSessions = null;
public String getStartDate() { return startDate; }
public CallOutcomeReport setStartDate(String value) { this.startDate = value; return this; }
public String getEndDate() { return endDate; }
public CallOutcomeReport setEndDate(String value) { this.endDate = value; return this; }
public String getTimeZoneId() { return timeZoneId; }
public CallOutcomeReport setTimeZoneId(String value) { this.timeZoneId = value; return this; }
public String getCustomerId() { return customerId; }
public CallOutcomeReport setCustomerId(String value) { this.customerId = value; return this; }
public String getSpecificState() { return specificState; }
public CallOutcomeReport setSpecificState(String value) { this.specificState = value; return this; }
public Boolean isIncludeArchivedSessions() { return includeArchivedSessions; }
public CallOutcomeReport setIncludeArchivedSessions(Boolean value) { this.includeArchivedSessions = value; return this; }
}
public static class ReportRequest implements IPost
{
/**
* The account ID this report should be run for
*/
@ApiMember(Description="The account ID this report should be run for")
public String accountId = null;
/**
* The email address to notify after the report is run
*/
@ApiMember(Description="The email address to notify after the report is run")
public String emailAddressToNotify = null;
/**
* The webhook to call after the report is complete with the data from the report
*/
@ApiMember(Description="The webhook to call after the report is complete with the data from the report")
public String webhookUrl = null;
public String getAccountId() { return accountId; }
public ReportRequest setAccountId(String value) { this.accountId = value; return this; }
public String getEmailAddressToNotify() { return emailAddressToNotify; }
public ReportRequest setEmailAddressToNotify(String value) { this.emailAddressToNotify = value; return this; }
public String getWebhookUrl() { return webhookUrl; }
public ReportRequest setWebhookUrl(String value) { this.webhookUrl = value; return this; }
}
public static class ReportInfo
{
public String id = null;
public String name = null;
public ReportStatuses status = null;
public String statusMessage = null;
public String dateCreated = null;
public String dateUpdated = null;
public String downloadLink = null;
public String jobId = null;
public String emailAddressToNotify = null;
public String server = null;
public String getId() { return id; }
public ReportInfo setId(String value) { this.id = value; return this; }
public String getName() { return name; }
public ReportInfo setName(String value) { this.name = value; return this; }
public ReportStatuses getStatus() { return status; }
public ReportInfo setStatus(ReportStatuses value) { this.status = value; return this; }
public String getStatusMessage() { return statusMessage; }
public ReportInfo setStatusMessage(String value) { this.statusMessage = value; return this; }
public String getDateCreated() { return dateCreated; }
public ReportInfo setDateCreated(String value) { this.dateCreated = value; return this; }
public String getDateUpdated() { return dateUpdated; }
public ReportInfo setDateUpdated(String value) { this.dateUpdated = value; return this; }
public String getDownloadLink() { return downloadLink; }
public ReportInfo setDownloadLink(String value) { this.downloadLink = value; return this; }
public String getJobId() { return jobId; }
public ReportInfo setJobId(String value) { this.jobId = value; return this; }
public String getEmailAddressToNotify() { return emailAddressToNotify; }
public ReportInfo setEmailAddressToNotify(String value) { this.emailAddressToNotify = value; return this; }
public String getServer() { return server; }
public ReportInfo setServer(String value) { this.server = value; return this; }
}
public static enum ReportStatuses
{
Queued,
Running,
Completed,
Error;
}
}
To override the Content-type in your clients, use the HTTP Accept Header, append the .jsv suffix or ?format=jsv
The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.
POST /reports/call-outcome HTTP/1.1
Host: team.evovoice.io
Accept: text/jsv
Content-Type: text/jsv
Content-Length: length
{
startDate: String,
endDate: String,
timeZoneId: String,
customerId: String,
specificState: String,
includeArchivedSessions: False,
accountId: String,
emailAddressToNotify: String,
webhookUrl: String
}
HTTP/1.1 200 OK Content-Type: text/jsv Content-Length: length { id: String, name: String, status: Queued, statusMessage: String, dateCreated: String, dateUpdated: String, downloadLink: String, jobId: String, emailAddressToNotify: String, server: String }