com.twilio.sdk.resource.instance.taskrouter
Class Reservation

java.lang.Object
  extended by com.twilio.sdk.resource.Resource<C>
      extended by com.twilio.sdk.resource.InstanceResource<C>
          extended by com.twilio.sdk.resource.NextGenInstanceResource<TwilioTaskRouterClient>
              extended by com.twilio.sdk.resource.instance.taskrouter.Reservation

public class Reservation
extends NextGenInstanceResource<TwilioTaskRouterClient>

The Reservation subresource of Task is created whenever a Task is assigned to a Worker. TaskRouter will provide the details of this Reservation instance subresource in the Assignment Callback HTTP request it makes to your application server. See the TaskRouter documentation.


Constructor Summary
Reservation(TwilioTaskRouterClient client)
          Instantiates a reservation.
Reservation(TwilioTaskRouterClient client, Map<String,Object> properties)
          Instantiates a reservation.
Reservation(TwilioTaskRouterClient client, String workspaceSid, String taskSid, String reservationSid)
          Instantiates a reservation.
 
Method Summary
 String getAccountSid()
          The unique ID of the Account that owns this Reservation.
 Date getDateCreated()
          The date and time this Reservation was created.
 Date getDateUpdated()
          The date and time this Reservation was last updated.
 String getReservationStatus()
          The current status of this Reservation.
 String getSid()
          The unique ID of this Reservation.
 String getTaskSid()
          The unique ID of the Task this Reservation was created for.
 String getWorkerName()
          The FriendlyName of the reserved Worker.
 String getWorkerSid()
          The unique ID of the reserved Worker
 String getWorkspaceSid()
          The unique ID of the Workspace containing this Reservation.
 
Methods inherited from class com.twilio.sdk.resource.InstanceResource
getObject, getProperty, update, update
 
Methods inherited from class com.twilio.sdk.resource.Resource
setRequestAccountSid
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Reservation

public Reservation(TwilioTaskRouterClient client)
Instantiates a reservation.

Parameters:
client - the client

Reservation

public Reservation(TwilioTaskRouterClient client,
                   Map<String,Object> properties)
Instantiates a reservation.

Parameters:
client - the client
properties - the properties

Reservation

public Reservation(TwilioTaskRouterClient client,
                   String workspaceSid,
                   String taskSid,
                   String reservationSid)
Instantiates a reservation.

Parameters:
client - the client
workspaceSid - the workspace sid
taskSid - the task sid
reservationSid - the reservation sid
Method Detail

getAccountSid

public String getAccountSid()
The unique ID of the Account that owns this Reservation.

Returns:
the account sid

getDateCreated

public Date getDateCreated()
The date and time this Reservation was created.

Returns:
the date created

getDateUpdated

public Date getDateUpdated()
The date and time this Reservation was last updated.

Returns:
the date updated

getReservationStatus

public String getReservationStatus()
The current status of this Reservation. One of "pending", "accepted", "rejected", or "timeout".

Returns:
the reservation status

getSid

public String getSid()
The unique ID of this Reservation.

Returns:
the sid

getTaskSid

public String getTaskSid()
The unique ID of the Task this Reservation was created for.

Returns:
the task sid

getWorkerName

public String getWorkerName()
The FriendlyName of the reserved Worker.

Returns:
the worker name

getWorkerSid

public String getWorkerSid()
The unique ID of the reserved Worker

Returns:
the worker sid

getWorkspaceSid

public String getWorkspaceSid()
The unique ID of the Workspace containing this Reservation.

Returns:
the workspace sid


Copyright © 2011 Twilio, Inc. All Rights Reserved.