The following are Apex classes for the Slack calls API methods. These classes enable you to integrate your calls with Slack using the Calls API.
Call Class
Represents a call on Slack.
Call Methods
The following are methods for Call.
getChannels()
Gets the channel that initiated the call.
Signature
public List<String> getChannels()
Return Value
Type: List<String>
getDateEnd()
Gets the call end time in UTC UNIX timestamp format.
Signature
public Integer getDateEnd()
Return Value
Type: Integer
getDateStart()
Gets the call start time in UTC UNIX timestamp format.
Signature
public Integer getDateStart()
Return Value
Type: Integer
getDesktopAppJoinUrl()
Gets the Slack clients that launched the call. For example, callapp://join/0987654321.
Signature
public String getDesktopAppJoinUrl()
Return Value
Type: String
getExternalDisplayId()
Gets the external display ID. For example, 705-292-868.
Signature
public String getExternalDisplayId()
Return Value
Type: String
getExternalUniqueId()
Gets the unique ID created by your app for your users.
Signature
public String getExternalUniqueId()
Return Value
Type: String
getId()
Gets the call ID.
Signature
public String getId()
Return Value
Type: String
getJoinUrl()
Gets the URL required for a client to join the call.
Signature
public String getJoinUrl()
Return Value
Type: String
getTitle()
Gets the name of the call.
Signature
public String getTitle()
Return Value
Type: String
getUsers()
Gets a list of call participants.
Signature
public List<Slack.CallParticipant> getUsers()
Return Value
Type: List<Slack.CallParticipant>
setChannels(channels)
Sets the channel that initiates the call.
Signature
public void setChannels(List<String> channels)
Parameters
channels
Type: List<String>
Return Value
Type: void
setDateEnd(dateEnd)
Sets the call end time in UTC UNIX timestamp format.
Signature
public void setDateEnd(Integer dateEnd)
Parameters
dateEnd
Type: Integer
Return Value
Type: void
setDateStart(dateStart)
Sets the call start time in UTC UNIX timestamp format.
Signature
public void setDateStart(Integer dateStart)
Parameters
dateStart
Type: Integer
Return Value
Type: void
setDesktopAppJoinUrl(desktopAppJoinUrl)
Sets the Slack clients that launched the call. For example, callapp://join/0987654321.
Signature
public void setDesktopAppJoinUrl(String desktopAppJoinUrl)
Parameters
desktopAppJoinUrl
Type: String
Return Value
Type: void
setExternalDisplayId(externalDisplayId)
Sets the external display ID.
Signature
public void setExternalDisplayId(String externalDisplayId)
Parameters
externalDisplayId
Type: String
Return Value
Type: void
setExternalUniqueId(externalUniqueId)
Sets the unique ID created by your app for your users.
Signature
public void setExternalUniqueId(String externalUniqueId)
Parameters
externalUniqueId
Type: String
Return Value
Type: void
setId(id)
Sets the call ID.
Signature
public void setId(String id)
Parameters
id
Type: String
Return Value
Type: void
setJoinUrl(joinUrl)
Sets the URL required for a client to join the call.
Signature
public void setJoinUrl(String joinUrl)
Parameters
joinUrl
Type: String
Return Value
Type: void
setTitle(title)
Sets the name of the call.
Signature
public void setTitle(String title)
Parameters
title
Type: String
Return Value
Type: void
setUsers(users)
Sets the call participants.
Signature
public void setUsers(List<Slack.CallParticipant> users)
Parameters
users
Type: List<Slack.CallParticipant>
Return Value
Type: void
CallParticipant Class
Represent a user on a call.
CallParticipant Class
The following are methods for CallParticipant.
getAvatarUrl()
Gets the URL for the call participant's avatar.
Signature
public String getAvatarUrl()
Return Value
Type: String
getDisplayName()
Gets the display name for the call participant.
Signature
public String getDisplayName()
Return Value
Type: String
getExternalId()
Gets the external ID for the call participant. The external ID is a unique ID that your app creates for your users.
Signature
public String getExternalId()
Return Value
Type: String
getSlackId()
Gets the Slack ID for the call participant.
Signature
public String getSlackId()
Return Value
Type: String
setAvatarUrl(avatarUrl)
Sets the URL for the call participant's avatar.
Signature
public void setAvatarUrl(String avatarUrl)
Parameters
avatarUrl
Type: String
Return Value
Type: void
setDisplayName(displayName)
Sets the display name for the call participant.
Signature
public void setDisplayName(String displayName)
Parameters
displayName
Type: String
Return Value
Type: void
setExternalId(externalId)
Sets the external ID for the call participant.
Signature
public void setExternalId(String externalId)
Parameters
externalId
Type: String
Return Value
Type: void
setSlackId(slackId)
Sets the Slack ID for the call participant.
Signature
public void setSlackId(String slackId)
Parameters
slackId
Type: String
Return Value
Type: void
CallsAddRequest Class
Sends a request to register a new call.
Usage
See Slack's calls.add method.
CallsAddRequest Methods
The following are methods for CallsAddRequest.
builder()
Builds a request object that's used when executing the API call.
Signature
public static Slack.CallsAddRequest.Builder builder()
Return Value
Type: Slack.CallsAddRequest.Builder
CallsAddRequest.Builder Class
Contains methods to build an instance of the Slack.CallsAddRequest class.
A Builder object is obtained by invoking one of the CallsAddRequest.Builder methods defined by the CallsAddRequest class.
CallsAddRequest.Builder Methods
The following are methods for CallsAddRequest.Builder. These methods are optional unless specified otherwise.
build()
Required. Builds an instance of the Slack.CallsAddRequest class.
Signature
public Slack.CallsAddRequest build()
Return Value
Type: Slack.CallsAddRequest
createdBy(createdBy)
The Slack user ID of the user who created the call. When this method is called with a user token, createdBy is optional and defaults to the authenticated user of the token. Otherwise, the field is required.
Signature
public Slack.CallsAddRequest.Builder createdBy(String createdBy)
Parameters
createdBy
Type: String
Return Value
Type: Slacks.CallsAddRequest.Builder
dateStart(dateStart)
Call start time in UTC UNIX timestamp format.
Signature
public Slack.CallsAddRequest.Builder dateStart(Integer dateStart)
Parameters
dateStart
Type: Integer
Return Value
Type: Slack.CallsAddRequest.Builder
desktopAppJoinUrl(desktopAppJoinUrl)
The URL that's used to launch the 3rd-party call for the Slack clients.
Signature
public Slack.CallsAddRequest.Builder desktopAppJoinUrl(String desktopAppJoinUrl)
Parameters
desktopAppJoinUrl
Type: String
Return Value
Type: Slack.CallsAddRequest.Builder
externalDisplayId(externalDisplayId)
An optional ID supplied by the 3rd-party call provider. This ID is displayed in the call object.
Signature
public Slack.CallsAddRequest.Builder externalDisplayId(String externalDisplayId)
Parameters
externalDisplayId
Type: String
Return Value
Type: Slack.CallsAddRequest.Builder
externalUniqueId(externalUniqueId)
Required. An ID supplied by the 3rd-party call provider. It must be unique across all calls from that service.
Signature
public Slack.CallsAddRequest.Builder externalUniqueId(String externalUniqueId)
Parameters
externalUniqueId
Type: String
Return Value
Type: Slack.CallsAddRequest.Builder
joinUrl(joinUrl)
Required. The URL required for a client to join the call.
Signature
joinUrl
Type: String
Return Value
Type: Slack.CallsAddRequest.Builder
title(title)
The name for the call, which can be a short description.
Signature
public Slack.CallsAddRequest.Builder title(String title)
Parameters
title
Type: String
Return Value
Type: Slack.CallsAddRequest.Builder
users(users)
The list of call participants.
Signature
public Slack.CallsAddRequest.Builder users(List<Slack.CallParticipant> users)
Parameters
users
Type: List<Slack.CallParticipant>
Return Value
Type: Slack.CallsAddRequest.Builder
CallsAddResponse Class
Registers a new call.
CallsAddResponse Method
This class contains standard response methods.
The following are methods for CallsAddResponse.
getCall()
Gets information about the call.
Signature
public Slack.Call getCall()
Return Value
Type: Slack.Call
getResponseMetadata()
Signature
public Slack.ResponseMetadata getResponseMetadata()
Return Value
Type: Slack.ResponseMetadata
setCall(call)
Sets a call to be registered. setCall registers the details of the call with Slack.
Signature
public void setCall(Slack.Call call)
Parameters
call
Type: Slack.Call
Return Value
Type: void
setResponseMetadata(responseMetadata)
Signature
public void setResponseMetadata(Slack.ResponseMetadata responseMetadata)
Parameters
responseMetadata
Type: Slack.ResponseMetadata
Return Value
Type: void
CallsEndRequest Class
Sends a request to end a call.
Usage
See Slack's calls.add method.
CallsEndRequest Methods
The following are methods for CallsEndRequest.
builder()
Builds a request object that's used when executing the API call.
Signature
public static Slack.CallsEndRequest.Builder builder()
Return Value
Type: Slack.CallsEndRequest.Builder
CallsEndRequest.Builder Class
Contains methods to build an instance of the Slack.CallsEndRequest class.
A Builder object is obtained by invoking one of the CallsEndRequest.Builder methods defined by the CallsEndRequest class.
CallsEndRequest.Builder Methods
The following are methods for CallsEndRequest.Builder. These methods are optional unless specified otherwise.
build()
Required. Returns an instance of the Slack.CallsEndRequest object.
Signature
public Slack.CallsEndRequest build()
Return Value
Type: Slack.CallsEndRequest
duration(duration)
Call duration in seconds.
Signature
public Slack.CallsEndRequest.Builder duration(Integer duration)
Parameters
duration
Type: Integer
Return Value
Type: Slack.CallsEndRequest.Builder
id(id)
Required. The ID that's returned when registering a call using CallsAddRequest.
Signature
public Slack.CallsEndRequest.Builder id(String id)
Parameters
id
Type: String
Return Value
Type: Slack.CallsEndRequest.Builder
CallsEndResponse Class
Ends a call.
CallsEndResponse Methods
This class contains standard response methods.
The following are methods for CallsEndResponse.
getCall()
Gets information about the call.
Signature
public Slack.Call getCall()
Return Value
Type: Slack.Call
getResponseMetadata()
Signature
public Slack.ResponseMetadata getResponseMetadata()
Return Value
Type: Slack.ResponseMetadata
setCall(call)
Sets the call to be terminated.
Signature
public void setCall(Slack.Call call)
Parameters
call
Type: Slack.Call
Return Value
Type: void
setResponseMetadata(responseMetadata)
Signature
public void setResponseMetadata(Slack.ResponseMetadata responseMetadata)
Parameters
responseMetadata
Type: Slack.ResponseMetadata
Return Value
Type: void
CallsInfoRequest Class
Sends a request to return information about a call.
Usage
See Slack's calls.info method.
CallsInfoRequest Methods
The following are methods for CallsInfoRequest.
builder()
Builds a request object that's used when executing the API call.
Signature
public static Slack.CallsInfoRequest.Builder builder()
Return Value
Type: Slack.CallsInfoRequest.Builder
CallsInfoRequest.Builder Class
Contains methods to build an instance of the Slack.CallsInfoRequest class.
A Builder object is obtained by invoking one of the CallsInfoRequest.Builder methods defined by the CallsInfoRequest class.
CallsInfoRequest.Builder Methods
The following are methods for CallsInfoRequest.Builder. These methods are optional unless specified otherwise.
build()
Required. Returns an instance of the Slack.CallsInfoRequesxt object.
Signature
public Slack.CallsInfoRequest build()
Return Value
Type: Slack.CallsInfoRequest
id(id)
Required. The ID of the call that's returned by CallsAddRequest.
Signature
public Slack.CallsInfoRequest.Builder id(String id)
Parameters
id
Type: String
Return Value
Type: Slack.CallsInfoRequest.Builder
CallsInfoResponse Class
Returns information about a call.
CallsInfoResponse Methods
This class contains standard response methods.
The following are methods for CallsInfoResponse.
getCall()
Gets information about the call.
Signature
public Slack.Call getCall()
Return Value
Type: Slack.Call
getResponseMetadata()
Signature
public Slack.ResponseMetadata getResponseMetadata()
Return Value
Type: Slack.ResponseMetadata
setCall(call)
Sets the call from which to get information.
Signature
public void setCall(Slack.Call call)
Parameters
call
Type: Slack.Call
Return Value
Type: void
setResponseMetadata(responseMetadata)
Signature
public void setResponseMetadata(Slack.ResponseMetadata responseMetadata)
Parameters
responseMetadata
Type: Slack.ResponseMetadata
Return Value
Type: void
CallsParticipantsAddRequest Class
Sends a request to register new participants that are added to a call.
Usage
See Slack's calls.participants.add method.
CallsParticipantsAddRequest Methods
The following are methods for CallsParticipantsAddRequest.
builder()
Builds a request object that's used when executing the API call.
Signature
public static Slack.CallsParticipantsAddRequest.Builder builder()
Return Value
Type: Slack.CallsParticipantsAddRequest.Builder
CallsParticipantsAddRequest.Builder Class
Contains methods to build an instance of the Slack.CallsParticipantsAddRequest class.
A Builder object is obtained by invoking one of the CallsParticipantsAddRequest.Builder methods defined by the CallsParticipantsAddRequest class.
CallsParticipantsAddRequest.Builder Methods
The following are methods for CallsParticipantsAddRequest.Builder.
build()
Required. Returns an instance of the Slack.CallsParticipantsAddRequest object.
Signature
public Slack.CallsParticipantsAddRequest build()
Return Value
Type: Slack.CallsParticipantsAddRequest
id(id)
Required. The ID that's returned by CallsAddRequest.
Signature
public Slack.CallsParticipantsAddRequest.Builder id(String id)
Parameters
id
Type: String
Return Value
Type: Slack.CallsParticipantsAddRequest.Builder
users(users)
Required. The list of users to add as participants in the call.
Signature
public Slack.CallsParticipantsAddRequest.Builder users(List<Slack.CallParticipant> users)
Parameters
users
Type: List<Slack.CallParticipant>
Return Value
Type: Slack.CallsParticipantsAddRequest.Builder
CallsParticipantsAddResponse Class
Registers new participants that are added to a call.
CallsParticipantsAddResponse Methods
This class contains standard response methods.
The following are methods for CallsParticipantsAddResponse.
getCall()
Gets information about the call.
Signature
public Slack.Call getCall()
Return Value
Type: Slack.Call
getResponseMetadata()
Signature
public Slack.ResponseMetadata getResponseMetadata()
Return Value
Type: Slack.ResponseMetadata
setCall(call)
Sets the call for which to register new participants.
Signature
public void setCall(Slack.Call call)
Parameters
call
Type: Slack.Call
Return Value
Type: void
setResponseMetadata(responseMetadata)
Signature
public void setResponseMetadata(Slack.ResponseMetadata responseMetadata)
Parameters
responseMetadata
Type: Slack.ResponseMetadata
Return Value
Type: void
CallsParticipantsRemoveRequest Class
Sends a request to remove participants in the call.
Usage
See Slack's calls.participants.remove method.
CallsParticipantsRemoveRequest Methods
The following are methods for CallsParticipantsRemoveRequest.
builder()
Builds a request object that's used when executing the API call.
Signature
public static Slack.CallsParticipantsRemoveRequest.Builder builder()
Return Value
Type: Type: Slack.CallsParticipantsRemoveRequest.Builder
CallsParticipantsRemoveRequest.Builder Class
Contains methods to build an instance of the Slack.CallsParticipantsRemoveRequest class.
A Builder object is obtained by invoking one of the CallsParticipantsRemoveRequest.Builder methods defined by the CallsParticipantsRemoveRequest class.
CallsParticipantsRemoveRequest.Builder Methods
The following are methods for CallsParticipantsRemoveRequest.Builder.
build()
Required. Returns an instance of the Slack.CallsParticipantsRemoveRequest object.
Signature
public Slack.CallsParticipantsRemoveRequest build()
Return Value
Type: Slack.CallsParticipantsRemoveRequest
id(id)
Required. The ID that's returned by CallsAddRequest.
Signature
public Slack.CallsParticipantsRemoveRequest.Builder id(String id)
Parameters
id
Type: String
Return Value
Type: Type: Slack.CallsParticipantsRemoveRequest.Builder
users(users)
Required. The list of users to remove as participants in the call.
Signature
public Slack.CallsParticipantsRemoveRequest.Builder users(List<Slack.CallParticipant> users)
Parameters
users
Type: List<Slack.CallParticipant>
Return Value
Type: Slack.CallsParticipantsRemoveRequest.Builder
CallsParticipantsRemoveResponse Class
Registers participants removed from a Call.
CallsParticipantsRemoveResponse Methods
This class contains standard response methods.
The following are methods for CallsParticipantsRemoveResponse.
getCall()
Gets information about the call.
Signature
public Slack.Call getCall()
Return Value
Type: Slack.Call
getResponseMetadata()
Signature
public Slack.ResponseMetadata getResponseMetadata()
Return Value
Type: Slack.ResponseMetadata
setCall(call)
Sets the call from which to remove participants.
Signature
public void setCall(Slack.Call call)
Parameters
call
Type: Slack.Call
Return Value
Type: void
setResponseMetadata(responseMetadata)
Signature
public void setResponseMetadata(Slack.ResponseMetadata responseMetadata)
Parameters
responseMetadata
Type: Slack.ResponseMetadata
Return Value
Type: void
CallsUpdateRequest Class
Sends a request to update information about a call.
CallsUpdateRequest Methods
The following are methods for CallsUpdateRequest.
builder()
Signature
public static Slack.CallsUpdateRequest.Builder builder()
Return Value
Type: Slack.CallsUpdateRequest.Builder
CallsUpdateRequest.Builder Class
Contains methods to build an instance of the Slack.CallsUpdateRequest class.
A Builder object is obtained by invoking one of the CallsUpdateRequest.Builder methods defined by the CallsUpdateRequest class.
CallsUpdateRequest.Builder Methods
The following are methods for CallsUpdateRequest.Builder. These methods are optional unless specified otherwise.
build()
Required. Returns an instance of the Slack.CallsUpdateRequest object.
Signature
public Slack.CallsUpdateRequest build()
Return Value
Type: Slack.CallsUpdateRequest
desktopAppJoinUrl(desktopAppJoinUrl)
Signature
public Slack.CallsUpdateRequest.Builder desktopAppJoinUrl(String desktopAppJoinUrl)
Parameters
desktopAppJoinUrl
Type: String
Return Value
Type: Slack.CallsUpdateRequest.Builder
id(id)
Required. The ID that's returned by CallsAddRequest.
Signature
public Slack.CallsUpdateRequest.Builder id(String id)
Parameters
id
Type: String
Return Value
Type: Slack.CallsUpdateRequest.Builder
joinUrl(joinUrl)
Signature
public Slack.CallsUpdateRequest.Builder joinUrl(String joinUrl)
Parameters
joinUrl
Type: String
Return Value
Type: Slack.CallsUpdateRequest.Builder
title(title)
Signature
public Slack.CallsUpdateRequest.Builder title(String title)
Parameters
title
Type: String
Return Value
Type: Slack.CallsUpdateRequest.Builder
CallsUpdateResponse Class
Updates information about a call.
CallsUpdateResponse Methods
This class contains standard response methods.
The following are methods for CallsUpdateResponse.
getCall()
Gets information about the call.
Signature
public Slack.Call getCall()
Return Value
Type: Slack.Call
getResponseMetadata()
Signature
public Slack.ResponseMetadata getResponseMetadata()
Return Value
Type: Slack.ResponseMetadata
setCall(call)
Sets the call for which to update information.
Signature
public void setCall(Slack.Call call)
Parameters
call
Type: Slack.Call
Return Value
Type: void
setResponseMetadata(responseMetadata)
Signature
public void setResponseMetadata(Slack.ResponseMetadata responseMetadata)
Parameters
responseMetadata
Type: Slack.ResponseMetadata
Return Value
Type: void