Package com.twilio.jwt.accesstoken
Class VoiceGrant
- java.lang.Object
-
- com.twilio.jwt.accesstoken.VoiceGrant
-
- All Implemented Interfaces:
Grant
public class VoiceGrant extends Object implements Grant
Grant used to access Twilio VoiceFor more information see: https://www.twilio.com/docs/api/rest/access-tokens
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description class
VoiceGrant.Payload
-
Constructor Summary
Constructors Constructor Description VoiceGrant()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description String
getGrantKey()
The key for the grant.Object
getPayload()
The payload for this grant.VoiceGrant
setEndpointId(String endpointId)
VoiceGrant
setIncomingAllow(Boolean incomingAllow)
VoiceGrant
setOutgoingApplication(String outgoingApplicationSid, Map<String,Object> outgoingApplicationParams)
Set the outgoing application.VoiceGrant
setOutgoingApplicationSid(String outgoingApplicationSid)
VoiceGrant
setPushCredentialSid(String pushCredentialSid)
-
-
-
Method Detail
-
setIncomingAllow
public VoiceGrant setIncomingAllow(Boolean incomingAllow)
-
setOutgoingApplicationSid
public VoiceGrant setOutgoingApplicationSid(String outgoingApplicationSid)
-
setOutgoingApplication
public VoiceGrant setOutgoingApplication(String outgoingApplicationSid, Map<String,Object> outgoingApplicationParams)
Set the outgoing application.- Parameters:
outgoingApplicationSid
- outgoing application sidoutgoingApplicationParams
- outgoing application parameters- Returns:
- voice grant
-
setPushCredentialSid
public VoiceGrant setPushCredentialSid(String pushCredentialSid)
-
setEndpointId
public VoiceGrant setEndpointId(String endpointId)
-
getGrantKey
public String getGrantKey()
Description copied from interface:Grant
The key for the grant.- Specified by:
getGrantKey
in interfaceGrant
- Returns:
- The key for the grant.
-
getPayload
public Object getPayload()
Description copied from interface:Grant
The payload for this grant.The payload allows us to decouple the user API from how the grant is structured.
- Specified by:
getPayload
in interfaceGrant
- Returns:
- The payload for this grant.
-
-