All URIs are relative to https://api.smooch.io
Method | HTTP request | Description |
---|---|---|
create_webhook | POST /v2/apps/{appId}/integrations/{integrationId}/webhooks | Create Webhook |
delete_webhook | DELETE /v2/apps/{appId}/integrations/{integrationId}/webhooks/{webhookId} | Delete Webhook |
get_webhook | GET /v2/apps/{appId}/integrations/{integrationId}/webhooks/{webhookId} | Get Webhook |
list_webhooks | GET /v2/apps/{appId}/integrations/{integrationId}/webhooks | List Webhooks |
update_webhook | PATCH /v2/apps/{appId}/integrations/{integrationId}/webhooks/{webhookId} | Update Webhook |
WebhookResponse create_webhook(app_id, integration_id, webhook_create_body)
Create Webhook
Creates a new webhook associated with a Sunshine Conversations Connect integration or a custom integration.
# load the gem
require 'sunshine-conversations-client'
# setup authorization
SunshineConversationsClient.configure do |config|
# Configure HTTP basic authorization: basicAuth
config.username = 'YOUR_USERNAME'
config.password = 'YOUR_PASSWORD'
# Configure Bearer authorization (JWT): bearerAuth
# Uncomment this line to use JWTs
# config.access_token = 'YOUR_JWT'
end
api_instance = SunshineConversationsClient::WebhooksApi.new
app_id = '5d8cff3cd55b040010928b5b' # String | Identifies the app.
integration_id = '029c31f25a21b47effd7be90' # String | The id of the integration.
webhook_create_body = SunshineConversationsClient::WebhookCreateBody.new # WebhookCreateBody |
# Be sure to add the required body parameters
begin
#Create Webhook
result = api_instance.create_webhook(app_id, integration_id, webhook_create_body)
p result
rescue SunshineConversationsClient::ApiError => e
puts "Exception when calling WebhooksApi->create_webhook: #{e}"
end
Name | Type | Description | Notes |
---|---|---|---|
app_id | String | Identifies the app. | |
integration_id | String | The id of the integration. | |
webhook_create_body | WebhookCreateBody |
- Content-Type: application/json
- Accept: application/json
Object delete_webhook(app_id, integration_id, webhook_id)
Delete Webhook
Deletes the specified webhook associated with a Sunshine Conversations Connect integration or a custom integration.
# load the gem
require 'sunshine-conversations-client'
# setup authorization
SunshineConversationsClient.configure do |config|
# Configure HTTP basic authorization: basicAuth
config.username = 'YOUR_USERNAME'
config.password = 'YOUR_PASSWORD'
# Configure Bearer authorization (JWT): bearerAuth
# Uncomment this line to use JWTs
# config.access_token = 'YOUR_JWT'
end
api_instance = SunshineConversationsClient::WebhooksApi.new
app_id = '5d8cff3cd55b040010928b5b' # String | Identifies the app.
integration_id = '029c31f25a21b47effd7be90' # String | The id of the integration.
webhook_id = '029c31f25a21b47effd7be90' # String | The id of the webhook.
# Be sure to add the required body parameters
begin
#Delete Webhook
result = api_instance.delete_webhook(app_id, integration_id, webhook_id)
p result
rescue SunshineConversationsClient::ApiError => e
puts "Exception when calling WebhooksApi->delete_webhook: #{e}"
end
Name | Type | Description | Notes |
---|---|---|---|
app_id | String | Identifies the app. | |
integration_id | String | The id of the integration. | |
webhook_id | String | The id of the webhook. |
Object
- Content-Type: Not defined
- Accept: application/json
WebhookResponse get_webhook(app_id, integration_id, webhook_id)
Get Webhook
Gets the specified webhook associated with a Sunshine Conversations Connect integration or a custom integration.
# load the gem
require 'sunshine-conversations-client'
# setup authorization
SunshineConversationsClient.configure do |config|
# Configure HTTP basic authorization: basicAuth
config.username = 'YOUR_USERNAME'
config.password = 'YOUR_PASSWORD'
# Configure Bearer authorization (JWT): bearerAuth
# Uncomment this line to use JWTs
# config.access_token = 'YOUR_JWT'
end
api_instance = SunshineConversationsClient::WebhooksApi.new
app_id = '5d8cff3cd55b040010928b5b' # String | Identifies the app.
integration_id = '029c31f25a21b47effd7be90' # String | The id of the integration.
webhook_id = '029c31f25a21b47effd7be90' # String | The id of the webhook.
# Be sure to add the required body parameters
begin
#Get Webhook
result = api_instance.get_webhook(app_id, integration_id, webhook_id)
p result
rescue SunshineConversationsClient::ApiError => e
puts "Exception when calling WebhooksApi->get_webhook: #{e}"
end
Name | Type | Description | Notes |
---|---|---|---|
app_id | String | Identifies the app. | |
integration_id | String | The id of the integration. | |
webhook_id | String | The id of the webhook. |
- Content-Type: Not defined
- Accept: application/json
WebhookListResponse list_webhooks(app_id, integration_id)
List Webhooks
Lists all webhooks for a given Sunshine Conversations Connect integration or custom integration.
# load the gem
require 'sunshine-conversations-client'
# setup authorization
SunshineConversationsClient.configure do |config|
# Configure HTTP basic authorization: basicAuth
config.username = 'YOUR_USERNAME'
config.password = 'YOUR_PASSWORD'
# Configure Bearer authorization (JWT): bearerAuth
# Uncomment this line to use JWTs
# config.access_token = 'YOUR_JWT'
end
api_instance = SunshineConversationsClient::WebhooksApi.new
app_id = '5d8cff3cd55b040010928b5b' # String | Identifies the app.
integration_id = '029c31f25a21b47effd7be90' # String | The id of the integration.
# Be sure to add the required body parameters
begin
#List Webhooks
result = api_instance.list_webhooks(app_id, integration_id)
p result
rescue SunshineConversationsClient::ApiError => e
puts "Exception when calling WebhooksApi->list_webhooks: #{e}"
end
Name | Type | Description | Notes |
---|---|---|---|
app_id | String | Identifies the app. | |
integration_id | String | The id of the integration. |
- Content-Type: Not defined
- Accept: application/json
WebhookResponse update_webhook(app_id, integration_id, webhook_id, webhook_body)
Update Webhook
Updates the specified webhook associated with a Sunshine Conversations Connect integration or a custom integration.
# load the gem
require 'sunshine-conversations-client'
# setup authorization
SunshineConversationsClient.configure do |config|
# Configure HTTP basic authorization: basicAuth
config.username = 'YOUR_USERNAME'
config.password = 'YOUR_PASSWORD'
# Configure Bearer authorization (JWT): bearerAuth
# Uncomment this line to use JWTs
# config.access_token = 'YOUR_JWT'
end
api_instance = SunshineConversationsClient::WebhooksApi.new
app_id = '5d8cff3cd55b040010928b5b' # String | Identifies the app.
integration_id = '029c31f25a21b47effd7be90' # String | The id of the integration.
webhook_id = '029c31f25a21b47effd7be90' # String | The id of the webhook.
webhook_body = SunshineConversationsClient::WebhookBody.new # WebhookBody |
# Be sure to add the required body parameters
begin
#Update Webhook
result = api_instance.update_webhook(app_id, integration_id, webhook_id, webhook_body)
p result
rescue SunshineConversationsClient::ApiError => e
puts "Exception when calling WebhooksApi->update_webhook: #{e}"
end
Name | Type | Description | Notes |
---|---|---|---|
app_id | String | Identifies the app. | |
integration_id | String | The id of the integration. | |
webhook_id | String | The id of the webhook. | |
webhook_body | WebhookBody |
- Content-Type: application/json
- Accept: application/json