Evo Voice

<back to all web services

GetActiveCalls

Gets all activecalls

Requires Authentication
Requires any of the roles:SystemAdministrator, Manager
The following routes are available for this service:
GET/calls/active
import java.math.*;
import java.util.*;
import net.servicestack.client.*;

public class dtos
{

    /**
    * Gets all activecalls
    */
    @Api(Description="Gets all activecalls")
    public static class GetActiveCalls implements IGet
    {
        /**
        * The account ID to retrieve for
        */
        @ApiMember(Description="The account ID to retrieve for")
        public String accountId = null;
        
        public String getAccountId() { return accountId; }
        public GetActiveCalls setAccountId(String value) { this.accountId = value; return this; }
    }

    public static class GetActiveCallsResponse
    {
        public ArrayList<CallInfo> calls = null;
        
        public ArrayList<CallInfo> getCalls() { return calls; }
        public GetActiveCallsResponse setCalls(ArrayList<CallInfo> value) { this.calls = value; return this; }
    }

    public static class CallInfo
    {
        public String accountSid = null;
        public String annotation = null;
        public String answeredBy = null;
        public String callerName = null;
        public String dateCreated = null;
        public String dateUpdated = null;
        public String direction = null;
        public Integer duration = null;
        public String endTime = null;
        public String forwardedFrom = null;
        public String from = null;
        public String fromFormatted = null;
        public String parentCallSid = null;
        public String phoneNumberSid = null;
        public BigDecimal price = null;
        public String priceUnit = null;
        public String sid = null;
        public String startTime = null;
        public String status = null;
        public String to = null;
        public String toFormatted = null;
        public String uri = null;
        
        public String getAccountSid() { return accountSid; }
        public CallInfo setAccountSid(String value) { this.accountSid = value; return this; }
        public String getAnnotation() { return annotation; }
        public CallInfo setAnnotation(String value) { this.annotation = value; return this; }
        public String getAnsweredBy() { return answeredBy; }
        public CallInfo setAnsweredBy(String value) { this.answeredBy = value; return this; }
        public String getCallerName() { return callerName; }
        public CallInfo setCallerName(String value) { this.callerName = value; return this; }
        public String getDateCreated() { return dateCreated; }
        public CallInfo setDateCreated(String value) { this.dateCreated = value; return this; }
        public String getDateUpdated() { return dateUpdated; }
        public CallInfo setDateUpdated(String value) { this.dateUpdated = value; return this; }
        public String getDirection() { return direction; }
        public CallInfo setDirection(String value) { this.direction = value; return this; }
        public Integer getDuration() { return duration; }
        public CallInfo setDuration(Integer value) { this.duration = value; return this; }
        public String getEndTime() { return endTime; }
        public CallInfo setEndTime(String value) { this.endTime = value; return this; }
        public String getForwardedFrom() { return forwardedFrom; }
        public CallInfo setForwardedFrom(String value) { this.forwardedFrom = value; return this; }
        public String getFrom() { return from; }
        public CallInfo setFrom(String value) { this.from = value; return this; }
        public String getFromFormatted() { return fromFormatted; }
        public CallInfo setFromFormatted(String value) { this.fromFormatted = value; return this; }
        public String getParentCallSid() { return parentCallSid; }
        public CallInfo setParentCallSid(String value) { this.parentCallSid = value; return this; }
        public String getPhoneNumberSid() { return phoneNumberSid; }
        public CallInfo setPhoneNumberSid(String value) { this.phoneNumberSid = value; return this; }
        public BigDecimal getPrice() { return price; }
        public CallInfo setPrice(BigDecimal value) { this.price = value; return this; }
        public String getPriceUnit() { return priceUnit; }
        public CallInfo setPriceUnit(String value) { this.priceUnit = value; return this; }
        public String getSid() { return sid; }
        public CallInfo setSid(String value) { this.sid = value; return this; }
        public String getStartTime() { return startTime; }
        public CallInfo setStartTime(String value) { this.startTime = value; return this; }
        public String getStatus() { return status; }
        public CallInfo setStatus(String value) { this.status = value; return this; }
        public String getTo() { return to; }
        public CallInfo setTo(String value) { this.to = value; return this; }
        public String getToFormatted() { return toFormatted; }
        public CallInfo setToFormatted(String value) { this.toFormatted = value; return this; }
        public String getUri() { return uri; }
        public CallInfo setUri(String value) { this.uri = value; return this; }
    }

}

Java GetActiveCalls DTOs

To override the Content-type in your clients, use the HTTP Accept Header, append the .xml suffix or ?format=xml

HTTP + XML

The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.

GET /calls/active HTTP/1.1 
Host: evovoice.io 
Accept: application/xml
HTTP/1.1 200 OK
Content-Type: application/xml
Content-Length: length

<GetActiveCallsResponse xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/Voice.Api.Dashboard">
  <Calls>
    <CallInfo>
      <AccountSid>String</AccountSid>
      <Annotation>String</Annotation>
      <AnsweredBy>String</AnsweredBy>
      <CallerName>String</CallerName>
      <DateCreated>String</DateCreated>
      <DateUpdated>String</DateUpdated>
      <Direction>String</Direction>
      <Duration>0</Duration>
      <EndTime>String</EndTime>
      <ForwardedFrom>String</ForwardedFrom>
      <From>String</From>
      <FromFormatted>String</FromFormatted>
      <ParentCallSid>String</ParentCallSid>
      <PhoneNumberSid>String</PhoneNumberSid>
      <Price>0</Price>
      <PriceUnit>String</PriceUnit>
      <Sid>String</Sid>
      <StartTime>String</StartTime>
      <Status>String</Status>
      <To>String</To>
      <ToFormatted>String</ToFormatted>
      <Uri>String</Uri>
    </CallInfo>
  </Calls>
</GetActiveCallsResponse>