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

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.Workspace

public class Workspace
extends NextGenInstanceResource<TwilioTaskRouterClient>

A Workspace is a container for your Tasks, Workers, TaskQueues, Workflows and Activities. Each of these items exists within a single Workspace and will not be shared across Workspaces.


Constructor Summary
Workspace(TwilioTaskRouterClient client)
          Instantiates a workspace.
Workspace(TwilioTaskRouterClient client, Map<String,Object> properties)
          Instantiates a workspace.
Workspace(TwilioTaskRouterClient client, String sid)
          Instantiates a workspace.
 
Method Summary
 String getAccountSid()
          The ID of the Account that owns this Workspace.
 ActivityList getActivities()
          Retrieves the ActivityList for this Workspace
 Activity getActivity(String activitySid)
          Retrieves an Activity from this Workspace by ID.
 Date getDateCreated()
          The date and time this Workspace was created.
 Date getDateUpdated()
          The date and time this Workspace was last updated.
 String getDefaultActivityName()
          The human-readable name of the default activity.
 String getDefaultActivitySid()
          The ID of the Activity that will be used when new Workers are created in this Workspace.
 Event getEvent(String eventSid)
          Retrieves an Event from this Workspace
 String getEventCallbackUrl()
          An optional URL where the Workspace will publish events.
 EventList getEvents()
          Retrieves the EventList for this Workspace
 String getFriendlyName()
          A human-readable description of this Workspace.
 String getSid()
          The unique ID for this Workspace.
 Task getTask(String taskSid)
          Retrieves a Task from this Workspace.
 TaskList getTasks()
          Retrieves the TaskList for this Workspace.
 String getTimeoutActivityName()
          The human-readable name of the timeout activity.
 String getTimeoutActivitySid()
          The ID of the Activity that will be assigned to a Worker when a Task reservation times out without a response.
 Worker getWorker(String workerSid)
          Retrieves a Worker from a Workspace
 WorkerList getWorkers()
          Retrieves the WorkerList for this Workspace
 Workflow getWorkflow(String workflowSid)
          Retrieves a Workflow from a Workspace
 WorkflowList getWorkflows()
          Retrieves the WorkflowList for this Workspace
 
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

Workspace

public Workspace(TwilioTaskRouterClient client)
Instantiates a workspace.

Parameters:
client - the client

Workspace

public Workspace(TwilioTaskRouterClient client,
                 Map<String,Object> properties)
Instantiates a workspace.

Parameters:
client - the client
properties - the properties

Workspace

public Workspace(TwilioTaskRouterClient client,
                 String sid)
Instantiates a workspace.

Parameters:
client - the client
sid - the sid
Method Detail

getAccountSid

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

Returns:
the account sid

getActivities

public ActivityList getActivities()
Retrieves the ActivityList for this Workspace

Returns:
the ActivityList

getActivity

public Activity getActivity(String activitySid)
Retrieves an Activity from this Workspace by ID.


getDateCreated

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

Returns:
the date created

getDateUpdated

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

Returns:
the date updated

getDefaultActivityName

public String getDefaultActivityName()
The human-readable name of the default activity. Read only.

Returns:
the default activity name

getDefaultActivitySid

public String getDefaultActivitySid()
The ID of the Activity that will be used when new Workers are created in this Workspace.

Returns:
the default activity sid

getEvent

public Event getEvent(String eventSid)
Retrieves an Event from this Workspace


getEvents

public EventList getEvents()
Retrieves the EventList for this Workspace

Returns:
the EventList

getEventCallbackUrl

public String getEventCallbackUrl()
An optional URL where the Workspace will publish events. You can use this to gather data for reporting.

Returns:
the event callback URL

getFriendlyName

public String getFriendlyName()
A human-readable description of this Workspace.

Returns:
the friendly name

getSid

public String getSid()
The unique ID for this Workspace.

Returns:
the sid

getTask

public Task getTask(String taskSid)
Retrieves a Task from this Workspace.


getTasks

public TaskList getTasks()
Retrieves the TaskList for this Workspace.

Returns:
the TaskList

getTimeoutActivityName

public String getTimeoutActivityName()
The human-readable name of the timeout activity. Read only.

Returns:
the timeout activity name

getTimeoutActivitySid

public String getTimeoutActivitySid()
The ID of the Activity that will be assigned to a Worker when a Task reservation times out without a response.

Returns:
the timeout activity sid

getWorker

public Worker getWorker(String workerSid)
Retrieves a Worker from a Workspace


getWorkers

public WorkerList getWorkers()
Retrieves the WorkerList for this Workspace

Returns:
the WorkerList

getWorkflow

public Workflow getWorkflow(String workflowSid)
Retrieves a Workflow from a Workspace


getWorkflows

public WorkflowList getWorkflows()
Retrieves the WorkflowList for this Workspace

Returns:
the WorkflowList


Copyright © 2011 Twilio, Inc. All Rights Reserved.