Copyright | (c) 2013-2021 Brendan Hay |
---|---|
License | Mozilla Public License, v. 2.0. |
Maintainer | Brendan Hay <brendan.g.hay+amazonka@gmail.com> |
Stability | auto-generated |
Portability | non-portable (GHC extensions) |
Safe Haskell | None |
Creates the participant's connection. Note that ParticipantToken is used for invoking this API instead of ConnectionToken.
The participant token is valid for the lifetime of the participant – until they are part of a contact.
The response URL for WEBSOCKET
Type has a connect expiry timeout of
100s. Clients must manually connect to the returned websocket URL and
subscribe to the desired topic.
For chat, you need to publish the following on the established websocket connection:
{"topic":"aws/subscribe","content":{"topics":["aws/chat"]}}
Upon websocket URL expiry, as specified in the response ConnectionExpiry parameter, clients need to call this API again to obtain a new websocket URL and perform the same steps as before.
The Amazon Connect Participant Service APIs do not use Signature Version 4 authentication.
Synopsis
- data CreateParticipantConnection = CreateParticipantConnection' {}
- newCreateParticipantConnection :: NonEmpty ConnectionType -> Text -> CreateParticipantConnection
- createParticipantConnection_type :: Lens' CreateParticipantConnection (NonEmpty ConnectionType)
- createParticipantConnection_participantToken :: Lens' CreateParticipantConnection Text
- data CreateParticipantConnectionResponse = CreateParticipantConnectionResponse' {}
- newCreateParticipantConnectionResponse :: Int -> CreateParticipantConnectionResponse
- createParticipantConnectionResponse_connectionCredentials :: Lens' CreateParticipantConnectionResponse (Maybe ConnectionCredentials)
- createParticipantConnectionResponse_websocket :: Lens' CreateParticipantConnectionResponse (Maybe Websocket)
- createParticipantConnectionResponse_httpStatus :: Lens' CreateParticipantConnectionResponse Int
Creating a Request
data CreateParticipantConnection Source #
See: newCreateParticipantConnection
smart constructor.
CreateParticipantConnection' | |
|
Instances
newCreateParticipantConnection Source #
Create a value of CreateParticipantConnection
with all optional fields omitted.
Use generic-lens or optics to modify other optional fields.
The following record fields are available, with the corresponding lenses provided for backwards compatibility:
$sel:type':CreateParticipantConnection'
, createParticipantConnection_type
- Type of connection information required.
$sel:participantToken:CreateParticipantConnection'
, createParticipantConnection_participantToken
- This is a header parameter.
The Participant Token as obtained from StartChatContact API response.
Request Lenses
createParticipantConnection_type :: Lens' CreateParticipantConnection (NonEmpty ConnectionType) Source #
Type of connection information required.
createParticipantConnection_participantToken :: Lens' CreateParticipantConnection Text Source #
This is a header parameter.
The Participant Token as obtained from StartChatContact API response.
Destructuring the Response
data CreateParticipantConnectionResponse Source #
See: newCreateParticipantConnectionResponse
smart constructor.
CreateParticipantConnectionResponse' | |
|
Instances
newCreateParticipantConnectionResponse Source #
Create a value of CreateParticipantConnectionResponse
with all optional fields omitted.
Use generic-lens or optics to modify other optional fields.
The following record fields are available, with the corresponding lenses provided for backwards compatibility:
$sel:connectionCredentials:CreateParticipantConnectionResponse'
, createParticipantConnectionResponse_connectionCredentials
- Creates the participant's connection credentials. The authentication
token associated with the participant's connection.
$sel:websocket:CreateParticipantConnectionResponse'
, createParticipantConnectionResponse_websocket
- Creates the participant's websocket connection.
$sel:httpStatus:CreateParticipantConnectionResponse'
, createParticipantConnectionResponse_httpStatus
- The response's http status code.
Response Lenses
createParticipantConnectionResponse_connectionCredentials :: Lens' CreateParticipantConnectionResponse (Maybe ConnectionCredentials) Source #
Creates the participant's connection credentials. The authentication token associated with the participant's connection.
createParticipantConnectionResponse_websocket :: Lens' CreateParticipantConnectionResponse (Maybe Websocket) Source #
Creates the participant's websocket connection.
createParticipantConnectionResponse_httpStatus :: Lens' CreateParticipantConnectionResponse Int Source #
The response's http status code.