From 32cf18b0610935d646879c409fe11718aaa064f3 Mon Sep 17 00:00:00 2001 From: Jingming Niu Date: Fri, 31 Mar 2017 12:59:35 -0700 Subject: [PATCH] Bump library to 5.2.0 --- CHANGES.md | 5 +++++ src/Twilio/Properties/AssemblyInfo.cs | 2 +- .../Rest/Api/V2010/Account/CallOptions.cs | 18 ++++++++++++++++++ .../Rest/Api/V2010/Account/CallResource.cs | 12 ++++++++---- .../Rest/Chat/V1/Service/UserResource.cs | 5 +++++ src/Twilio/Rest/Chat/V1/ServiceOptions.cs | 18 ++++++++++++++++++ src/Twilio/Rest/Chat/V1/ServiceResource.cs | 17 +++++++++++++---- .../IpMessaging/V1/Service/UserResource.cs | 5 +++++ .../Rest/IpMessaging/V1/ServiceOptions.cs | 18 ++++++++++++++++++ .../Rest/IpMessaging/V1/ServiceResource.cs | 17 +++++++++++++---- .../Taskrouter/V1/Workspace/TaskResource.cs | 1 + src/Twilio/Twilio.csproj | 2 +- .../Rest/Chat/V1/Service/UserResourceTest.cs | 8 ++++---- .../Rest/Chat/V1/ServiceResourceTest.cs | 8 ++++---- .../IpMessaging/V1/Service/UserResourceTest.cs | 8 ++++---- .../Rest/IpMessaging/V1/ServiceResourceTest.cs | 8 ++++---- .../TaskQueueStatisticsResourceTest.cs | 2 +- .../TaskQueuesStatisticsResourceTest.cs | 2 +- .../Workflow/WorkflowStatisticsResourceTest.cs | 2 +- .../WorkspaceStatisticsResourceTest.cs | 2 +- 20 files changed, 126 insertions(+), 34 deletions(-) diff --git a/CHANGES.md b/CHANGES.md index 9dacc3727..45c7d7287 100644 --- a/CHANGES.md +++ b/CHANGES.md @@ -1,6 +1,11 @@ twilio-csharp Changelog ======================= +[2017-04-01] Version 5.2.0 +-------------------------- + - Add answering machine detection to Programmable Voice + - Add channel limits to Programmable Chat + [2017-03-21] Version 5.1.1 -------------------------- - Add `Equals` and `GetHashCode` to `StringEnum` diff --git a/src/Twilio/Properties/AssemblyInfo.cs b/src/Twilio/Properties/AssemblyInfo.cs index db7fcb9e2..3aea5cca8 100644 --- a/src/Twilio/Properties/AssemblyInfo.cs +++ b/src/Twilio/Properties/AssemblyInfo.cs @@ -14,5 +14,5 @@ internal class AssemblyInfomation { - public const string AssemblyInformationalVersion = "5.1.1"; + public const string AssemblyInformationalVersion = "5.2.0"; } \ No newline at end of file diff --git a/src/Twilio/Rest/Api/V2010/Account/CallOptions.cs b/src/Twilio/Rest/Api/V2010/Account/CallOptions.cs index eee11581f..75f8cccf0 100644 --- a/src/Twilio/Rest/Api/V2010/Account/CallOptions.cs +++ b/src/Twilio/Rest/Api/V2010/Account/CallOptions.cs @@ -92,6 +92,14 @@ public class CreateCallOptions : IOptions /// The sip_auth_password /// public string SipAuthPassword { get; set; } + /// + /// Enable machine detection or end of greeting detection + /// + public string MachineDetection { get; set; } + /// + /// Number of miliseconds to wait for machine detection + /// + public int? MachineDetectionTimeout { get; set; } /// /// Construct a new CreateCallOptions @@ -207,6 +215,16 @@ public List> GetParams() p.Add(new KeyValuePair("SipAuthPassword", SipAuthPassword)); } + if (MachineDetection != null) + { + p.Add(new KeyValuePair("MachineDetection", MachineDetection)); + } + + if (MachineDetectionTimeout != null) + { + p.Add(new KeyValuePair("MachineDetectionTimeout", MachineDetectionTimeout.Value.ToString())); + } + return p; } } diff --git a/src/Twilio/Rest/Api/V2010/Account/CallResource.cs b/src/Twilio/Rest/Api/V2010/Account/CallResource.cs index bf6fb56da..7b163857f 100644 --- a/src/Twilio/Rest/Api/V2010/Account/CallResource.cs +++ b/src/Twilio/Rest/Api/V2010/Account/CallResource.cs @@ -116,11 +116,13 @@ public static async System.Threading.Tasks.Task CreateAsync(Create /// The recording_status_callback_method /// The sip_auth_username /// The sip_auth_password + /// Enable machine detection or end of greeting detection + /// Number of miliseconds to wait for machine detection /// Client to make requests to Twilio /// A single instance of Call - public static CallResource Create(IEndpoint to, Types.PhoneNumber from, string pathAccountSid = null, Uri url = null, string applicationSid = null, Twilio.Http.HttpMethod method = null, Uri fallbackUrl = null, Twilio.Http.HttpMethod fallbackMethod = null, Uri statusCallback = null, List statusCallbackEvent = null, Twilio.Http.HttpMethod statusCallbackMethod = null, string sendDigits = null, string ifMachine = null, int? timeout = null, bool? record = null, string recordingChannels = null, string recordingStatusCallback = null, Twilio.Http.HttpMethod recordingStatusCallbackMethod = null, string sipAuthUsername = null, string sipAuthPassword = null, ITwilioRestClient client = null) + public static CallResource Create(IEndpoint to, Types.PhoneNumber from, string pathAccountSid = null, Uri url = null, string applicationSid = null, Twilio.Http.HttpMethod method = null, Uri fallbackUrl = null, Twilio.Http.HttpMethod fallbackMethod = null, Uri statusCallback = null, List statusCallbackEvent = null, Twilio.Http.HttpMethod statusCallbackMethod = null, string sendDigits = null, string ifMachine = null, int? timeout = null, bool? record = null, string recordingChannels = null, string recordingStatusCallback = null, Twilio.Http.HttpMethod recordingStatusCallbackMethod = null, string sipAuthUsername = null, string sipAuthPassword = null, string machineDetection = null, int? machineDetectionTimeout = null, ITwilioRestClient client = null) { - var options = new CreateCallOptions(to, from){PathAccountSid = pathAccountSid, Url = url, ApplicationSid = applicationSid, Method = method, FallbackUrl = fallbackUrl, FallbackMethod = fallbackMethod, StatusCallback = statusCallback, StatusCallbackEvent = statusCallbackEvent, StatusCallbackMethod = statusCallbackMethod, SendDigits = sendDigits, IfMachine = ifMachine, Timeout = timeout, Record = record, RecordingChannels = recordingChannels, RecordingStatusCallback = recordingStatusCallback, RecordingStatusCallbackMethod = recordingStatusCallbackMethod, SipAuthUsername = sipAuthUsername, SipAuthPassword = sipAuthPassword}; + var options = new CreateCallOptions(to, from){PathAccountSid = pathAccountSid, Url = url, ApplicationSid = applicationSid, Method = method, FallbackUrl = fallbackUrl, FallbackMethod = fallbackMethod, StatusCallback = statusCallback, StatusCallbackEvent = statusCallbackEvent, StatusCallbackMethod = statusCallbackMethod, SendDigits = sendDigits, IfMachine = ifMachine, Timeout = timeout, Record = record, RecordingChannels = recordingChannels, RecordingStatusCallback = recordingStatusCallback, RecordingStatusCallbackMethod = recordingStatusCallbackMethod, SipAuthUsername = sipAuthUsername, SipAuthPassword = sipAuthPassword, MachineDetection = machineDetection, MachineDetectionTimeout = machineDetectionTimeout}; return Create(options, client); } @@ -149,11 +151,13 @@ public static CallResource Create(IEndpoint to, Types.PhoneNumber from, string p /// The recording_status_callback_method /// The sip_auth_username /// The sip_auth_password + /// Enable machine detection or end of greeting detection + /// Number of miliseconds to wait for machine detection /// Client to make requests to Twilio /// Task that resolves to A single instance of Call - public static async System.Threading.Tasks.Task CreateAsync(IEndpoint to, Types.PhoneNumber from, string pathAccountSid = null, Uri url = null, string applicationSid = null, Twilio.Http.HttpMethod method = null, Uri fallbackUrl = null, Twilio.Http.HttpMethod fallbackMethod = null, Uri statusCallback = null, List statusCallbackEvent = null, Twilio.Http.HttpMethod statusCallbackMethod = null, string sendDigits = null, string ifMachine = null, int? timeout = null, bool? record = null, string recordingChannels = null, string recordingStatusCallback = null, Twilio.Http.HttpMethod recordingStatusCallbackMethod = null, string sipAuthUsername = null, string sipAuthPassword = null, ITwilioRestClient client = null) + public static async System.Threading.Tasks.Task CreateAsync(IEndpoint to, Types.PhoneNumber from, string pathAccountSid = null, Uri url = null, string applicationSid = null, Twilio.Http.HttpMethod method = null, Uri fallbackUrl = null, Twilio.Http.HttpMethod fallbackMethod = null, Uri statusCallback = null, List statusCallbackEvent = null, Twilio.Http.HttpMethod statusCallbackMethod = null, string sendDigits = null, string ifMachine = null, int? timeout = null, bool? record = null, string recordingChannels = null, string recordingStatusCallback = null, Twilio.Http.HttpMethod recordingStatusCallbackMethod = null, string sipAuthUsername = null, string sipAuthPassword = null, string machineDetection = null, int? machineDetectionTimeout = null, ITwilioRestClient client = null) { - var options = new CreateCallOptions(to, from){PathAccountSid = pathAccountSid, Url = url, ApplicationSid = applicationSid, Method = method, FallbackUrl = fallbackUrl, FallbackMethod = fallbackMethod, StatusCallback = statusCallback, StatusCallbackEvent = statusCallbackEvent, StatusCallbackMethod = statusCallbackMethod, SendDigits = sendDigits, IfMachine = ifMachine, Timeout = timeout, Record = record, RecordingChannels = recordingChannels, RecordingStatusCallback = recordingStatusCallback, RecordingStatusCallbackMethod = recordingStatusCallbackMethod, SipAuthUsername = sipAuthUsername, SipAuthPassword = sipAuthPassword}; + var options = new CreateCallOptions(to, from){PathAccountSid = pathAccountSid, Url = url, ApplicationSid = applicationSid, Method = method, FallbackUrl = fallbackUrl, FallbackMethod = fallbackMethod, StatusCallback = statusCallback, StatusCallbackEvent = statusCallbackEvent, StatusCallbackMethod = statusCallbackMethod, SendDigits = sendDigits, IfMachine = ifMachine, Timeout = timeout, Record = record, RecordingChannels = recordingChannels, RecordingStatusCallback = recordingStatusCallback, RecordingStatusCallbackMethod = recordingStatusCallbackMethod, SipAuthUsername = sipAuthUsername, SipAuthPassword = sipAuthPassword, MachineDetection = machineDetection, MachineDetectionTimeout = machineDetectionTimeout}; return await CreateAsync(options, client); } #endif diff --git a/src/Twilio/Rest/Chat/V1/Service/UserResource.cs b/src/Twilio/Rest/Chat/V1/Service/UserResource.cs index ef5c478ab..fe573a157 100644 --- a/src/Twilio/Rest/Chat/V1/Service/UserResource.cs +++ b/src/Twilio/Rest/Chat/V1/Service/UserResource.cs @@ -484,6 +484,11 @@ public static UserResource FromJson(string json) [JsonProperty("date_updated")] public DateTime? DateUpdated { get; private set; } /// + /// The joined_channels_count + /// + [JsonProperty("joined_channels_count")] + public int? JoinedChannelsCount { get; private set; } + /// /// The links /// [JsonProperty("links")] diff --git a/src/Twilio/Rest/Chat/V1/ServiceOptions.cs b/src/Twilio/Rest/Chat/V1/ServiceOptions.cs index ce91f0f7c..af46b37a7 100644 --- a/src/Twilio/Rest/Chat/V1/ServiceOptions.cs +++ b/src/Twilio/Rest/Chat/V1/ServiceOptions.cs @@ -402,6 +402,14 @@ public class UpdateServiceOptions : IOptions /// The webhooks.on_member_removed.format /// public string WebhooksOnMemberRemovedFormat { get; set; } + /// + /// The limits.channel_members + /// + public int? LimitsChannelMembers { get; set; } + /// + /// The limits.user_channels + /// + public int? LimitsUserChannels { get; set; } /// /// Construct a new UpdateServiceOptions @@ -760,6 +768,16 @@ public List> GetParams() p.Add(new KeyValuePair("Webhooks.OnMemberRemoved.Format", WebhooksOnMemberRemovedFormat)); } + if (LimitsChannelMembers != null) + { + p.Add(new KeyValuePair("Limits.ChannelMembers", LimitsChannelMembers.Value.ToString())); + } + + if (LimitsUserChannels != null) + { + p.Add(new KeyValuePair("Limits.UserChannels", LimitsUserChannels.Value.ToString())); + } + return p; } } diff --git a/src/Twilio/Rest/Chat/V1/ServiceResource.cs b/src/Twilio/Rest/Chat/V1/ServiceResource.cs index 899bd8c99..b9074e2c0 100644 --- a/src/Twilio/Rest/Chat/V1/ServiceResource.cs +++ b/src/Twilio/Rest/Chat/V1/ServiceResource.cs @@ -432,11 +432,13 @@ public static async System.Threading.Tasks.Task UpdateAsync(Upd /// The webhooks.on_member_removed.url /// The webhooks.on_member_removed.method /// The webhooks.on_member_removed.format + /// The limits.channel_members + /// The limits.user_channels /// Client to make requests to Twilio /// A single instance of Service - public static ServiceResource Update(string pathSid, string friendlyName = null, string defaultServiceRoleSid = null, string defaultChannelRoleSid = null, string defaultChannelCreatorRoleSid = null, bool? readStatusEnabled = null, bool? reachabilityEnabled = null, int? typingIndicatorTimeout = null, int? consumptionReportInterval = null, bool? notificationsNewMessageEnabled = null, string notificationsNewMessageTemplate = null, bool? notificationsAddedToChannelEnabled = null, string notificationsAddedToChannelTemplate = null, bool? notificationsRemovedFromChannelEnabled = null, string notificationsRemovedFromChannelTemplate = null, bool? notificationsInvitedToChannelEnabled = null, string notificationsInvitedToChannelTemplate = null, Uri preWebhookUrl = null, Uri postWebhookUrl = null, Twilio.Http.HttpMethod webhookMethod = null, List webhookFilters = null, Uri webhooksOnMessageSendUrl = null, Twilio.Http.HttpMethod webhooksOnMessageSendMethod = null, string webhooksOnMessageSendFormat = null, Uri webhooksOnMessageUpdateUrl = null, Twilio.Http.HttpMethod webhooksOnMessageUpdateMethod = null, string webhooksOnMessageUpdateFormat = null, Uri webhooksOnMessageRemoveUrl = null, Twilio.Http.HttpMethod webhooksOnMessageRemoveMethod = null, string webhooksOnMessageRemoveFormat = null, Uri webhooksOnChannelAddUrl = null, Twilio.Http.HttpMethod webhooksOnChannelAddMethod = null, string webhooksOnChannelAddFormat = null, Uri webhooksOnChannelDestroyUrl = null, Twilio.Http.HttpMethod webhooksOnChannelDestroyMethod = null, string webhooksOnChannelDestroyFormat = null, Uri webhooksOnChannelUpdateUrl = null, Twilio.Http.HttpMethod webhooksOnChannelUpdateMethod = null, string webhooksOnChannelUpdateFormat = null, Uri webhooksOnMemberAddUrl = null, Twilio.Http.HttpMethod webhooksOnMemberAddMethod = null, string webhooksOnMemberAddFormat = null, Uri webhooksOnMemberRemoveUrl = null, Twilio.Http.HttpMethod webhooksOnMemberRemoveMethod = null, string webhooksOnMemberRemoveFormat = null, Uri webhooksOnMessageSentUrl = null, Twilio.Http.HttpMethod webhooksOnMessageSentMethod = null, string webhooksOnMessageSentFormat = null, Uri webhooksOnMessageUpdatedUrl = null, Twilio.Http.HttpMethod webhooksOnMessageUpdatedMethod = null, string webhooksOnMessageUpdatedFormat = null, Uri webhooksOnMessageRemovedUrl = null, Twilio.Http.HttpMethod webhooksOnMessageRemovedMethod = null, string webhooksOnMessageRemovedFormat = null, Uri webhooksOnChannelAddedUrl = null, Twilio.Http.HttpMethod webhooksOnChannelAddedMethod = null, string webhooksOnChannelAddedFormat = null, Uri webhooksOnChannelDestroyedUrl = null, Twilio.Http.HttpMethod webhooksOnChannelDestroyedMethod = null, string webhooksOnChannelDestroyedFormat = null, Uri webhooksOnChannelUpdatedUrl = null, Twilio.Http.HttpMethod webhooksOnChannelUpdatedMethod = null, string webhooksOnChannelUpdatedFormat = null, Uri webhooksOnMemberAddedUrl = null, Twilio.Http.HttpMethod webhooksOnMemberAddedMethod = null, string webhooksOnMemberAddedFormat = null, Uri webhooksOnMemberRemovedUrl = null, Twilio.Http.HttpMethod webhooksOnMemberRemovedMethod = null, string webhooksOnMemberRemovedFormat = null, ITwilioRestClient client = null) + public static ServiceResource Update(string pathSid, string friendlyName = null, string defaultServiceRoleSid = null, string defaultChannelRoleSid = null, string defaultChannelCreatorRoleSid = null, bool? readStatusEnabled = null, bool? reachabilityEnabled = null, int? typingIndicatorTimeout = null, int? consumptionReportInterval = null, bool? notificationsNewMessageEnabled = null, string notificationsNewMessageTemplate = null, bool? notificationsAddedToChannelEnabled = null, string notificationsAddedToChannelTemplate = null, bool? notificationsRemovedFromChannelEnabled = null, string notificationsRemovedFromChannelTemplate = null, bool? notificationsInvitedToChannelEnabled = null, string notificationsInvitedToChannelTemplate = null, Uri preWebhookUrl = null, Uri postWebhookUrl = null, Twilio.Http.HttpMethod webhookMethod = null, List webhookFilters = null, Uri webhooksOnMessageSendUrl = null, Twilio.Http.HttpMethod webhooksOnMessageSendMethod = null, string webhooksOnMessageSendFormat = null, Uri webhooksOnMessageUpdateUrl = null, Twilio.Http.HttpMethod webhooksOnMessageUpdateMethod = null, string webhooksOnMessageUpdateFormat = null, Uri webhooksOnMessageRemoveUrl = null, Twilio.Http.HttpMethod webhooksOnMessageRemoveMethod = null, string webhooksOnMessageRemoveFormat = null, Uri webhooksOnChannelAddUrl = null, Twilio.Http.HttpMethod webhooksOnChannelAddMethod = null, string webhooksOnChannelAddFormat = null, Uri webhooksOnChannelDestroyUrl = null, Twilio.Http.HttpMethod webhooksOnChannelDestroyMethod = null, string webhooksOnChannelDestroyFormat = null, Uri webhooksOnChannelUpdateUrl = null, Twilio.Http.HttpMethod webhooksOnChannelUpdateMethod = null, string webhooksOnChannelUpdateFormat = null, Uri webhooksOnMemberAddUrl = null, Twilio.Http.HttpMethod webhooksOnMemberAddMethod = null, string webhooksOnMemberAddFormat = null, Uri webhooksOnMemberRemoveUrl = null, Twilio.Http.HttpMethod webhooksOnMemberRemoveMethod = null, string webhooksOnMemberRemoveFormat = null, Uri webhooksOnMessageSentUrl = null, Twilio.Http.HttpMethod webhooksOnMessageSentMethod = null, string webhooksOnMessageSentFormat = null, Uri webhooksOnMessageUpdatedUrl = null, Twilio.Http.HttpMethod webhooksOnMessageUpdatedMethod = null, string webhooksOnMessageUpdatedFormat = null, Uri webhooksOnMessageRemovedUrl = null, Twilio.Http.HttpMethod webhooksOnMessageRemovedMethod = null, string webhooksOnMessageRemovedFormat = null, Uri webhooksOnChannelAddedUrl = null, Twilio.Http.HttpMethod webhooksOnChannelAddedMethod = null, string webhooksOnChannelAddedFormat = null, Uri webhooksOnChannelDestroyedUrl = null, Twilio.Http.HttpMethod webhooksOnChannelDestroyedMethod = null, string webhooksOnChannelDestroyedFormat = null, Uri webhooksOnChannelUpdatedUrl = null, Twilio.Http.HttpMethod webhooksOnChannelUpdatedMethod = null, string webhooksOnChannelUpdatedFormat = null, Uri webhooksOnMemberAddedUrl = null, Twilio.Http.HttpMethod webhooksOnMemberAddedMethod = null, string webhooksOnMemberAddedFormat = null, Uri webhooksOnMemberRemovedUrl = null, Twilio.Http.HttpMethod webhooksOnMemberRemovedMethod = null, string webhooksOnMemberRemovedFormat = null, int? limitsChannelMembers = null, int? limitsUserChannels = null, ITwilioRestClient client = null) { - var options = new UpdateServiceOptions(pathSid){FriendlyName = friendlyName, DefaultServiceRoleSid = defaultServiceRoleSid, DefaultChannelRoleSid = defaultChannelRoleSid, DefaultChannelCreatorRoleSid = defaultChannelCreatorRoleSid, ReadStatusEnabled = readStatusEnabled, ReachabilityEnabled = reachabilityEnabled, TypingIndicatorTimeout = typingIndicatorTimeout, ConsumptionReportInterval = consumptionReportInterval, NotificationsNewMessageEnabled = notificationsNewMessageEnabled, NotificationsNewMessageTemplate = notificationsNewMessageTemplate, NotificationsAddedToChannelEnabled = notificationsAddedToChannelEnabled, NotificationsAddedToChannelTemplate = notificationsAddedToChannelTemplate, NotificationsRemovedFromChannelEnabled = notificationsRemovedFromChannelEnabled, NotificationsRemovedFromChannelTemplate = notificationsRemovedFromChannelTemplate, NotificationsInvitedToChannelEnabled = notificationsInvitedToChannelEnabled, NotificationsInvitedToChannelTemplate = notificationsInvitedToChannelTemplate, PreWebhookUrl = preWebhookUrl, PostWebhookUrl = postWebhookUrl, WebhookMethod = webhookMethod, WebhookFilters = webhookFilters, WebhooksOnMessageSendUrl = webhooksOnMessageSendUrl, WebhooksOnMessageSendMethod = webhooksOnMessageSendMethod, WebhooksOnMessageSendFormat = webhooksOnMessageSendFormat, WebhooksOnMessageUpdateUrl = webhooksOnMessageUpdateUrl, WebhooksOnMessageUpdateMethod = webhooksOnMessageUpdateMethod, WebhooksOnMessageUpdateFormat = webhooksOnMessageUpdateFormat, WebhooksOnMessageRemoveUrl = webhooksOnMessageRemoveUrl, WebhooksOnMessageRemoveMethod = webhooksOnMessageRemoveMethod, WebhooksOnMessageRemoveFormat = webhooksOnMessageRemoveFormat, WebhooksOnChannelAddUrl = webhooksOnChannelAddUrl, WebhooksOnChannelAddMethod = webhooksOnChannelAddMethod, WebhooksOnChannelAddFormat = webhooksOnChannelAddFormat, WebhooksOnChannelDestroyUrl = webhooksOnChannelDestroyUrl, WebhooksOnChannelDestroyMethod = webhooksOnChannelDestroyMethod, WebhooksOnChannelDestroyFormat = webhooksOnChannelDestroyFormat, WebhooksOnChannelUpdateUrl = webhooksOnChannelUpdateUrl, WebhooksOnChannelUpdateMethod = webhooksOnChannelUpdateMethod, WebhooksOnChannelUpdateFormat = webhooksOnChannelUpdateFormat, WebhooksOnMemberAddUrl = webhooksOnMemberAddUrl, WebhooksOnMemberAddMethod = webhooksOnMemberAddMethod, WebhooksOnMemberAddFormat = webhooksOnMemberAddFormat, WebhooksOnMemberRemoveUrl = webhooksOnMemberRemoveUrl, WebhooksOnMemberRemoveMethod = webhooksOnMemberRemoveMethod, WebhooksOnMemberRemoveFormat = webhooksOnMemberRemoveFormat, WebhooksOnMessageSentUrl = webhooksOnMessageSentUrl, WebhooksOnMessageSentMethod = webhooksOnMessageSentMethod, WebhooksOnMessageSentFormat = webhooksOnMessageSentFormat, WebhooksOnMessageUpdatedUrl = webhooksOnMessageUpdatedUrl, WebhooksOnMessageUpdatedMethod = webhooksOnMessageUpdatedMethod, WebhooksOnMessageUpdatedFormat = webhooksOnMessageUpdatedFormat, WebhooksOnMessageRemovedUrl = webhooksOnMessageRemovedUrl, WebhooksOnMessageRemovedMethod = webhooksOnMessageRemovedMethod, WebhooksOnMessageRemovedFormat = webhooksOnMessageRemovedFormat, WebhooksOnChannelAddedUrl = webhooksOnChannelAddedUrl, WebhooksOnChannelAddedMethod = webhooksOnChannelAddedMethod, WebhooksOnChannelAddedFormat = webhooksOnChannelAddedFormat, WebhooksOnChannelDestroyedUrl = webhooksOnChannelDestroyedUrl, WebhooksOnChannelDestroyedMethod = webhooksOnChannelDestroyedMethod, WebhooksOnChannelDestroyedFormat = webhooksOnChannelDestroyedFormat, WebhooksOnChannelUpdatedUrl = webhooksOnChannelUpdatedUrl, WebhooksOnChannelUpdatedMethod = webhooksOnChannelUpdatedMethod, WebhooksOnChannelUpdatedFormat = webhooksOnChannelUpdatedFormat, WebhooksOnMemberAddedUrl = webhooksOnMemberAddedUrl, WebhooksOnMemberAddedMethod = webhooksOnMemberAddedMethod, WebhooksOnMemberAddedFormat = webhooksOnMemberAddedFormat, WebhooksOnMemberRemovedUrl = webhooksOnMemberRemovedUrl, WebhooksOnMemberRemovedMethod = webhooksOnMemberRemovedMethod, WebhooksOnMemberRemovedFormat = webhooksOnMemberRemovedFormat}; + var options = new UpdateServiceOptions(pathSid){FriendlyName = friendlyName, DefaultServiceRoleSid = defaultServiceRoleSid, DefaultChannelRoleSid = defaultChannelRoleSid, DefaultChannelCreatorRoleSid = defaultChannelCreatorRoleSid, ReadStatusEnabled = readStatusEnabled, ReachabilityEnabled = reachabilityEnabled, TypingIndicatorTimeout = typingIndicatorTimeout, ConsumptionReportInterval = consumptionReportInterval, NotificationsNewMessageEnabled = notificationsNewMessageEnabled, NotificationsNewMessageTemplate = notificationsNewMessageTemplate, NotificationsAddedToChannelEnabled = notificationsAddedToChannelEnabled, NotificationsAddedToChannelTemplate = notificationsAddedToChannelTemplate, NotificationsRemovedFromChannelEnabled = notificationsRemovedFromChannelEnabled, NotificationsRemovedFromChannelTemplate = notificationsRemovedFromChannelTemplate, NotificationsInvitedToChannelEnabled = notificationsInvitedToChannelEnabled, NotificationsInvitedToChannelTemplate = notificationsInvitedToChannelTemplate, PreWebhookUrl = preWebhookUrl, PostWebhookUrl = postWebhookUrl, WebhookMethod = webhookMethod, WebhookFilters = webhookFilters, WebhooksOnMessageSendUrl = webhooksOnMessageSendUrl, WebhooksOnMessageSendMethod = webhooksOnMessageSendMethod, WebhooksOnMessageSendFormat = webhooksOnMessageSendFormat, WebhooksOnMessageUpdateUrl = webhooksOnMessageUpdateUrl, WebhooksOnMessageUpdateMethod = webhooksOnMessageUpdateMethod, WebhooksOnMessageUpdateFormat = webhooksOnMessageUpdateFormat, WebhooksOnMessageRemoveUrl = webhooksOnMessageRemoveUrl, WebhooksOnMessageRemoveMethod = webhooksOnMessageRemoveMethod, WebhooksOnMessageRemoveFormat = webhooksOnMessageRemoveFormat, WebhooksOnChannelAddUrl = webhooksOnChannelAddUrl, WebhooksOnChannelAddMethod = webhooksOnChannelAddMethod, WebhooksOnChannelAddFormat = webhooksOnChannelAddFormat, WebhooksOnChannelDestroyUrl = webhooksOnChannelDestroyUrl, WebhooksOnChannelDestroyMethod = webhooksOnChannelDestroyMethod, WebhooksOnChannelDestroyFormat = webhooksOnChannelDestroyFormat, WebhooksOnChannelUpdateUrl = webhooksOnChannelUpdateUrl, WebhooksOnChannelUpdateMethod = webhooksOnChannelUpdateMethod, WebhooksOnChannelUpdateFormat = webhooksOnChannelUpdateFormat, WebhooksOnMemberAddUrl = webhooksOnMemberAddUrl, WebhooksOnMemberAddMethod = webhooksOnMemberAddMethod, WebhooksOnMemberAddFormat = webhooksOnMemberAddFormat, WebhooksOnMemberRemoveUrl = webhooksOnMemberRemoveUrl, WebhooksOnMemberRemoveMethod = webhooksOnMemberRemoveMethod, WebhooksOnMemberRemoveFormat = webhooksOnMemberRemoveFormat, WebhooksOnMessageSentUrl = webhooksOnMessageSentUrl, WebhooksOnMessageSentMethod = webhooksOnMessageSentMethod, WebhooksOnMessageSentFormat = webhooksOnMessageSentFormat, WebhooksOnMessageUpdatedUrl = webhooksOnMessageUpdatedUrl, WebhooksOnMessageUpdatedMethod = webhooksOnMessageUpdatedMethod, WebhooksOnMessageUpdatedFormat = webhooksOnMessageUpdatedFormat, WebhooksOnMessageRemovedUrl = webhooksOnMessageRemovedUrl, WebhooksOnMessageRemovedMethod = webhooksOnMessageRemovedMethod, WebhooksOnMessageRemovedFormat = webhooksOnMessageRemovedFormat, WebhooksOnChannelAddedUrl = webhooksOnChannelAddedUrl, WebhooksOnChannelAddedMethod = webhooksOnChannelAddedMethod, WebhooksOnChannelAddedFormat = webhooksOnChannelAddedFormat, WebhooksOnChannelDestroyedUrl = webhooksOnChannelDestroyedUrl, WebhooksOnChannelDestroyedMethod = webhooksOnChannelDestroyedMethod, WebhooksOnChannelDestroyedFormat = webhooksOnChannelDestroyedFormat, WebhooksOnChannelUpdatedUrl = webhooksOnChannelUpdatedUrl, WebhooksOnChannelUpdatedMethod = webhooksOnChannelUpdatedMethod, WebhooksOnChannelUpdatedFormat = webhooksOnChannelUpdatedFormat, WebhooksOnMemberAddedUrl = webhooksOnMemberAddedUrl, WebhooksOnMemberAddedMethod = webhooksOnMemberAddedMethod, WebhooksOnMemberAddedFormat = webhooksOnMemberAddedFormat, WebhooksOnMemberRemovedUrl = webhooksOnMemberRemovedUrl, WebhooksOnMemberRemovedMethod = webhooksOnMemberRemovedMethod, WebhooksOnMemberRemovedFormat = webhooksOnMemberRemovedFormat, LimitsChannelMembers = limitsChannelMembers, LimitsUserChannels = limitsUserChannels}; return Update(options, client); } @@ -514,11 +516,13 @@ public static ServiceResource Update(string pathSid, string friendlyName = null, /// The webhooks.on_member_removed.url /// The webhooks.on_member_removed.method /// The webhooks.on_member_removed.format + /// The limits.channel_members + /// The limits.user_channels /// Client to make requests to Twilio /// Task that resolves to A single instance of Service - public static async System.Threading.Tasks.Task UpdateAsync(string pathSid, string friendlyName = null, string defaultServiceRoleSid = null, string defaultChannelRoleSid = null, string defaultChannelCreatorRoleSid = null, bool? readStatusEnabled = null, bool? reachabilityEnabled = null, int? typingIndicatorTimeout = null, int? consumptionReportInterval = null, bool? notificationsNewMessageEnabled = null, string notificationsNewMessageTemplate = null, bool? notificationsAddedToChannelEnabled = null, string notificationsAddedToChannelTemplate = null, bool? notificationsRemovedFromChannelEnabled = null, string notificationsRemovedFromChannelTemplate = null, bool? notificationsInvitedToChannelEnabled = null, string notificationsInvitedToChannelTemplate = null, Uri preWebhookUrl = null, Uri postWebhookUrl = null, Twilio.Http.HttpMethod webhookMethod = null, List webhookFilters = null, Uri webhooksOnMessageSendUrl = null, Twilio.Http.HttpMethod webhooksOnMessageSendMethod = null, string webhooksOnMessageSendFormat = null, Uri webhooksOnMessageUpdateUrl = null, Twilio.Http.HttpMethod webhooksOnMessageUpdateMethod = null, string webhooksOnMessageUpdateFormat = null, Uri webhooksOnMessageRemoveUrl = null, Twilio.Http.HttpMethod webhooksOnMessageRemoveMethod = null, string webhooksOnMessageRemoveFormat = null, Uri webhooksOnChannelAddUrl = null, Twilio.Http.HttpMethod webhooksOnChannelAddMethod = null, string webhooksOnChannelAddFormat = null, Uri webhooksOnChannelDestroyUrl = null, Twilio.Http.HttpMethod webhooksOnChannelDestroyMethod = null, string webhooksOnChannelDestroyFormat = null, Uri webhooksOnChannelUpdateUrl = null, Twilio.Http.HttpMethod webhooksOnChannelUpdateMethod = null, string webhooksOnChannelUpdateFormat = null, Uri webhooksOnMemberAddUrl = null, Twilio.Http.HttpMethod webhooksOnMemberAddMethod = null, string webhooksOnMemberAddFormat = null, Uri webhooksOnMemberRemoveUrl = null, Twilio.Http.HttpMethod webhooksOnMemberRemoveMethod = null, string webhooksOnMemberRemoveFormat = null, Uri webhooksOnMessageSentUrl = null, Twilio.Http.HttpMethod webhooksOnMessageSentMethod = null, string webhooksOnMessageSentFormat = null, Uri webhooksOnMessageUpdatedUrl = null, Twilio.Http.HttpMethod webhooksOnMessageUpdatedMethod = null, string webhooksOnMessageUpdatedFormat = null, Uri webhooksOnMessageRemovedUrl = null, Twilio.Http.HttpMethod webhooksOnMessageRemovedMethod = null, string webhooksOnMessageRemovedFormat = null, Uri webhooksOnChannelAddedUrl = null, Twilio.Http.HttpMethod webhooksOnChannelAddedMethod = null, string webhooksOnChannelAddedFormat = null, Uri webhooksOnChannelDestroyedUrl = null, Twilio.Http.HttpMethod webhooksOnChannelDestroyedMethod = null, string webhooksOnChannelDestroyedFormat = null, Uri webhooksOnChannelUpdatedUrl = null, Twilio.Http.HttpMethod webhooksOnChannelUpdatedMethod = null, string webhooksOnChannelUpdatedFormat = null, Uri webhooksOnMemberAddedUrl = null, Twilio.Http.HttpMethod webhooksOnMemberAddedMethod = null, string webhooksOnMemberAddedFormat = null, Uri webhooksOnMemberRemovedUrl = null, Twilio.Http.HttpMethod webhooksOnMemberRemovedMethod = null, string webhooksOnMemberRemovedFormat = null, ITwilioRestClient client = null) + public static async System.Threading.Tasks.Task UpdateAsync(string pathSid, string friendlyName = null, string defaultServiceRoleSid = null, string defaultChannelRoleSid = null, string defaultChannelCreatorRoleSid = null, bool? readStatusEnabled = null, bool? reachabilityEnabled = null, int? typingIndicatorTimeout = null, int? consumptionReportInterval = null, bool? notificationsNewMessageEnabled = null, string notificationsNewMessageTemplate = null, bool? notificationsAddedToChannelEnabled = null, string notificationsAddedToChannelTemplate = null, bool? notificationsRemovedFromChannelEnabled = null, string notificationsRemovedFromChannelTemplate = null, bool? notificationsInvitedToChannelEnabled = null, string notificationsInvitedToChannelTemplate = null, Uri preWebhookUrl = null, Uri postWebhookUrl = null, Twilio.Http.HttpMethod webhookMethod = null, List webhookFilters = null, Uri webhooksOnMessageSendUrl = null, Twilio.Http.HttpMethod webhooksOnMessageSendMethod = null, string webhooksOnMessageSendFormat = null, Uri webhooksOnMessageUpdateUrl = null, Twilio.Http.HttpMethod webhooksOnMessageUpdateMethod = null, string webhooksOnMessageUpdateFormat = null, Uri webhooksOnMessageRemoveUrl = null, Twilio.Http.HttpMethod webhooksOnMessageRemoveMethod = null, string webhooksOnMessageRemoveFormat = null, Uri webhooksOnChannelAddUrl = null, Twilio.Http.HttpMethod webhooksOnChannelAddMethod = null, string webhooksOnChannelAddFormat = null, Uri webhooksOnChannelDestroyUrl = null, Twilio.Http.HttpMethod webhooksOnChannelDestroyMethod = null, string webhooksOnChannelDestroyFormat = null, Uri webhooksOnChannelUpdateUrl = null, Twilio.Http.HttpMethod webhooksOnChannelUpdateMethod = null, string webhooksOnChannelUpdateFormat = null, Uri webhooksOnMemberAddUrl = null, Twilio.Http.HttpMethod webhooksOnMemberAddMethod = null, string webhooksOnMemberAddFormat = null, Uri webhooksOnMemberRemoveUrl = null, Twilio.Http.HttpMethod webhooksOnMemberRemoveMethod = null, string webhooksOnMemberRemoveFormat = null, Uri webhooksOnMessageSentUrl = null, Twilio.Http.HttpMethod webhooksOnMessageSentMethod = null, string webhooksOnMessageSentFormat = null, Uri webhooksOnMessageUpdatedUrl = null, Twilio.Http.HttpMethod webhooksOnMessageUpdatedMethod = null, string webhooksOnMessageUpdatedFormat = null, Uri webhooksOnMessageRemovedUrl = null, Twilio.Http.HttpMethod webhooksOnMessageRemovedMethod = null, string webhooksOnMessageRemovedFormat = null, Uri webhooksOnChannelAddedUrl = null, Twilio.Http.HttpMethod webhooksOnChannelAddedMethod = null, string webhooksOnChannelAddedFormat = null, Uri webhooksOnChannelDestroyedUrl = null, Twilio.Http.HttpMethod webhooksOnChannelDestroyedMethod = null, string webhooksOnChannelDestroyedFormat = null, Uri webhooksOnChannelUpdatedUrl = null, Twilio.Http.HttpMethod webhooksOnChannelUpdatedMethod = null, string webhooksOnChannelUpdatedFormat = null, Uri webhooksOnMemberAddedUrl = null, Twilio.Http.HttpMethod webhooksOnMemberAddedMethod = null, string webhooksOnMemberAddedFormat = null, Uri webhooksOnMemberRemovedUrl = null, Twilio.Http.HttpMethod webhooksOnMemberRemovedMethod = null, string webhooksOnMemberRemovedFormat = null, int? limitsChannelMembers = null, int? limitsUserChannels = null, ITwilioRestClient client = null) { - var options = new UpdateServiceOptions(pathSid){FriendlyName = friendlyName, DefaultServiceRoleSid = defaultServiceRoleSid, DefaultChannelRoleSid = defaultChannelRoleSid, DefaultChannelCreatorRoleSid = defaultChannelCreatorRoleSid, ReadStatusEnabled = readStatusEnabled, ReachabilityEnabled = reachabilityEnabled, TypingIndicatorTimeout = typingIndicatorTimeout, ConsumptionReportInterval = consumptionReportInterval, NotificationsNewMessageEnabled = notificationsNewMessageEnabled, NotificationsNewMessageTemplate = notificationsNewMessageTemplate, NotificationsAddedToChannelEnabled = notificationsAddedToChannelEnabled, NotificationsAddedToChannelTemplate = notificationsAddedToChannelTemplate, NotificationsRemovedFromChannelEnabled = notificationsRemovedFromChannelEnabled, NotificationsRemovedFromChannelTemplate = notificationsRemovedFromChannelTemplate, NotificationsInvitedToChannelEnabled = notificationsInvitedToChannelEnabled, NotificationsInvitedToChannelTemplate = notificationsInvitedToChannelTemplate, PreWebhookUrl = preWebhookUrl, PostWebhookUrl = postWebhookUrl, WebhookMethod = webhookMethod, WebhookFilters = webhookFilters, WebhooksOnMessageSendUrl = webhooksOnMessageSendUrl, WebhooksOnMessageSendMethod = webhooksOnMessageSendMethod, WebhooksOnMessageSendFormat = webhooksOnMessageSendFormat, WebhooksOnMessageUpdateUrl = webhooksOnMessageUpdateUrl, WebhooksOnMessageUpdateMethod = webhooksOnMessageUpdateMethod, WebhooksOnMessageUpdateFormat = webhooksOnMessageUpdateFormat, WebhooksOnMessageRemoveUrl = webhooksOnMessageRemoveUrl, WebhooksOnMessageRemoveMethod = webhooksOnMessageRemoveMethod, WebhooksOnMessageRemoveFormat = webhooksOnMessageRemoveFormat, WebhooksOnChannelAddUrl = webhooksOnChannelAddUrl, WebhooksOnChannelAddMethod = webhooksOnChannelAddMethod, WebhooksOnChannelAddFormat = webhooksOnChannelAddFormat, WebhooksOnChannelDestroyUrl = webhooksOnChannelDestroyUrl, WebhooksOnChannelDestroyMethod = webhooksOnChannelDestroyMethod, WebhooksOnChannelDestroyFormat = webhooksOnChannelDestroyFormat, WebhooksOnChannelUpdateUrl = webhooksOnChannelUpdateUrl, WebhooksOnChannelUpdateMethod = webhooksOnChannelUpdateMethod, WebhooksOnChannelUpdateFormat = webhooksOnChannelUpdateFormat, WebhooksOnMemberAddUrl = webhooksOnMemberAddUrl, WebhooksOnMemberAddMethod = webhooksOnMemberAddMethod, WebhooksOnMemberAddFormat = webhooksOnMemberAddFormat, WebhooksOnMemberRemoveUrl = webhooksOnMemberRemoveUrl, WebhooksOnMemberRemoveMethod = webhooksOnMemberRemoveMethod, WebhooksOnMemberRemoveFormat = webhooksOnMemberRemoveFormat, WebhooksOnMessageSentUrl = webhooksOnMessageSentUrl, WebhooksOnMessageSentMethod = webhooksOnMessageSentMethod, WebhooksOnMessageSentFormat = webhooksOnMessageSentFormat, WebhooksOnMessageUpdatedUrl = webhooksOnMessageUpdatedUrl, WebhooksOnMessageUpdatedMethod = webhooksOnMessageUpdatedMethod, WebhooksOnMessageUpdatedFormat = webhooksOnMessageUpdatedFormat, WebhooksOnMessageRemovedUrl = webhooksOnMessageRemovedUrl, WebhooksOnMessageRemovedMethod = webhooksOnMessageRemovedMethod, WebhooksOnMessageRemovedFormat = webhooksOnMessageRemovedFormat, WebhooksOnChannelAddedUrl = webhooksOnChannelAddedUrl, WebhooksOnChannelAddedMethod = webhooksOnChannelAddedMethod, WebhooksOnChannelAddedFormat = webhooksOnChannelAddedFormat, WebhooksOnChannelDestroyedUrl = webhooksOnChannelDestroyedUrl, WebhooksOnChannelDestroyedMethod = webhooksOnChannelDestroyedMethod, WebhooksOnChannelDestroyedFormat = webhooksOnChannelDestroyedFormat, WebhooksOnChannelUpdatedUrl = webhooksOnChannelUpdatedUrl, WebhooksOnChannelUpdatedMethod = webhooksOnChannelUpdatedMethod, WebhooksOnChannelUpdatedFormat = webhooksOnChannelUpdatedFormat, WebhooksOnMemberAddedUrl = webhooksOnMemberAddedUrl, WebhooksOnMemberAddedMethod = webhooksOnMemberAddedMethod, WebhooksOnMemberAddedFormat = webhooksOnMemberAddedFormat, WebhooksOnMemberRemovedUrl = webhooksOnMemberRemovedUrl, WebhooksOnMemberRemovedMethod = webhooksOnMemberRemovedMethod, WebhooksOnMemberRemovedFormat = webhooksOnMemberRemovedFormat}; + var options = new UpdateServiceOptions(pathSid){FriendlyName = friendlyName, DefaultServiceRoleSid = defaultServiceRoleSid, DefaultChannelRoleSid = defaultChannelRoleSid, DefaultChannelCreatorRoleSid = defaultChannelCreatorRoleSid, ReadStatusEnabled = readStatusEnabled, ReachabilityEnabled = reachabilityEnabled, TypingIndicatorTimeout = typingIndicatorTimeout, ConsumptionReportInterval = consumptionReportInterval, NotificationsNewMessageEnabled = notificationsNewMessageEnabled, NotificationsNewMessageTemplate = notificationsNewMessageTemplate, NotificationsAddedToChannelEnabled = notificationsAddedToChannelEnabled, NotificationsAddedToChannelTemplate = notificationsAddedToChannelTemplate, NotificationsRemovedFromChannelEnabled = notificationsRemovedFromChannelEnabled, NotificationsRemovedFromChannelTemplate = notificationsRemovedFromChannelTemplate, NotificationsInvitedToChannelEnabled = notificationsInvitedToChannelEnabled, NotificationsInvitedToChannelTemplate = notificationsInvitedToChannelTemplate, PreWebhookUrl = preWebhookUrl, PostWebhookUrl = postWebhookUrl, WebhookMethod = webhookMethod, WebhookFilters = webhookFilters, WebhooksOnMessageSendUrl = webhooksOnMessageSendUrl, WebhooksOnMessageSendMethod = webhooksOnMessageSendMethod, WebhooksOnMessageSendFormat = webhooksOnMessageSendFormat, WebhooksOnMessageUpdateUrl = webhooksOnMessageUpdateUrl, WebhooksOnMessageUpdateMethod = webhooksOnMessageUpdateMethod, WebhooksOnMessageUpdateFormat = webhooksOnMessageUpdateFormat, WebhooksOnMessageRemoveUrl = webhooksOnMessageRemoveUrl, WebhooksOnMessageRemoveMethod = webhooksOnMessageRemoveMethod, WebhooksOnMessageRemoveFormat = webhooksOnMessageRemoveFormat, WebhooksOnChannelAddUrl = webhooksOnChannelAddUrl, WebhooksOnChannelAddMethod = webhooksOnChannelAddMethod, WebhooksOnChannelAddFormat = webhooksOnChannelAddFormat, WebhooksOnChannelDestroyUrl = webhooksOnChannelDestroyUrl, WebhooksOnChannelDestroyMethod = webhooksOnChannelDestroyMethod, WebhooksOnChannelDestroyFormat = webhooksOnChannelDestroyFormat, WebhooksOnChannelUpdateUrl = webhooksOnChannelUpdateUrl, WebhooksOnChannelUpdateMethod = webhooksOnChannelUpdateMethod, WebhooksOnChannelUpdateFormat = webhooksOnChannelUpdateFormat, WebhooksOnMemberAddUrl = webhooksOnMemberAddUrl, WebhooksOnMemberAddMethod = webhooksOnMemberAddMethod, WebhooksOnMemberAddFormat = webhooksOnMemberAddFormat, WebhooksOnMemberRemoveUrl = webhooksOnMemberRemoveUrl, WebhooksOnMemberRemoveMethod = webhooksOnMemberRemoveMethod, WebhooksOnMemberRemoveFormat = webhooksOnMemberRemoveFormat, WebhooksOnMessageSentUrl = webhooksOnMessageSentUrl, WebhooksOnMessageSentMethod = webhooksOnMessageSentMethod, WebhooksOnMessageSentFormat = webhooksOnMessageSentFormat, WebhooksOnMessageUpdatedUrl = webhooksOnMessageUpdatedUrl, WebhooksOnMessageUpdatedMethod = webhooksOnMessageUpdatedMethod, WebhooksOnMessageUpdatedFormat = webhooksOnMessageUpdatedFormat, WebhooksOnMessageRemovedUrl = webhooksOnMessageRemovedUrl, WebhooksOnMessageRemovedMethod = webhooksOnMessageRemovedMethod, WebhooksOnMessageRemovedFormat = webhooksOnMessageRemovedFormat, WebhooksOnChannelAddedUrl = webhooksOnChannelAddedUrl, WebhooksOnChannelAddedMethod = webhooksOnChannelAddedMethod, WebhooksOnChannelAddedFormat = webhooksOnChannelAddedFormat, WebhooksOnChannelDestroyedUrl = webhooksOnChannelDestroyedUrl, WebhooksOnChannelDestroyedMethod = webhooksOnChannelDestroyedMethod, WebhooksOnChannelDestroyedFormat = webhooksOnChannelDestroyedFormat, WebhooksOnChannelUpdatedUrl = webhooksOnChannelUpdatedUrl, WebhooksOnChannelUpdatedMethod = webhooksOnChannelUpdatedMethod, WebhooksOnChannelUpdatedFormat = webhooksOnChannelUpdatedFormat, WebhooksOnMemberAddedUrl = webhooksOnMemberAddedUrl, WebhooksOnMemberAddedMethod = webhooksOnMemberAddedMethod, WebhooksOnMemberAddedFormat = webhooksOnMemberAddedFormat, WebhooksOnMemberRemovedUrl = webhooksOnMemberRemovedUrl, WebhooksOnMemberRemovedMethod = webhooksOnMemberRemovedMethod, WebhooksOnMemberRemovedFormat = webhooksOnMemberRemovedFormat, LimitsChannelMembers = limitsChannelMembers, LimitsUserChannels = limitsUserChannels}; return await UpdateAsync(options, client); } #endif @@ -603,6 +607,11 @@ public static ServiceResource FromJson(string json) [JsonProperty("consumption_report_interval")] public int? ConsumptionReportInterval { get; private set; } /// + /// The limits + /// + [JsonProperty("limits")] + public object Limits { get; private set; } + /// /// The webhooks /// [JsonProperty("webhooks")] diff --git a/src/Twilio/Rest/IpMessaging/V1/Service/UserResource.cs b/src/Twilio/Rest/IpMessaging/V1/Service/UserResource.cs index b8c040d19..f1b8e0cd3 100644 --- a/src/Twilio/Rest/IpMessaging/V1/Service/UserResource.cs +++ b/src/Twilio/Rest/IpMessaging/V1/Service/UserResource.cs @@ -484,6 +484,11 @@ public static UserResource FromJson(string json) [JsonProperty("date_updated")] public DateTime? DateUpdated { get; private set; } /// + /// The joined_channels_count + /// + [JsonProperty("joined_channels_count")] + public int? JoinedChannelsCount { get; private set; } + /// /// The links /// [JsonProperty("links")] diff --git a/src/Twilio/Rest/IpMessaging/V1/ServiceOptions.cs b/src/Twilio/Rest/IpMessaging/V1/ServiceOptions.cs index 02025f0ff..14c4a3db4 100644 --- a/src/Twilio/Rest/IpMessaging/V1/ServiceOptions.cs +++ b/src/Twilio/Rest/IpMessaging/V1/ServiceOptions.cs @@ -402,6 +402,14 @@ public class UpdateServiceOptions : IOptions /// The webhooks.on_member_removed.format /// public string WebhooksOnMemberRemovedFormat { get; set; } + /// + /// The limits.channel_members + /// + public int? LimitsChannelMembers { get; set; } + /// + /// The limits.user_channels + /// + public int? LimitsUserChannels { get; set; } /// /// Construct a new UpdateServiceOptions @@ -760,6 +768,16 @@ public List> GetParams() p.Add(new KeyValuePair("Webhooks.OnMemberRemoved.Format", WebhooksOnMemberRemovedFormat)); } + if (LimitsChannelMembers != null) + { + p.Add(new KeyValuePair("Limits.ChannelMembers", LimitsChannelMembers.Value.ToString())); + } + + if (LimitsUserChannels != null) + { + p.Add(new KeyValuePair("Limits.UserChannels", LimitsUserChannels.Value.ToString())); + } + return p; } } diff --git a/src/Twilio/Rest/IpMessaging/V1/ServiceResource.cs b/src/Twilio/Rest/IpMessaging/V1/ServiceResource.cs index 185742f03..abd136420 100644 --- a/src/Twilio/Rest/IpMessaging/V1/ServiceResource.cs +++ b/src/Twilio/Rest/IpMessaging/V1/ServiceResource.cs @@ -432,11 +432,13 @@ public static async System.Threading.Tasks.Task UpdateAsync(Upd /// The webhooks.on_member_removed.url /// The webhooks.on_member_removed.method /// The webhooks.on_member_removed.format + /// The limits.channel_members + /// The limits.user_channels /// Client to make requests to Twilio /// A single instance of Service - public static ServiceResource Update(string pathSid, string friendlyName = null, string defaultServiceRoleSid = null, string defaultChannelRoleSid = null, string defaultChannelCreatorRoleSid = null, bool? readStatusEnabled = null, bool? reachabilityEnabled = null, int? typingIndicatorTimeout = null, int? consumptionReportInterval = null, bool? notificationsNewMessageEnabled = null, string notificationsNewMessageTemplate = null, bool? notificationsAddedToChannelEnabled = null, string notificationsAddedToChannelTemplate = null, bool? notificationsRemovedFromChannelEnabled = null, string notificationsRemovedFromChannelTemplate = null, bool? notificationsInvitedToChannelEnabled = null, string notificationsInvitedToChannelTemplate = null, Uri preWebhookUrl = null, Uri postWebhookUrl = null, Twilio.Http.HttpMethod webhookMethod = null, List webhookFilters = null, Uri webhooksOnMessageSendUrl = null, Twilio.Http.HttpMethod webhooksOnMessageSendMethod = null, string webhooksOnMessageSendFormat = null, Uri webhooksOnMessageUpdateUrl = null, Twilio.Http.HttpMethod webhooksOnMessageUpdateMethod = null, string webhooksOnMessageUpdateFormat = null, Uri webhooksOnMessageRemoveUrl = null, Twilio.Http.HttpMethod webhooksOnMessageRemoveMethod = null, string webhooksOnMessageRemoveFormat = null, Uri webhooksOnChannelAddUrl = null, Twilio.Http.HttpMethod webhooksOnChannelAddMethod = null, string webhooksOnChannelAddFormat = null, Uri webhooksOnChannelDestroyUrl = null, Twilio.Http.HttpMethod webhooksOnChannelDestroyMethod = null, string webhooksOnChannelDestroyFormat = null, Uri webhooksOnChannelUpdateUrl = null, Twilio.Http.HttpMethod webhooksOnChannelUpdateMethod = null, string webhooksOnChannelUpdateFormat = null, Uri webhooksOnMemberAddUrl = null, Twilio.Http.HttpMethod webhooksOnMemberAddMethod = null, string webhooksOnMemberAddFormat = null, Uri webhooksOnMemberRemoveUrl = null, Twilio.Http.HttpMethod webhooksOnMemberRemoveMethod = null, string webhooksOnMemberRemoveFormat = null, Uri webhooksOnMessageSentUrl = null, Twilio.Http.HttpMethod webhooksOnMessageSentMethod = null, string webhooksOnMessageSentFormat = null, Uri webhooksOnMessageUpdatedUrl = null, Twilio.Http.HttpMethod webhooksOnMessageUpdatedMethod = null, string webhooksOnMessageUpdatedFormat = null, Uri webhooksOnMessageRemovedUrl = null, Twilio.Http.HttpMethod webhooksOnMessageRemovedMethod = null, string webhooksOnMessageRemovedFormat = null, Uri webhooksOnChannelAddedUrl = null, Twilio.Http.HttpMethod webhooksOnChannelAddedMethod = null, string webhooksOnChannelAddedFormat = null, Uri webhooksOnChannelDestroyedUrl = null, Twilio.Http.HttpMethod webhooksOnChannelDestroyedMethod = null, string webhooksOnChannelDestroyedFormat = null, Uri webhooksOnChannelUpdatedUrl = null, Twilio.Http.HttpMethod webhooksOnChannelUpdatedMethod = null, string webhooksOnChannelUpdatedFormat = null, Uri webhooksOnMemberAddedUrl = null, Twilio.Http.HttpMethod webhooksOnMemberAddedMethod = null, string webhooksOnMemberAddedFormat = null, Uri webhooksOnMemberRemovedUrl = null, Twilio.Http.HttpMethod webhooksOnMemberRemovedMethod = null, string webhooksOnMemberRemovedFormat = null, ITwilioRestClient client = null) + public static ServiceResource Update(string pathSid, string friendlyName = null, string defaultServiceRoleSid = null, string defaultChannelRoleSid = null, string defaultChannelCreatorRoleSid = null, bool? readStatusEnabled = null, bool? reachabilityEnabled = null, int? typingIndicatorTimeout = null, int? consumptionReportInterval = null, bool? notificationsNewMessageEnabled = null, string notificationsNewMessageTemplate = null, bool? notificationsAddedToChannelEnabled = null, string notificationsAddedToChannelTemplate = null, bool? notificationsRemovedFromChannelEnabled = null, string notificationsRemovedFromChannelTemplate = null, bool? notificationsInvitedToChannelEnabled = null, string notificationsInvitedToChannelTemplate = null, Uri preWebhookUrl = null, Uri postWebhookUrl = null, Twilio.Http.HttpMethod webhookMethod = null, List webhookFilters = null, Uri webhooksOnMessageSendUrl = null, Twilio.Http.HttpMethod webhooksOnMessageSendMethod = null, string webhooksOnMessageSendFormat = null, Uri webhooksOnMessageUpdateUrl = null, Twilio.Http.HttpMethod webhooksOnMessageUpdateMethod = null, string webhooksOnMessageUpdateFormat = null, Uri webhooksOnMessageRemoveUrl = null, Twilio.Http.HttpMethod webhooksOnMessageRemoveMethod = null, string webhooksOnMessageRemoveFormat = null, Uri webhooksOnChannelAddUrl = null, Twilio.Http.HttpMethod webhooksOnChannelAddMethod = null, string webhooksOnChannelAddFormat = null, Uri webhooksOnChannelDestroyUrl = null, Twilio.Http.HttpMethod webhooksOnChannelDestroyMethod = null, string webhooksOnChannelDestroyFormat = null, Uri webhooksOnChannelUpdateUrl = null, Twilio.Http.HttpMethod webhooksOnChannelUpdateMethod = null, string webhooksOnChannelUpdateFormat = null, Uri webhooksOnMemberAddUrl = null, Twilio.Http.HttpMethod webhooksOnMemberAddMethod = null, string webhooksOnMemberAddFormat = null, Uri webhooksOnMemberRemoveUrl = null, Twilio.Http.HttpMethod webhooksOnMemberRemoveMethod = null, string webhooksOnMemberRemoveFormat = null, Uri webhooksOnMessageSentUrl = null, Twilio.Http.HttpMethod webhooksOnMessageSentMethod = null, string webhooksOnMessageSentFormat = null, Uri webhooksOnMessageUpdatedUrl = null, Twilio.Http.HttpMethod webhooksOnMessageUpdatedMethod = null, string webhooksOnMessageUpdatedFormat = null, Uri webhooksOnMessageRemovedUrl = null, Twilio.Http.HttpMethod webhooksOnMessageRemovedMethod = null, string webhooksOnMessageRemovedFormat = null, Uri webhooksOnChannelAddedUrl = null, Twilio.Http.HttpMethod webhooksOnChannelAddedMethod = null, string webhooksOnChannelAddedFormat = null, Uri webhooksOnChannelDestroyedUrl = null, Twilio.Http.HttpMethod webhooksOnChannelDestroyedMethod = null, string webhooksOnChannelDestroyedFormat = null, Uri webhooksOnChannelUpdatedUrl = null, Twilio.Http.HttpMethod webhooksOnChannelUpdatedMethod = null, string webhooksOnChannelUpdatedFormat = null, Uri webhooksOnMemberAddedUrl = null, Twilio.Http.HttpMethod webhooksOnMemberAddedMethod = null, string webhooksOnMemberAddedFormat = null, Uri webhooksOnMemberRemovedUrl = null, Twilio.Http.HttpMethod webhooksOnMemberRemovedMethod = null, string webhooksOnMemberRemovedFormat = null, int? limitsChannelMembers = null, int? limitsUserChannels = null, ITwilioRestClient client = null) { - var options = new UpdateServiceOptions(pathSid){FriendlyName = friendlyName, DefaultServiceRoleSid = defaultServiceRoleSid, DefaultChannelRoleSid = defaultChannelRoleSid, DefaultChannelCreatorRoleSid = defaultChannelCreatorRoleSid, ReadStatusEnabled = readStatusEnabled, ReachabilityEnabled = reachabilityEnabled, TypingIndicatorTimeout = typingIndicatorTimeout, ConsumptionReportInterval = consumptionReportInterval, NotificationsNewMessageEnabled = notificationsNewMessageEnabled, NotificationsNewMessageTemplate = notificationsNewMessageTemplate, NotificationsAddedToChannelEnabled = notificationsAddedToChannelEnabled, NotificationsAddedToChannelTemplate = notificationsAddedToChannelTemplate, NotificationsRemovedFromChannelEnabled = notificationsRemovedFromChannelEnabled, NotificationsRemovedFromChannelTemplate = notificationsRemovedFromChannelTemplate, NotificationsInvitedToChannelEnabled = notificationsInvitedToChannelEnabled, NotificationsInvitedToChannelTemplate = notificationsInvitedToChannelTemplate, PreWebhookUrl = preWebhookUrl, PostWebhookUrl = postWebhookUrl, WebhookMethod = webhookMethod, WebhookFilters = webhookFilters, WebhooksOnMessageSendUrl = webhooksOnMessageSendUrl, WebhooksOnMessageSendMethod = webhooksOnMessageSendMethod, WebhooksOnMessageSendFormat = webhooksOnMessageSendFormat, WebhooksOnMessageUpdateUrl = webhooksOnMessageUpdateUrl, WebhooksOnMessageUpdateMethod = webhooksOnMessageUpdateMethod, WebhooksOnMessageUpdateFormat = webhooksOnMessageUpdateFormat, WebhooksOnMessageRemoveUrl = webhooksOnMessageRemoveUrl, WebhooksOnMessageRemoveMethod = webhooksOnMessageRemoveMethod, WebhooksOnMessageRemoveFormat = webhooksOnMessageRemoveFormat, WebhooksOnChannelAddUrl = webhooksOnChannelAddUrl, WebhooksOnChannelAddMethod = webhooksOnChannelAddMethod, WebhooksOnChannelAddFormat = webhooksOnChannelAddFormat, WebhooksOnChannelDestroyUrl = webhooksOnChannelDestroyUrl, WebhooksOnChannelDestroyMethod = webhooksOnChannelDestroyMethod, WebhooksOnChannelDestroyFormat = webhooksOnChannelDestroyFormat, WebhooksOnChannelUpdateUrl = webhooksOnChannelUpdateUrl, WebhooksOnChannelUpdateMethod = webhooksOnChannelUpdateMethod, WebhooksOnChannelUpdateFormat = webhooksOnChannelUpdateFormat, WebhooksOnMemberAddUrl = webhooksOnMemberAddUrl, WebhooksOnMemberAddMethod = webhooksOnMemberAddMethod, WebhooksOnMemberAddFormat = webhooksOnMemberAddFormat, WebhooksOnMemberRemoveUrl = webhooksOnMemberRemoveUrl, WebhooksOnMemberRemoveMethod = webhooksOnMemberRemoveMethod, WebhooksOnMemberRemoveFormat = webhooksOnMemberRemoveFormat, WebhooksOnMessageSentUrl = webhooksOnMessageSentUrl, WebhooksOnMessageSentMethod = webhooksOnMessageSentMethod, WebhooksOnMessageSentFormat = webhooksOnMessageSentFormat, WebhooksOnMessageUpdatedUrl = webhooksOnMessageUpdatedUrl, WebhooksOnMessageUpdatedMethod = webhooksOnMessageUpdatedMethod, WebhooksOnMessageUpdatedFormat = webhooksOnMessageUpdatedFormat, WebhooksOnMessageRemovedUrl = webhooksOnMessageRemovedUrl, WebhooksOnMessageRemovedMethod = webhooksOnMessageRemovedMethod, WebhooksOnMessageRemovedFormat = webhooksOnMessageRemovedFormat, WebhooksOnChannelAddedUrl = webhooksOnChannelAddedUrl, WebhooksOnChannelAddedMethod = webhooksOnChannelAddedMethod, WebhooksOnChannelAddedFormat = webhooksOnChannelAddedFormat, WebhooksOnChannelDestroyedUrl = webhooksOnChannelDestroyedUrl, WebhooksOnChannelDestroyedMethod = webhooksOnChannelDestroyedMethod, WebhooksOnChannelDestroyedFormat = webhooksOnChannelDestroyedFormat, WebhooksOnChannelUpdatedUrl = webhooksOnChannelUpdatedUrl, WebhooksOnChannelUpdatedMethod = webhooksOnChannelUpdatedMethod, WebhooksOnChannelUpdatedFormat = webhooksOnChannelUpdatedFormat, WebhooksOnMemberAddedUrl = webhooksOnMemberAddedUrl, WebhooksOnMemberAddedMethod = webhooksOnMemberAddedMethod, WebhooksOnMemberAddedFormat = webhooksOnMemberAddedFormat, WebhooksOnMemberRemovedUrl = webhooksOnMemberRemovedUrl, WebhooksOnMemberRemovedMethod = webhooksOnMemberRemovedMethod, WebhooksOnMemberRemovedFormat = webhooksOnMemberRemovedFormat}; + var options = new UpdateServiceOptions(pathSid){FriendlyName = friendlyName, DefaultServiceRoleSid = defaultServiceRoleSid, DefaultChannelRoleSid = defaultChannelRoleSid, DefaultChannelCreatorRoleSid = defaultChannelCreatorRoleSid, ReadStatusEnabled = readStatusEnabled, ReachabilityEnabled = reachabilityEnabled, TypingIndicatorTimeout = typingIndicatorTimeout, ConsumptionReportInterval = consumptionReportInterval, NotificationsNewMessageEnabled = notificationsNewMessageEnabled, NotificationsNewMessageTemplate = notificationsNewMessageTemplate, NotificationsAddedToChannelEnabled = notificationsAddedToChannelEnabled, NotificationsAddedToChannelTemplate = notificationsAddedToChannelTemplate, NotificationsRemovedFromChannelEnabled = notificationsRemovedFromChannelEnabled, NotificationsRemovedFromChannelTemplate = notificationsRemovedFromChannelTemplate, NotificationsInvitedToChannelEnabled = notificationsInvitedToChannelEnabled, NotificationsInvitedToChannelTemplate = notificationsInvitedToChannelTemplate, PreWebhookUrl = preWebhookUrl, PostWebhookUrl = postWebhookUrl, WebhookMethod = webhookMethod, WebhookFilters = webhookFilters, WebhooksOnMessageSendUrl = webhooksOnMessageSendUrl, WebhooksOnMessageSendMethod = webhooksOnMessageSendMethod, WebhooksOnMessageSendFormat = webhooksOnMessageSendFormat, WebhooksOnMessageUpdateUrl = webhooksOnMessageUpdateUrl, WebhooksOnMessageUpdateMethod = webhooksOnMessageUpdateMethod, WebhooksOnMessageUpdateFormat = webhooksOnMessageUpdateFormat, WebhooksOnMessageRemoveUrl = webhooksOnMessageRemoveUrl, WebhooksOnMessageRemoveMethod = webhooksOnMessageRemoveMethod, WebhooksOnMessageRemoveFormat = webhooksOnMessageRemoveFormat, WebhooksOnChannelAddUrl = webhooksOnChannelAddUrl, WebhooksOnChannelAddMethod = webhooksOnChannelAddMethod, WebhooksOnChannelAddFormat = webhooksOnChannelAddFormat, WebhooksOnChannelDestroyUrl = webhooksOnChannelDestroyUrl, WebhooksOnChannelDestroyMethod = webhooksOnChannelDestroyMethod, WebhooksOnChannelDestroyFormat = webhooksOnChannelDestroyFormat, WebhooksOnChannelUpdateUrl = webhooksOnChannelUpdateUrl, WebhooksOnChannelUpdateMethod = webhooksOnChannelUpdateMethod, WebhooksOnChannelUpdateFormat = webhooksOnChannelUpdateFormat, WebhooksOnMemberAddUrl = webhooksOnMemberAddUrl, WebhooksOnMemberAddMethod = webhooksOnMemberAddMethod, WebhooksOnMemberAddFormat = webhooksOnMemberAddFormat, WebhooksOnMemberRemoveUrl = webhooksOnMemberRemoveUrl, WebhooksOnMemberRemoveMethod = webhooksOnMemberRemoveMethod, WebhooksOnMemberRemoveFormat = webhooksOnMemberRemoveFormat, WebhooksOnMessageSentUrl = webhooksOnMessageSentUrl, WebhooksOnMessageSentMethod = webhooksOnMessageSentMethod, WebhooksOnMessageSentFormat = webhooksOnMessageSentFormat, WebhooksOnMessageUpdatedUrl = webhooksOnMessageUpdatedUrl, WebhooksOnMessageUpdatedMethod = webhooksOnMessageUpdatedMethod, WebhooksOnMessageUpdatedFormat = webhooksOnMessageUpdatedFormat, WebhooksOnMessageRemovedUrl = webhooksOnMessageRemovedUrl, WebhooksOnMessageRemovedMethod = webhooksOnMessageRemovedMethod, WebhooksOnMessageRemovedFormat = webhooksOnMessageRemovedFormat, WebhooksOnChannelAddedUrl = webhooksOnChannelAddedUrl, WebhooksOnChannelAddedMethod = webhooksOnChannelAddedMethod, WebhooksOnChannelAddedFormat = webhooksOnChannelAddedFormat, WebhooksOnChannelDestroyedUrl = webhooksOnChannelDestroyedUrl, WebhooksOnChannelDestroyedMethod = webhooksOnChannelDestroyedMethod, WebhooksOnChannelDestroyedFormat = webhooksOnChannelDestroyedFormat, WebhooksOnChannelUpdatedUrl = webhooksOnChannelUpdatedUrl, WebhooksOnChannelUpdatedMethod = webhooksOnChannelUpdatedMethod, WebhooksOnChannelUpdatedFormat = webhooksOnChannelUpdatedFormat, WebhooksOnMemberAddedUrl = webhooksOnMemberAddedUrl, WebhooksOnMemberAddedMethod = webhooksOnMemberAddedMethod, WebhooksOnMemberAddedFormat = webhooksOnMemberAddedFormat, WebhooksOnMemberRemovedUrl = webhooksOnMemberRemovedUrl, WebhooksOnMemberRemovedMethod = webhooksOnMemberRemovedMethod, WebhooksOnMemberRemovedFormat = webhooksOnMemberRemovedFormat, LimitsChannelMembers = limitsChannelMembers, LimitsUserChannels = limitsUserChannels}; return Update(options, client); } @@ -514,11 +516,13 @@ public static ServiceResource Update(string pathSid, string friendlyName = null, /// The webhooks.on_member_removed.url /// The webhooks.on_member_removed.method /// The webhooks.on_member_removed.format + /// The limits.channel_members + /// The limits.user_channels /// Client to make requests to Twilio /// Task that resolves to A single instance of Service - public static async System.Threading.Tasks.Task UpdateAsync(string pathSid, string friendlyName = null, string defaultServiceRoleSid = null, string defaultChannelRoleSid = null, string defaultChannelCreatorRoleSid = null, bool? readStatusEnabled = null, bool? reachabilityEnabled = null, int? typingIndicatorTimeout = null, int? consumptionReportInterval = null, bool? notificationsNewMessageEnabled = null, string notificationsNewMessageTemplate = null, bool? notificationsAddedToChannelEnabled = null, string notificationsAddedToChannelTemplate = null, bool? notificationsRemovedFromChannelEnabled = null, string notificationsRemovedFromChannelTemplate = null, bool? notificationsInvitedToChannelEnabled = null, string notificationsInvitedToChannelTemplate = null, Uri preWebhookUrl = null, Uri postWebhookUrl = null, Twilio.Http.HttpMethod webhookMethod = null, List webhookFilters = null, Uri webhooksOnMessageSendUrl = null, Twilio.Http.HttpMethod webhooksOnMessageSendMethod = null, string webhooksOnMessageSendFormat = null, Uri webhooksOnMessageUpdateUrl = null, Twilio.Http.HttpMethod webhooksOnMessageUpdateMethod = null, string webhooksOnMessageUpdateFormat = null, Uri webhooksOnMessageRemoveUrl = null, Twilio.Http.HttpMethod webhooksOnMessageRemoveMethod = null, string webhooksOnMessageRemoveFormat = null, Uri webhooksOnChannelAddUrl = null, Twilio.Http.HttpMethod webhooksOnChannelAddMethod = null, string webhooksOnChannelAddFormat = null, Uri webhooksOnChannelDestroyUrl = null, Twilio.Http.HttpMethod webhooksOnChannelDestroyMethod = null, string webhooksOnChannelDestroyFormat = null, Uri webhooksOnChannelUpdateUrl = null, Twilio.Http.HttpMethod webhooksOnChannelUpdateMethod = null, string webhooksOnChannelUpdateFormat = null, Uri webhooksOnMemberAddUrl = null, Twilio.Http.HttpMethod webhooksOnMemberAddMethod = null, string webhooksOnMemberAddFormat = null, Uri webhooksOnMemberRemoveUrl = null, Twilio.Http.HttpMethod webhooksOnMemberRemoveMethod = null, string webhooksOnMemberRemoveFormat = null, Uri webhooksOnMessageSentUrl = null, Twilio.Http.HttpMethod webhooksOnMessageSentMethod = null, string webhooksOnMessageSentFormat = null, Uri webhooksOnMessageUpdatedUrl = null, Twilio.Http.HttpMethod webhooksOnMessageUpdatedMethod = null, string webhooksOnMessageUpdatedFormat = null, Uri webhooksOnMessageRemovedUrl = null, Twilio.Http.HttpMethod webhooksOnMessageRemovedMethod = null, string webhooksOnMessageRemovedFormat = null, Uri webhooksOnChannelAddedUrl = null, Twilio.Http.HttpMethod webhooksOnChannelAddedMethod = null, string webhooksOnChannelAddedFormat = null, Uri webhooksOnChannelDestroyedUrl = null, Twilio.Http.HttpMethod webhooksOnChannelDestroyedMethod = null, string webhooksOnChannelDestroyedFormat = null, Uri webhooksOnChannelUpdatedUrl = null, Twilio.Http.HttpMethod webhooksOnChannelUpdatedMethod = null, string webhooksOnChannelUpdatedFormat = null, Uri webhooksOnMemberAddedUrl = null, Twilio.Http.HttpMethod webhooksOnMemberAddedMethod = null, string webhooksOnMemberAddedFormat = null, Uri webhooksOnMemberRemovedUrl = null, Twilio.Http.HttpMethod webhooksOnMemberRemovedMethod = null, string webhooksOnMemberRemovedFormat = null, ITwilioRestClient client = null) + public static async System.Threading.Tasks.Task UpdateAsync(string pathSid, string friendlyName = null, string defaultServiceRoleSid = null, string defaultChannelRoleSid = null, string defaultChannelCreatorRoleSid = null, bool? readStatusEnabled = null, bool? reachabilityEnabled = null, int? typingIndicatorTimeout = null, int? consumptionReportInterval = null, bool? notificationsNewMessageEnabled = null, string notificationsNewMessageTemplate = null, bool? notificationsAddedToChannelEnabled = null, string notificationsAddedToChannelTemplate = null, bool? notificationsRemovedFromChannelEnabled = null, string notificationsRemovedFromChannelTemplate = null, bool? notificationsInvitedToChannelEnabled = null, string notificationsInvitedToChannelTemplate = null, Uri preWebhookUrl = null, Uri postWebhookUrl = null, Twilio.Http.HttpMethod webhookMethod = null, List webhookFilters = null, Uri webhooksOnMessageSendUrl = null, Twilio.Http.HttpMethod webhooksOnMessageSendMethod = null, string webhooksOnMessageSendFormat = null, Uri webhooksOnMessageUpdateUrl = null, Twilio.Http.HttpMethod webhooksOnMessageUpdateMethod = null, string webhooksOnMessageUpdateFormat = null, Uri webhooksOnMessageRemoveUrl = null, Twilio.Http.HttpMethod webhooksOnMessageRemoveMethod = null, string webhooksOnMessageRemoveFormat = null, Uri webhooksOnChannelAddUrl = null, Twilio.Http.HttpMethod webhooksOnChannelAddMethod = null, string webhooksOnChannelAddFormat = null, Uri webhooksOnChannelDestroyUrl = null, Twilio.Http.HttpMethod webhooksOnChannelDestroyMethod = null, string webhooksOnChannelDestroyFormat = null, Uri webhooksOnChannelUpdateUrl = null, Twilio.Http.HttpMethod webhooksOnChannelUpdateMethod = null, string webhooksOnChannelUpdateFormat = null, Uri webhooksOnMemberAddUrl = null, Twilio.Http.HttpMethod webhooksOnMemberAddMethod = null, string webhooksOnMemberAddFormat = null, Uri webhooksOnMemberRemoveUrl = null, Twilio.Http.HttpMethod webhooksOnMemberRemoveMethod = null, string webhooksOnMemberRemoveFormat = null, Uri webhooksOnMessageSentUrl = null, Twilio.Http.HttpMethod webhooksOnMessageSentMethod = null, string webhooksOnMessageSentFormat = null, Uri webhooksOnMessageUpdatedUrl = null, Twilio.Http.HttpMethod webhooksOnMessageUpdatedMethod = null, string webhooksOnMessageUpdatedFormat = null, Uri webhooksOnMessageRemovedUrl = null, Twilio.Http.HttpMethod webhooksOnMessageRemovedMethod = null, string webhooksOnMessageRemovedFormat = null, Uri webhooksOnChannelAddedUrl = null, Twilio.Http.HttpMethod webhooksOnChannelAddedMethod = null, string webhooksOnChannelAddedFormat = null, Uri webhooksOnChannelDestroyedUrl = null, Twilio.Http.HttpMethod webhooksOnChannelDestroyedMethod = null, string webhooksOnChannelDestroyedFormat = null, Uri webhooksOnChannelUpdatedUrl = null, Twilio.Http.HttpMethod webhooksOnChannelUpdatedMethod = null, string webhooksOnChannelUpdatedFormat = null, Uri webhooksOnMemberAddedUrl = null, Twilio.Http.HttpMethod webhooksOnMemberAddedMethod = null, string webhooksOnMemberAddedFormat = null, Uri webhooksOnMemberRemovedUrl = null, Twilio.Http.HttpMethod webhooksOnMemberRemovedMethod = null, string webhooksOnMemberRemovedFormat = null, int? limitsChannelMembers = null, int? limitsUserChannels = null, ITwilioRestClient client = null) { - var options = new UpdateServiceOptions(pathSid){FriendlyName = friendlyName, DefaultServiceRoleSid = defaultServiceRoleSid, DefaultChannelRoleSid = defaultChannelRoleSid, DefaultChannelCreatorRoleSid = defaultChannelCreatorRoleSid, ReadStatusEnabled = readStatusEnabled, ReachabilityEnabled = reachabilityEnabled, TypingIndicatorTimeout = typingIndicatorTimeout, ConsumptionReportInterval = consumptionReportInterval, NotificationsNewMessageEnabled = notificationsNewMessageEnabled, NotificationsNewMessageTemplate = notificationsNewMessageTemplate, NotificationsAddedToChannelEnabled = notificationsAddedToChannelEnabled, NotificationsAddedToChannelTemplate = notificationsAddedToChannelTemplate, NotificationsRemovedFromChannelEnabled = notificationsRemovedFromChannelEnabled, NotificationsRemovedFromChannelTemplate = notificationsRemovedFromChannelTemplate, NotificationsInvitedToChannelEnabled = notificationsInvitedToChannelEnabled, NotificationsInvitedToChannelTemplate = notificationsInvitedToChannelTemplate, PreWebhookUrl = preWebhookUrl, PostWebhookUrl = postWebhookUrl, WebhookMethod = webhookMethod, WebhookFilters = webhookFilters, WebhooksOnMessageSendUrl = webhooksOnMessageSendUrl, WebhooksOnMessageSendMethod = webhooksOnMessageSendMethod, WebhooksOnMessageSendFormat = webhooksOnMessageSendFormat, WebhooksOnMessageUpdateUrl = webhooksOnMessageUpdateUrl, WebhooksOnMessageUpdateMethod = webhooksOnMessageUpdateMethod, WebhooksOnMessageUpdateFormat = webhooksOnMessageUpdateFormat, WebhooksOnMessageRemoveUrl = webhooksOnMessageRemoveUrl, WebhooksOnMessageRemoveMethod = webhooksOnMessageRemoveMethod, WebhooksOnMessageRemoveFormat = webhooksOnMessageRemoveFormat, WebhooksOnChannelAddUrl = webhooksOnChannelAddUrl, WebhooksOnChannelAddMethod = webhooksOnChannelAddMethod, WebhooksOnChannelAddFormat = webhooksOnChannelAddFormat, WebhooksOnChannelDestroyUrl = webhooksOnChannelDestroyUrl, WebhooksOnChannelDestroyMethod = webhooksOnChannelDestroyMethod, WebhooksOnChannelDestroyFormat = webhooksOnChannelDestroyFormat, WebhooksOnChannelUpdateUrl = webhooksOnChannelUpdateUrl, WebhooksOnChannelUpdateMethod = webhooksOnChannelUpdateMethod, WebhooksOnChannelUpdateFormat = webhooksOnChannelUpdateFormat, WebhooksOnMemberAddUrl = webhooksOnMemberAddUrl, WebhooksOnMemberAddMethod = webhooksOnMemberAddMethod, WebhooksOnMemberAddFormat = webhooksOnMemberAddFormat, WebhooksOnMemberRemoveUrl = webhooksOnMemberRemoveUrl, WebhooksOnMemberRemoveMethod = webhooksOnMemberRemoveMethod, WebhooksOnMemberRemoveFormat = webhooksOnMemberRemoveFormat, WebhooksOnMessageSentUrl = webhooksOnMessageSentUrl, WebhooksOnMessageSentMethod = webhooksOnMessageSentMethod, WebhooksOnMessageSentFormat = webhooksOnMessageSentFormat, WebhooksOnMessageUpdatedUrl = webhooksOnMessageUpdatedUrl, WebhooksOnMessageUpdatedMethod = webhooksOnMessageUpdatedMethod, WebhooksOnMessageUpdatedFormat = webhooksOnMessageUpdatedFormat, WebhooksOnMessageRemovedUrl = webhooksOnMessageRemovedUrl, WebhooksOnMessageRemovedMethod = webhooksOnMessageRemovedMethod, WebhooksOnMessageRemovedFormat = webhooksOnMessageRemovedFormat, WebhooksOnChannelAddedUrl = webhooksOnChannelAddedUrl, WebhooksOnChannelAddedMethod = webhooksOnChannelAddedMethod, WebhooksOnChannelAddedFormat = webhooksOnChannelAddedFormat, WebhooksOnChannelDestroyedUrl = webhooksOnChannelDestroyedUrl, WebhooksOnChannelDestroyedMethod = webhooksOnChannelDestroyedMethod, WebhooksOnChannelDestroyedFormat = webhooksOnChannelDestroyedFormat, WebhooksOnChannelUpdatedUrl = webhooksOnChannelUpdatedUrl, WebhooksOnChannelUpdatedMethod = webhooksOnChannelUpdatedMethod, WebhooksOnChannelUpdatedFormat = webhooksOnChannelUpdatedFormat, WebhooksOnMemberAddedUrl = webhooksOnMemberAddedUrl, WebhooksOnMemberAddedMethod = webhooksOnMemberAddedMethod, WebhooksOnMemberAddedFormat = webhooksOnMemberAddedFormat, WebhooksOnMemberRemovedUrl = webhooksOnMemberRemovedUrl, WebhooksOnMemberRemovedMethod = webhooksOnMemberRemovedMethod, WebhooksOnMemberRemovedFormat = webhooksOnMemberRemovedFormat}; + var options = new UpdateServiceOptions(pathSid){FriendlyName = friendlyName, DefaultServiceRoleSid = defaultServiceRoleSid, DefaultChannelRoleSid = defaultChannelRoleSid, DefaultChannelCreatorRoleSid = defaultChannelCreatorRoleSid, ReadStatusEnabled = readStatusEnabled, ReachabilityEnabled = reachabilityEnabled, TypingIndicatorTimeout = typingIndicatorTimeout, ConsumptionReportInterval = consumptionReportInterval, NotificationsNewMessageEnabled = notificationsNewMessageEnabled, NotificationsNewMessageTemplate = notificationsNewMessageTemplate, NotificationsAddedToChannelEnabled = notificationsAddedToChannelEnabled, NotificationsAddedToChannelTemplate = notificationsAddedToChannelTemplate, NotificationsRemovedFromChannelEnabled = notificationsRemovedFromChannelEnabled, NotificationsRemovedFromChannelTemplate = notificationsRemovedFromChannelTemplate, NotificationsInvitedToChannelEnabled = notificationsInvitedToChannelEnabled, NotificationsInvitedToChannelTemplate = notificationsInvitedToChannelTemplate, PreWebhookUrl = preWebhookUrl, PostWebhookUrl = postWebhookUrl, WebhookMethod = webhookMethod, WebhookFilters = webhookFilters, WebhooksOnMessageSendUrl = webhooksOnMessageSendUrl, WebhooksOnMessageSendMethod = webhooksOnMessageSendMethod, WebhooksOnMessageSendFormat = webhooksOnMessageSendFormat, WebhooksOnMessageUpdateUrl = webhooksOnMessageUpdateUrl, WebhooksOnMessageUpdateMethod = webhooksOnMessageUpdateMethod, WebhooksOnMessageUpdateFormat = webhooksOnMessageUpdateFormat, WebhooksOnMessageRemoveUrl = webhooksOnMessageRemoveUrl, WebhooksOnMessageRemoveMethod = webhooksOnMessageRemoveMethod, WebhooksOnMessageRemoveFormat = webhooksOnMessageRemoveFormat, WebhooksOnChannelAddUrl = webhooksOnChannelAddUrl, WebhooksOnChannelAddMethod = webhooksOnChannelAddMethod, WebhooksOnChannelAddFormat = webhooksOnChannelAddFormat, WebhooksOnChannelDestroyUrl = webhooksOnChannelDestroyUrl, WebhooksOnChannelDestroyMethod = webhooksOnChannelDestroyMethod, WebhooksOnChannelDestroyFormat = webhooksOnChannelDestroyFormat, WebhooksOnChannelUpdateUrl = webhooksOnChannelUpdateUrl, WebhooksOnChannelUpdateMethod = webhooksOnChannelUpdateMethod, WebhooksOnChannelUpdateFormat = webhooksOnChannelUpdateFormat, WebhooksOnMemberAddUrl = webhooksOnMemberAddUrl, WebhooksOnMemberAddMethod = webhooksOnMemberAddMethod, WebhooksOnMemberAddFormat = webhooksOnMemberAddFormat, WebhooksOnMemberRemoveUrl = webhooksOnMemberRemoveUrl, WebhooksOnMemberRemoveMethod = webhooksOnMemberRemoveMethod, WebhooksOnMemberRemoveFormat = webhooksOnMemberRemoveFormat, WebhooksOnMessageSentUrl = webhooksOnMessageSentUrl, WebhooksOnMessageSentMethod = webhooksOnMessageSentMethod, WebhooksOnMessageSentFormat = webhooksOnMessageSentFormat, WebhooksOnMessageUpdatedUrl = webhooksOnMessageUpdatedUrl, WebhooksOnMessageUpdatedMethod = webhooksOnMessageUpdatedMethod, WebhooksOnMessageUpdatedFormat = webhooksOnMessageUpdatedFormat, WebhooksOnMessageRemovedUrl = webhooksOnMessageRemovedUrl, WebhooksOnMessageRemovedMethod = webhooksOnMessageRemovedMethod, WebhooksOnMessageRemovedFormat = webhooksOnMessageRemovedFormat, WebhooksOnChannelAddedUrl = webhooksOnChannelAddedUrl, WebhooksOnChannelAddedMethod = webhooksOnChannelAddedMethod, WebhooksOnChannelAddedFormat = webhooksOnChannelAddedFormat, WebhooksOnChannelDestroyedUrl = webhooksOnChannelDestroyedUrl, WebhooksOnChannelDestroyedMethod = webhooksOnChannelDestroyedMethod, WebhooksOnChannelDestroyedFormat = webhooksOnChannelDestroyedFormat, WebhooksOnChannelUpdatedUrl = webhooksOnChannelUpdatedUrl, WebhooksOnChannelUpdatedMethod = webhooksOnChannelUpdatedMethod, WebhooksOnChannelUpdatedFormat = webhooksOnChannelUpdatedFormat, WebhooksOnMemberAddedUrl = webhooksOnMemberAddedUrl, WebhooksOnMemberAddedMethod = webhooksOnMemberAddedMethod, WebhooksOnMemberAddedFormat = webhooksOnMemberAddedFormat, WebhooksOnMemberRemovedUrl = webhooksOnMemberRemovedUrl, WebhooksOnMemberRemovedMethod = webhooksOnMemberRemovedMethod, WebhooksOnMemberRemovedFormat = webhooksOnMemberRemovedFormat, LimitsChannelMembers = limitsChannelMembers, LimitsUserChannels = limitsUserChannels}; return await UpdateAsync(options, client); } #endif @@ -603,6 +607,11 @@ public static ServiceResource FromJson(string json) [JsonProperty("consumption_report_interval")] public int? ConsumptionReportInterval { get; private set; } /// + /// The limits + /// + [JsonProperty("limits")] + public object Limits { get; private set; } + /// /// The webhooks /// [JsonProperty("webhooks")] diff --git a/src/Twilio/Rest/Taskrouter/V1/Workspace/TaskResource.cs b/src/Twilio/Rest/Taskrouter/V1/Workspace/TaskResource.cs index c75e9cf33..ed8c4c99f 100644 --- a/src/Twilio/Rest/Taskrouter/V1/Workspace/TaskResource.cs +++ b/src/Twilio/Rest/Taskrouter/V1/Workspace/TaskResource.cs @@ -26,6 +26,7 @@ public StatusEnum() {} public static readonly StatusEnum Assigned = new StatusEnum("assigned"); public static readonly StatusEnum Canceled = new StatusEnum("canceled"); public static readonly StatusEnum Completed = new StatusEnum("completed"); + public static readonly StatusEnum Wrapping = new StatusEnum("wrapping"); } private static Request BuildFetchRequest(FetchTaskOptions options, ITwilioRestClient client) diff --git a/src/Twilio/Twilio.csproj b/src/Twilio/Twilio.csproj index 438710da7..1dc47f10d 100644 --- a/src/Twilio/Twilio.csproj +++ b/src/Twilio/Twilio.csproj @@ -7,7 +7,7 @@ Copyright © Twilio Twilio en-US - 5.1.1 + 5.2.0 Twilio $(NoWarn);CS1591 false diff --git a/test/Twilio.Test/Rest/Chat/V1/Service/UserResourceTest.cs b/test/Twilio.Test/Rest/Chat/V1/Service/UserResourceTest.cs index e8c331477..aa35b7af7 100644 --- a/test/Twilio.Test/Rest/Chat/V1/Service/UserResourceTest.cs +++ b/test/Twilio.Test/Rest/Chat/V1/Service/UserResourceTest.cs @@ -44,7 +44,7 @@ public void TestFetchResponse() twilioRestClient.Request(Arg.Any()) .Returns(new Response( System.Net.HttpStatusCode.OK, - "{\"sid\": \"USaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"account_sid\": \"ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"service_sid\": \"ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"role_sid\": \"RLaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"identity\": \"jing\",\"attributes\": null,\"is_online\": true,\"is_notifiable\": null,\"friendly_name\": null,\"date_created\": \"2016-03-24T21:05:19Z\",\"date_updated\": \"2016-03-24T21:05:19Z\",\"links\": {\"user_channels\": \"https://ip-messaging.twilio.com/v1/Services/ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Users/USaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Channels\"},\"url\": \"https://ip-messaging.twilio.com/v1/Services/ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Users/USaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\"}" + "{\"sid\": \"USaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"account_sid\": \"ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"service_sid\": \"ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"role_sid\": \"RLaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"identity\": \"jing\",\"attributes\": null,\"is_online\": true,\"is_notifiable\": null,\"friendly_name\": null,\"joined_channels_count\": 0,\"date_created\": \"2016-03-24T21:05:19Z\",\"date_updated\": \"2016-03-24T21:05:19Z\",\"links\": {\"user_channels\": \"https://ip-messaging.twilio.com/v1/Services/ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Users/USaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Channels\"},\"url\": \"https://ip-messaging.twilio.com/v1/Services/ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Users/USaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\"}" )); var response = UserResource.Fetch("ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa", "USaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa", client: twilioRestClient); @@ -117,7 +117,7 @@ public void TestCreateResponse() twilioRestClient.Request(Arg.Any()) .Returns(new Response( System.Net.HttpStatusCode.Created, - "{\"sid\": \"USaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"account_sid\": \"ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"service_sid\": \"ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"role_sid\": \"RLaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"identity\": \"jing\",\"attributes\": null,\"is_online\": true,\"is_notifiable\": null,\"friendly_name\": null,\"date_created\": \"2016-03-24T21:05:19Z\",\"date_updated\": \"2016-03-24T21:05:19Z\",\"links\": {\"user_channels\": \"https://ip-messaging.twilio.com/v1/Services/ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Users/USaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Channels\"},\"url\": \"https://ip-messaging.twilio.com/v1/Services/ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Users/USaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\"}" + "{\"sid\": \"USaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"account_sid\": \"ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"service_sid\": \"ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"role_sid\": \"RLaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"identity\": \"jing\",\"attributes\": null,\"is_online\": true,\"is_notifiable\": null,\"friendly_name\": null,\"joined_channels_count\": 0,\"date_created\": \"2016-03-24T21:05:19Z\",\"date_updated\": \"2016-03-24T21:05:19Z\",\"links\": {\"user_channels\": \"https://ip-messaging.twilio.com/v1/Services/ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Users/USaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Channels\"},\"url\": \"https://ip-messaging.twilio.com/v1/Services/ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Users/USaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\"}" )); var response = UserResource.Create("ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa", "Identity", client: twilioRestClient); @@ -153,7 +153,7 @@ public void TestReadFullResponse() twilioRestClient.Request(Arg.Any()) .Returns(new Response( System.Net.HttpStatusCode.OK, - "{\"meta\": {\"page\": 0,\"page_size\": 50,\"first_page_url\": \"https://ip-messaging.twilio.com/v1/Services/ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Users?PageSize=50&Page=0\",\"previous_page_url\": null,\"url\": \"https://ip-messaging.twilio.com/v1/Services/ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Users?PageSize=50&Page=0\",\"next_page_url\": null,\"key\": \"users\"},\"users\": [{\"sid\": \"USaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"account_sid\": \"ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"service_sid\": \"ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"role_sid\": \"RLaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"identity\": \"jing\",\"attributes\": null,\"is_online\": true,\"is_notifiable\": null,\"friendly_name\": null,\"date_created\": \"2016-03-24T21:05:19Z\",\"date_updated\": \"2016-03-24T21:05:19Z\",\"links\": {\"user_channels\": \"https://ip-messaging.twilio.com/v1/Services/ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Users/USaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Channels\"},\"url\": \"https://ip-messaging.twilio.com/v1/Services/ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Users/USaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\"}]}" + "{\"meta\": {\"page\": 0,\"page_size\": 50,\"first_page_url\": \"https://ip-messaging.twilio.com/v1/Services/ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Users?PageSize=50&Page=0\",\"previous_page_url\": null,\"url\": \"https://ip-messaging.twilio.com/v1/Services/ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Users?PageSize=50&Page=0\",\"next_page_url\": null,\"key\": \"users\"},\"users\": [{\"sid\": \"USaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"account_sid\": \"ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"service_sid\": \"ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"role_sid\": \"RLaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"identity\": \"jing\",\"attributes\": null,\"is_online\": true,\"is_notifiable\": null,\"friendly_name\": null,\"date_created\": \"2016-03-24T21:05:19Z\",\"date_updated\": \"2016-03-24T21:05:19Z\",\"joined_channels_count\": 0,\"links\": {\"user_channels\": \"https://ip-messaging.twilio.com/v1/Services/ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Users/USaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Channels\"},\"url\": \"https://ip-messaging.twilio.com/v1/Services/ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Users/USaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\"}]}" )); var response = UserResource.Read("ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa", client: twilioRestClient); @@ -204,7 +204,7 @@ public void TestUpdateResponse() twilioRestClient.Request(Arg.Any()) .Returns(new Response( System.Net.HttpStatusCode.OK, - "{\"sid\": \"USaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"account_sid\": \"ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"service_sid\": \"ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"role_sid\": \"RLaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"identity\": \"jing\",\"attributes\": null,\"is_online\": true,\"is_notifiable\": null,\"friendly_name\": null,\"date_created\": \"2016-03-24T21:05:19Z\",\"date_updated\": \"2016-03-24T21:05:19Z\",\"links\": {\"user_channels\": \"https://ip-messaging.twilio.com/v1/Services/ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Users/USaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Channels\"},\"url\": \"https://ip-messaging.twilio.com/v1/Services/ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Users/USaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\"}" + "{\"sid\": \"USaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"account_sid\": \"ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"service_sid\": \"ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"role_sid\": \"RLaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"identity\": \"jing\",\"attributes\": null,\"is_online\": true,\"is_notifiable\": null,\"friendly_name\": null,\"joined_channels_count\": 0,\"date_created\": \"2016-03-24T21:05:19Z\",\"date_updated\": \"2016-03-24T21:05:19Z\",\"links\": {\"user_channels\": \"https://ip-messaging.twilio.com/v1/Services/ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Users/USaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Channels\"},\"url\": \"https://ip-messaging.twilio.com/v1/Services/ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Users/USaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\"}" )); var response = UserResource.Update("ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa", "USaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa", client: twilioRestClient); diff --git a/test/Twilio.Test/Rest/Chat/V1/ServiceResourceTest.cs b/test/Twilio.Test/Rest/Chat/V1/ServiceResourceTest.cs index c09a3f04b..6ecafd868 100644 --- a/test/Twilio.Test/Rest/Chat/V1/ServiceResourceTest.cs +++ b/test/Twilio.Test/Rest/Chat/V1/ServiceResourceTest.cs @@ -44,7 +44,7 @@ public void TestFetchResponse() twilioRestClient.Request(Arg.Any()) .Returns(new Response( System.Net.HttpStatusCode.OK, - "{\"account_sid\": \"ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"consumption_report_interval\": 100,\"date_created\": \"2015-07-30T20:00:00Z\",\"date_updated\": \"2015-07-30T20:00:00Z\",\"default_channel_creator_role_sid\": \"RLaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"default_channel_role_sid\": \"RLaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"default_service_role_sid\": \"RLaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"friendly_name\": \"friendly_name\",\"links\": {},\"notifications\": {},\"post_webhook_url\": \"post_webhook_url\",\"pre_webhook_url\": \"pre_webhook_url\",\"reachability_enabled\": false,\"read_status_enabled\": false,\"sid\": \"ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"typing_indicator_timeout\": 100,\"url\": \"http://www.example.com\",\"webhook_filters\": [\"webhook_filters\"],\"webhook_method\": \"webhook_method\",\"webhooks\": {}}" + "{\"account_sid\": \"ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"consumption_report_interval\": 100,\"date_created\": \"2015-07-30T20:00:00Z\",\"date_updated\": \"2015-07-30T20:00:00Z\",\"default_channel_creator_role_sid\": \"RLaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"default_channel_role_sid\": \"RLaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"default_service_role_sid\": \"RLaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"friendly_name\": \"friendly_name\",\"limits\": {\"actions_per_second\": 20,\"channel_members\": 100,\"user_channels\": 250},\"links\": {},\"notifications\": {},\"post_webhook_url\": \"post_webhook_url\",\"pre_webhook_url\": \"pre_webhook_url\",\"reachability_enabled\": false,\"read_status_enabled\": false,\"sid\": \"ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"typing_indicator_timeout\": 100,\"url\": \"http://www.example.com\",\"webhook_filters\": [\"webhook_filters\"],\"webhook_method\": \"webhook_method\",\"webhooks\": {}}" )); var response = ServiceResource.Fetch("ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa", client: twilioRestClient); @@ -117,7 +117,7 @@ public void TestCreateResponse() twilioRestClient.Request(Arg.Any()) .Returns(new Response( System.Net.HttpStatusCode.Created, - "{\"account_sid\": \"ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"consumption_report_interval\": 100,\"date_created\": \"2015-07-30T20:00:00Z\",\"date_updated\": \"2015-07-30T20:00:00Z\",\"default_channel_creator_role_sid\": \"RLaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"default_channel_role_sid\": \"RLaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"default_service_role_sid\": \"RLaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"friendly_name\": \"friendly_name\",\"links\": {},\"notifications\": {},\"post_webhook_url\": \"post_webhook_url\",\"pre_webhook_url\": \"pre_webhook_url\",\"reachability_enabled\": false,\"read_status_enabled\": false,\"sid\": \"ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"typing_indicator_timeout\": 100,\"url\": \"http://www.example.com\",\"webhook_filters\": [\"webhook_filters\"],\"webhook_method\": \"webhook_method\",\"webhooks\": {}}" + "{\"account_sid\": \"ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"consumption_report_interval\": 100,\"date_created\": \"2015-07-30T20:00:00Z\",\"date_updated\": \"2015-07-30T20:00:00Z\",\"default_channel_creator_role_sid\": \"RLaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"default_channel_role_sid\": \"RLaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"default_service_role_sid\": \"RLaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"friendly_name\": \"friendly_name\",\"limits\": {\"actions_per_second\": 20,\"channel_members\": 100,\"user_channels\": 250},\"links\": {},\"notifications\": {},\"post_webhook_url\": \"post_webhook_url\",\"pre_webhook_url\": \"pre_webhook_url\",\"reachability_enabled\": false,\"read_status_enabled\": false,\"sid\": \"ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"typing_indicator_timeout\": 100,\"url\": \"http://www.example.com\",\"webhook_filters\": [\"webhook_filters\"],\"webhook_method\": \"webhook_method\",\"webhooks\": {}}" )); var response = ServiceResource.Create("FriendlyName", client: twilioRestClient); @@ -168,7 +168,7 @@ public void TestReadFullResponse() twilioRestClient.Request(Arg.Any()) .Returns(new Response( System.Net.HttpStatusCode.OK, - "{\"meta\": {\"first_page_url\": \"https://ip-messaging.twilio.com/v1/Services?Page=0&PageSize=50\",\"key\": \"services\",\"next_page_url\": null,\"page\": 0,\"page_size\": 1,\"previous_page_url\": null,\"url\": \"https://ip-messaging.twilio.com/v1/Services\"},\"services\": [{\"account_sid\": \"ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"consumption_report_interval\": 100,\"date_created\": \"2015-07-30T20:00:00Z\",\"date_updated\": \"2015-07-30T20:00:00Z\",\"default_channel_creator_role_sid\": \"RLaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"default_channel_role_sid\": \"RLaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"default_service_role_sid\": \"RLaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"friendly_name\": \"friendly_name\",\"links\": {},\"notifications\": {},\"post_webhook_url\": \"post_webhook_url\",\"pre_webhook_url\": \"pre_webhook_url\",\"reachability_enabled\": false,\"read_status_enabled\": false,\"sid\": \"ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"typing_indicator_timeout\": 100,\"url\": \"http://www.example.com\",\"webhook_filters\": [\"webhook_filters\"],\"webhook_method\": \"webhook_method\",\"webhooks\": {}}]}" + "{\"meta\": {\"first_page_url\": \"https://ip-messaging.twilio.com/v1/Services?Page=0&PageSize=50\",\"key\": \"services\",\"next_page_url\": null,\"page\": 0,\"page_size\": 1,\"previous_page_url\": null,\"url\": \"https://ip-messaging.twilio.com/v1/Services\"},\"services\": [{\"account_sid\": \"ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"consumption_report_interval\": 100,\"date_created\": \"2015-07-30T20:00:00Z\",\"date_updated\": \"2015-07-30T20:00:00Z\",\"default_channel_creator_role_sid\": \"RLaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"default_channel_role_sid\": \"RLaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"default_service_role_sid\": \"RLaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"friendly_name\": \"friendly_name\",\"limits\": {\"actions_per_second\": 20,\"channel_members\": 100,\"user_channels\": 250},\"links\": {},\"notifications\": {},\"post_webhook_url\": \"post_webhook_url\",\"pre_webhook_url\": \"pre_webhook_url\",\"reachability_enabled\": false,\"read_status_enabled\": false,\"sid\": \"ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"typing_indicator_timeout\": 100,\"url\": \"http://www.example.com\",\"webhook_filters\": [\"webhook_filters\"],\"webhook_method\": \"webhook_method\",\"webhooks\": {}}]}" )); var response = ServiceResource.Read(client: twilioRestClient); @@ -204,7 +204,7 @@ public void TestUpdateResponse() twilioRestClient.Request(Arg.Any()) .Returns(new Response( System.Net.HttpStatusCode.OK, - "{\"account_sid\": \"ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"consumption_report_interval\": 100,\"date_created\": \"2015-07-30T20:00:00Z\",\"date_updated\": \"2015-07-30T20:00:00Z\",\"default_channel_creator_role_sid\": \"RLaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"default_channel_role_sid\": \"RLaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"default_service_role_sid\": \"RLaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"friendly_name\": \"friendly_name\",\"links\": {},\"notifications\": {},\"post_webhook_url\": \"post_webhook_url\",\"pre_webhook_url\": \"pre_webhook_url\",\"reachability_enabled\": false,\"read_status_enabled\": false,\"sid\": \"ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"typing_indicator_timeout\": 100,\"url\": \"http://www.example.com\",\"webhook_filters\": [\"webhook_filters\"],\"webhook_method\": \"webhook_method\",\"webhooks\": {}}" + "{\"account_sid\": \"ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"consumption_report_interval\": 100,\"date_created\": \"2015-07-30T20:00:00Z\",\"date_updated\": \"2015-07-30T20:00:00Z\",\"default_channel_creator_role_sid\": \"RLaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"default_channel_role_sid\": \"RLaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"default_service_role_sid\": \"RLaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"friendly_name\": \"friendly_name\",\"limits\": {\"actions_per_second\": 20,\"channel_members\": 500,\"user_channels\": 600},\"links\": {},\"notifications\": {},\"post_webhook_url\": \"post_webhook_url\",\"pre_webhook_url\": \"pre_webhook_url\",\"reachability_enabled\": false,\"read_status_enabled\": false,\"sid\": \"ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"typing_indicator_timeout\": 100,\"url\": \"http://www.example.com\",\"webhook_filters\": [\"webhook_filters\"],\"webhook_method\": \"webhook_method\",\"webhooks\": {}}" )); var response = ServiceResource.Update("ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa", client: twilioRestClient); diff --git a/test/Twilio.Test/Rest/IpMessaging/V1/Service/UserResourceTest.cs b/test/Twilio.Test/Rest/IpMessaging/V1/Service/UserResourceTest.cs index ea52cd1e0..3542b534b 100644 --- a/test/Twilio.Test/Rest/IpMessaging/V1/Service/UserResourceTest.cs +++ b/test/Twilio.Test/Rest/IpMessaging/V1/Service/UserResourceTest.cs @@ -44,7 +44,7 @@ public void TestFetchResponse() twilioRestClient.Request(Arg.Any()) .Returns(new Response( System.Net.HttpStatusCode.OK, - "{\"sid\": \"USaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"account_sid\": \"ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"service_sid\": \"ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"role_sid\": \"RLaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"identity\": \"jing\",\"attributes\": null,\"is_online\": true,\"is_notifiable\": null,\"friendly_name\": null,\"date_created\": \"2016-03-24T21:05:19Z\",\"date_updated\": \"2016-03-24T21:05:19Z\",\"links\": {\"user_channels\": \"https://ip-messaging.twilio.com/v1/Services/ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Users/USaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Channels\"},\"url\": \"https://ip-messaging.twilio.com/v1/Services/ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Users/USaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\"}" + "{\"sid\": \"USaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"account_sid\": \"ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"service_sid\": \"ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"role_sid\": \"RLaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"identity\": \"jing\",\"attributes\": null,\"is_online\": true,\"is_notifiable\": null,\"friendly_name\": null,\"joined_channels_count\": 0,\"date_created\": \"2016-03-24T21:05:19Z\",\"date_updated\": \"2016-03-24T21:05:19Z\",\"links\": {\"user_channels\": \"https://ip-messaging.twilio.com/v1/Services/ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Users/USaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Channels\"},\"url\": \"https://ip-messaging.twilio.com/v1/Services/ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Users/USaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\"}" )); var response = UserResource.Fetch("ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa", "USaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa", client: twilioRestClient); @@ -117,7 +117,7 @@ public void TestCreateResponse() twilioRestClient.Request(Arg.Any()) .Returns(new Response( System.Net.HttpStatusCode.Created, - "{\"sid\": \"USaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"account_sid\": \"ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"service_sid\": \"ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"role_sid\": \"RLaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"identity\": \"jing\",\"attributes\": null,\"is_online\": true,\"is_notifiable\": null,\"friendly_name\": null,\"date_created\": \"2016-03-24T21:05:19Z\",\"date_updated\": \"2016-03-24T21:05:19Z\",\"links\": {\"user_channels\": \"https://ip-messaging.twilio.com/v1/Services/ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Users/USaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Channels\"},\"url\": \"https://ip-messaging.twilio.com/v1/Services/ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Users/USaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\"}" + "{\"sid\": \"USaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"account_sid\": \"ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"service_sid\": \"ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"role_sid\": \"RLaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"identity\": \"jing\",\"attributes\": null,\"is_online\": true,\"is_notifiable\": null,\"friendly_name\": null,\"joined_channels_count\": 0,\"date_created\": \"2016-03-24T21:05:19Z\",\"date_updated\": \"2016-03-24T21:05:19Z\",\"links\": {\"user_channels\": \"https://ip-messaging.twilio.com/v1/Services/ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Users/USaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Channels\"},\"url\": \"https://ip-messaging.twilio.com/v1/Services/ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Users/USaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\"}" )); var response = UserResource.Create("ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa", "Identity", client: twilioRestClient); @@ -153,7 +153,7 @@ public void TestReadFullResponse() twilioRestClient.Request(Arg.Any()) .Returns(new Response( System.Net.HttpStatusCode.OK, - "{\"meta\": {\"page\": 0,\"page_size\": 50,\"first_page_url\": \"https://ip-messaging.twilio.com/v1/Services/ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Users?PageSize=50&Page=0\",\"previous_page_url\": null,\"url\": \"https://ip-messaging.twilio.com/v1/Services/ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Users?PageSize=50&Page=0\",\"next_page_url\": null,\"key\": \"users\"},\"users\": [{\"sid\": \"USaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"account_sid\": \"ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"service_sid\": \"ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"role_sid\": \"RLaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"identity\": \"jing\",\"attributes\": null,\"is_online\": true,\"is_notifiable\": null,\"friendly_name\": null,\"date_created\": \"2016-03-24T21:05:19Z\",\"date_updated\": \"2016-03-24T21:05:19Z\",\"links\": {\"user_channels\": \"https://ip-messaging.twilio.com/v1/Services/ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Users/USaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Channels\"},\"url\": \"https://ip-messaging.twilio.com/v1/Services/ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Users/USaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\"}]}" + "{\"meta\": {\"page\": 0,\"page_size\": 50,\"first_page_url\": \"https://ip-messaging.twilio.com/v1/Services/ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Users?PageSize=50&Page=0\",\"previous_page_url\": null,\"url\": \"https://ip-messaging.twilio.com/v1/Services/ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Users?PageSize=50&Page=0\",\"next_page_url\": null,\"key\": \"users\"},\"users\": [{\"sid\": \"USaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"account_sid\": \"ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"service_sid\": \"ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"role_sid\": \"RLaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"identity\": \"jing\",\"attributes\": null,\"is_online\": true,\"is_notifiable\": null,\"friendly_name\": null,\"date_created\": \"2016-03-24T21:05:19Z\",\"date_updated\": \"2016-03-24T21:05:19Z\",\"joined_channels_count\": 0,\"links\": {\"user_channels\": \"https://ip-messaging.twilio.com/v1/Services/ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Users/USaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Channels\"},\"url\": \"https://ip-messaging.twilio.com/v1/Services/ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Users/USaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\"}]}" )); var response = UserResource.Read("ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa", client: twilioRestClient); @@ -204,7 +204,7 @@ public void TestUpdateResponse() twilioRestClient.Request(Arg.Any()) .Returns(new Response( System.Net.HttpStatusCode.OK, - "{\"sid\": \"USaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"account_sid\": \"ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"service_sid\": \"ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"role_sid\": \"RLaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"identity\": \"jing\",\"attributes\": null,\"is_online\": true,\"is_notifiable\": null,\"friendly_name\": null,\"date_created\": \"2016-03-24T21:05:19Z\",\"date_updated\": \"2016-03-24T21:05:19Z\",\"links\": {\"user_channels\": \"https://ip-messaging.twilio.com/v1/Services/ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Users/USaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Channels\"},\"url\": \"https://ip-messaging.twilio.com/v1/Services/ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Users/USaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\"}" + "{\"sid\": \"USaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"account_sid\": \"ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"service_sid\": \"ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"role_sid\": \"RLaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"identity\": \"jing\",\"attributes\": null,\"is_online\": true,\"is_notifiable\": null,\"friendly_name\": null,\"joined_channels_count\": 0,\"date_created\": \"2016-03-24T21:05:19Z\",\"date_updated\": \"2016-03-24T21:05:19Z\",\"links\": {\"user_channels\": \"https://ip-messaging.twilio.com/v1/Services/ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Users/USaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Channels\"},\"url\": \"https://ip-messaging.twilio.com/v1/Services/ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Users/USaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\"}" )); var response = UserResource.Update("ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa", "USaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa", client: twilioRestClient); diff --git a/test/Twilio.Test/Rest/IpMessaging/V1/ServiceResourceTest.cs b/test/Twilio.Test/Rest/IpMessaging/V1/ServiceResourceTest.cs index 36e4340c3..f50840256 100644 --- a/test/Twilio.Test/Rest/IpMessaging/V1/ServiceResourceTest.cs +++ b/test/Twilio.Test/Rest/IpMessaging/V1/ServiceResourceTest.cs @@ -44,7 +44,7 @@ public void TestFetchResponse() twilioRestClient.Request(Arg.Any()) .Returns(new Response( System.Net.HttpStatusCode.OK, - "{\"account_sid\": \"ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"consumption_report_interval\": 100,\"date_created\": \"2015-07-30T20:00:00Z\",\"date_updated\": \"2015-07-30T20:00:00Z\",\"default_channel_creator_role_sid\": \"RLaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"default_channel_role_sid\": \"RLaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"default_service_role_sid\": \"RLaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"friendly_name\": \"friendly_name\",\"links\": {},\"notifications\": {},\"post_webhook_url\": \"post_webhook_url\",\"pre_webhook_url\": \"pre_webhook_url\",\"reachability_enabled\": false,\"read_status_enabled\": false,\"sid\": \"ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"typing_indicator_timeout\": 100,\"url\": \"http://www.example.com\",\"webhook_filters\": [\"webhook_filters\"],\"webhook_method\": \"webhook_method\",\"webhooks\": {}}" + "{\"account_sid\": \"ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"consumption_report_interval\": 100,\"date_created\": \"2015-07-30T20:00:00Z\",\"date_updated\": \"2015-07-30T20:00:00Z\",\"default_channel_creator_role_sid\": \"RLaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"default_channel_role_sid\": \"RLaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"default_service_role_sid\": \"RLaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"friendly_name\": \"friendly_name\",\"limits\": {\"actions_per_second\": 20,\"channel_members\": 100,\"user_channels\": 250},\"links\": {},\"notifications\": {},\"post_webhook_url\": \"post_webhook_url\",\"pre_webhook_url\": \"pre_webhook_url\",\"reachability_enabled\": false,\"read_status_enabled\": false,\"sid\": \"ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"typing_indicator_timeout\": 100,\"url\": \"http://www.example.com\",\"webhook_filters\": [\"webhook_filters\"],\"webhook_method\": \"webhook_method\",\"webhooks\": {}}" )); var response = ServiceResource.Fetch("ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa", client: twilioRestClient); @@ -117,7 +117,7 @@ public void TestCreateResponse() twilioRestClient.Request(Arg.Any()) .Returns(new Response( System.Net.HttpStatusCode.Created, - "{\"account_sid\": \"ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"consumption_report_interval\": 100,\"date_created\": \"2015-07-30T20:00:00Z\",\"date_updated\": \"2015-07-30T20:00:00Z\",\"default_channel_creator_role_sid\": \"RLaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"default_channel_role_sid\": \"RLaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"default_service_role_sid\": \"RLaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"friendly_name\": \"friendly_name\",\"links\": {},\"notifications\": {},\"post_webhook_url\": \"post_webhook_url\",\"pre_webhook_url\": \"pre_webhook_url\",\"reachability_enabled\": false,\"read_status_enabled\": false,\"sid\": \"ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"typing_indicator_timeout\": 100,\"url\": \"http://www.example.com\",\"webhook_filters\": [\"webhook_filters\"],\"webhook_method\": \"webhook_method\",\"webhooks\": {}}" + "{\"account_sid\": \"ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"consumption_report_interval\": 100,\"date_created\": \"2015-07-30T20:00:00Z\",\"date_updated\": \"2015-07-30T20:00:00Z\",\"default_channel_creator_role_sid\": \"RLaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"default_channel_role_sid\": \"RLaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"default_service_role_sid\": \"RLaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"friendly_name\": \"friendly_name\",\"limits\": {\"actions_per_second\": 20,\"channel_members\": 100,\"user_channels\": 250},\"links\": {},\"notifications\": {},\"post_webhook_url\": \"post_webhook_url\",\"pre_webhook_url\": \"pre_webhook_url\",\"reachability_enabled\": false,\"read_status_enabled\": false,\"sid\": \"ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"typing_indicator_timeout\": 100,\"url\": \"http://www.example.com\",\"webhook_filters\": [\"webhook_filters\"],\"webhook_method\": \"webhook_method\",\"webhooks\": {}}" )); var response = ServiceResource.Create("FriendlyName", client: twilioRestClient); @@ -168,7 +168,7 @@ public void TestReadFullResponse() twilioRestClient.Request(Arg.Any()) .Returns(new Response( System.Net.HttpStatusCode.OK, - "{\"meta\": {\"first_page_url\": \"https://ip-messaging.twilio.com/v1/Services?Page=0&PageSize=50\",\"key\": \"services\",\"next_page_url\": null,\"page\": 0,\"page_size\": 1,\"previous_page_url\": null,\"url\": \"https://ip-messaging.twilio.com/v1/Services\"},\"services\": [{\"account_sid\": \"ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"consumption_report_interval\": 100,\"date_created\": \"2015-07-30T20:00:00Z\",\"date_updated\": \"2015-07-30T20:00:00Z\",\"default_channel_creator_role_sid\": \"RLaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"default_channel_role_sid\": \"RLaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"default_service_role_sid\": \"RLaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"friendly_name\": \"friendly_name\",\"links\": {},\"notifications\": {},\"post_webhook_url\": \"post_webhook_url\",\"pre_webhook_url\": \"pre_webhook_url\",\"reachability_enabled\": false,\"read_status_enabled\": false,\"sid\": \"ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"typing_indicator_timeout\": 100,\"url\": \"http://www.example.com\",\"webhook_filters\": [\"webhook_filters\"],\"webhook_method\": \"webhook_method\",\"webhooks\": {}}]}" + "{\"meta\": {\"first_page_url\": \"https://ip-messaging.twilio.com/v1/Services?Page=0&PageSize=50\",\"key\": \"services\",\"next_page_url\": null,\"page\": 0,\"page_size\": 1,\"previous_page_url\": null,\"url\": \"https://ip-messaging.twilio.com/v1/Services\"},\"services\": [{\"account_sid\": \"ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"consumption_report_interval\": 100,\"date_created\": \"2015-07-30T20:00:00Z\",\"date_updated\": \"2015-07-30T20:00:00Z\",\"default_channel_creator_role_sid\": \"RLaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"default_channel_role_sid\": \"RLaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"default_service_role_sid\": \"RLaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"friendly_name\": \"friendly_name\",\"limits\": {\"actions_per_second\": 20,\"channel_members\": 100,\"user_channels\": 250},\"links\": {},\"notifications\": {},\"post_webhook_url\": \"post_webhook_url\",\"pre_webhook_url\": \"pre_webhook_url\",\"reachability_enabled\": false,\"read_status_enabled\": false,\"sid\": \"ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"typing_indicator_timeout\": 100,\"url\": \"http://www.example.com\",\"webhook_filters\": [\"webhook_filters\"],\"webhook_method\": \"webhook_method\",\"webhooks\": {}}]}" )); var response = ServiceResource.Read(client: twilioRestClient); @@ -204,7 +204,7 @@ public void TestUpdateResponse() twilioRestClient.Request(Arg.Any()) .Returns(new Response( System.Net.HttpStatusCode.OK, - "{\"account_sid\": \"ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"consumption_report_interval\": 100,\"date_created\": \"2015-07-30T20:00:00Z\",\"date_updated\": \"2015-07-30T20:00:00Z\",\"default_channel_creator_role_sid\": \"RLaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"default_channel_role_sid\": \"RLaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"default_service_role_sid\": \"RLaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"friendly_name\": \"friendly_name\",\"links\": {},\"notifications\": {},\"post_webhook_url\": \"post_webhook_url\",\"pre_webhook_url\": \"pre_webhook_url\",\"reachability_enabled\": false,\"read_status_enabled\": false,\"sid\": \"ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"typing_indicator_timeout\": 100,\"url\": \"http://www.example.com\",\"webhook_filters\": [\"webhook_filters\"],\"webhook_method\": \"webhook_method\",\"webhooks\": {}}" + "{\"account_sid\": \"ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"consumption_report_interval\": 100,\"date_created\": \"2015-07-30T20:00:00Z\",\"date_updated\": \"2015-07-30T20:00:00Z\",\"default_channel_creator_role_sid\": \"RLaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"default_channel_role_sid\": \"RLaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"default_service_role_sid\": \"RLaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"friendly_name\": \"friendly_name\",\"limits\": {\"actions_per_second\": 20,\"channel_members\": 500,\"user_channels\": 600},\"links\": {},\"notifications\": {},\"post_webhook_url\": \"post_webhook_url\",\"pre_webhook_url\": \"pre_webhook_url\",\"reachability_enabled\": false,\"read_status_enabled\": false,\"sid\": \"ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"typing_indicator_timeout\": 100,\"url\": \"http://www.example.com\",\"webhook_filters\": [\"webhook_filters\"],\"webhook_method\": \"webhook_method\",\"webhooks\": {}}" )); var response = ServiceResource.Update("ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa", client: twilioRestClient); diff --git a/test/Twilio.Test/Rest/Taskrouter/V1/Workspace/TaskQueue/TaskQueueStatisticsResourceTest.cs b/test/Twilio.Test/Rest/Taskrouter/V1/Workspace/TaskQueue/TaskQueueStatisticsResourceTest.cs index 3c9b3fdc8..e416a8d64 100644 --- a/test/Twilio.Test/Rest/Taskrouter/V1/Workspace/TaskQueue/TaskQueueStatisticsResourceTest.cs +++ b/test/Twilio.Test/Rest/Taskrouter/V1/Workspace/TaskQueue/TaskQueueStatisticsResourceTest.cs @@ -44,7 +44,7 @@ public void TestFetchResponse() twilioRestClient.Request(Arg.Any()) .Returns(new Response( System.Net.HttpStatusCode.OK, - "{\"account_sid\": \"ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"url\": \"https://taskrouter.twilio.com/v1/Workspaces/WSaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/TaskQueues/WQaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Statistics\",\"cumulative\": {\"avg_task_acceptance_time\": 0.0,\"end_time\": \"2015-08-18T08:42:34Z\",\"reservations_accepted\": 0,\"reservations_canceled\": 0,\"reservations_created\": 0,\"reservations_rejected\": 0,\"reservations_rescinded\": 0,\"reservations_timed_out\": 0,\"start_time\": \"2015-08-18T08:27:34Z\",\"tasks_canceled\": 0,\"tasks_deleted\": 0,\"tasks_entered\": 0,\"tasks_moved\": 0},\"realtime\": {\"activity_statistics\": [{\"friendly_name\": \"Offline\",\"sid\": \"WAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"workers\": 0},{\"friendly_name\": \"Idle\",\"sid\": \"WAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"workers\": 0},{\"friendly_name\": \"80fa2beb-3a05-11e5-8fc8-98e0d9a1eb73\",\"sid\": \"WAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"workers\": 0},{\"friendly_name\": \"Reserved\",\"sid\": \"WAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"workers\": 0},{\"friendly_name\": \"Busy\",\"sid\": \"WAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"workers\": 0},{\"friendly_name\": \"817ca1c5-3a05-11e5-9292-98e0d9a1eb73\",\"sid\": \"WAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"workers\": 0}],\"longest_task_waiting_age\": 0,\"longest_task_waiting_sid\": null,\"tasks_by_status\": {\"assigned\": 0,\"pending\": 0,\"reserved\": 0},\"total_available_workers\": 0,\"total_eligible_workers\": 0,\"total_tasks\": 0},\"task_queue_sid\": \"WQaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"workspace_sid\": \"WSaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\"}" + "{\"account_sid\": \"ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"url\": \"https://taskrouter.twilio.com/v1/Workspaces/WSaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/TaskQueues/WQaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Statistics\",\"cumulative\": {\"avg_task_acceptance_time\": 0.0,\"end_time\": \"2015-08-18T08:42:34Z\",\"reservations_accepted\": 0,\"reservations_canceled\": 0,\"reservations_created\": 0,\"reservations_rejected\": 0,\"reservations_rescinded\": 0,\"reservations_timed_out\": 0,\"start_time\": \"2015-08-18T08:27:34Z\",\"tasks_canceled\": 0,\"tasks_deleted\": 0,\"tasks_entered\": 0,\"tasks_moved\": 0},\"realtime\": {\"activity_statistics\": [{\"friendly_name\": \"Offline\",\"sid\": \"WAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"workers\": 0},{\"friendly_name\": \"Idle\",\"sid\": \"WAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"workers\": 0},{\"friendly_name\": \"80fa2beb-3a05-11e5-8fc8-98e0d9a1eb73\",\"sid\": \"WAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"workers\": 0},{\"friendly_name\": \"Reserved\",\"sid\": \"WAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"workers\": 0},{\"friendly_name\": \"Busy\",\"sid\": \"WAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"workers\": 0},{\"friendly_name\": \"817ca1c5-3a05-11e5-9292-98e0d9a1eb73\",\"sid\": \"WAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"workers\": 0}],\"longest_task_waiting_age\": 0,\"longest_task_waiting_sid\": null,\"tasks_by_status\": {\"assigned\": 0,\"pending\": 0,\"reserved\": 0,\"wrapping\": 0},\"total_available_workers\": 0,\"total_eligible_workers\": 0,\"total_tasks\": 0},\"task_queue_sid\": \"WQaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"workspace_sid\": \"WSaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\"}" )); var response = TaskQueueStatisticsResource.Fetch("WSaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa", "WQaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa", client: twilioRestClient); diff --git a/test/Twilio.Test/Rest/Taskrouter/V1/Workspace/TaskQueue/TaskQueuesStatisticsResourceTest.cs b/test/Twilio.Test/Rest/Taskrouter/V1/Workspace/TaskQueue/TaskQueuesStatisticsResourceTest.cs index 7925e4e0a..122fe01f2 100644 --- a/test/Twilio.Test/Rest/Taskrouter/V1/Workspace/TaskQueue/TaskQueuesStatisticsResourceTest.cs +++ b/test/Twilio.Test/Rest/Taskrouter/V1/Workspace/TaskQueue/TaskQueuesStatisticsResourceTest.cs @@ -44,7 +44,7 @@ public void TestReadFullResponse() twilioRestClient.Request(Arg.Any()) .Returns(new Response( System.Net.HttpStatusCode.OK, - "{\"meta\": {\"first_page_url\": \"https://taskrouter.twilio.com/v1/Workspaces/WSaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/TaskQueues/Statistics?PageSize=50&Page=0\",\"key\": \"task_queues_statistics\",\"next_page_url\": null,\"page\": 0,\"page_size\": 50,\"previous_page_url\": null,\"url\": \"https://taskrouter.twilio.com/v1/Workspaces/WSaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/TaskQueues/Statistics?PageSize=50&Page=0\"},\"task_queues_statistics\": [{\"account_sid\": \"ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"cumulative\": {\"avg_task_acceptance_time\": 0.0,\"end_time\": \"2015-08-18T08:46:15Z\",\"reservations_accepted\": 0,\"reservations_canceled\": 0,\"reservations_created\": 0,\"reservations_rejected\": 0,\"reservations_rescinded\": 0,\"reservations_timed_out\": 0,\"start_time\": \"2015-08-18T08:31:15Z\",\"tasks_canceled\": 0,\"tasks_deleted\": 0,\"tasks_entered\": 0,\"tasks_moved\": 0},\"realtime\": {\"activity_statistics\": [{\"friendly_name\": \"Offline\",\"sid\": \"WAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"workers\": 0},{\"friendly_name\": \"Idle\",\"sid\": \"WAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"workers\": 0},{\"friendly_name\": \"80fa2beb-3a05-11e5-8fc8-98e0d9a1eb73\",\"sid\": \"WAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"workers\": 0},{\"friendly_name\": \"Reserved\",\"sid\": \"WAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"workers\": 0},{\"friendly_name\": \"Busy\",\"sid\": \"WAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"workers\": 0},{\"friendly_name\": \"817ca1c5-3a05-11e5-9292-98e0d9a1eb73\",\"sid\": \"WAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"workers\": 0}],\"longest_task_waiting_age\": 0,\"longest_task_waiting_sid\": null,\"tasks_by_status\": {\"assigned\": 0,\"pending\": 0,\"reserved\": 0},\"total_available_workers\": 0,\"total_eligible_workers\": 0,\"total_tasks\": 0},\"task_queue_sid\": \"WQaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"workspace_sid\": \"WSaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\"}]}" + "{\"meta\": {\"first_page_url\": \"https://taskrouter.twilio.com/v1/Workspaces/WSaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/TaskQueues/Statistics?PageSize=50&Page=0\",\"key\": \"task_queues_statistics\",\"next_page_url\": null,\"page\": 0,\"page_size\": 50,\"previous_page_url\": null,\"url\": \"https://taskrouter.twilio.com/v1/Workspaces/WSaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/TaskQueues/Statistics?PageSize=50&Page=0\"},\"task_queues_statistics\": [{\"account_sid\": \"ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"cumulative\": {\"avg_task_acceptance_time\": 0.0,\"end_time\": \"2015-08-18T08:46:15Z\",\"reservations_accepted\": 0,\"reservations_canceled\": 0,\"reservations_created\": 0,\"reservations_rejected\": 0,\"reservations_rescinded\": 0,\"reservations_timed_out\": 0,\"start_time\": \"2015-08-18T08:31:15Z\",\"tasks_canceled\": 0,\"tasks_deleted\": 0,\"tasks_entered\": 0,\"tasks_moved\": 0},\"realtime\": {\"activity_statistics\": [{\"friendly_name\": \"Offline\",\"sid\": \"WAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"workers\": 0},{\"friendly_name\": \"Idle\",\"sid\": \"WAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"workers\": 0},{\"friendly_name\": \"80fa2beb-3a05-11e5-8fc8-98e0d9a1eb73\",\"sid\": \"WAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"workers\": 0},{\"friendly_name\": \"Reserved\",\"sid\": \"WAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"workers\": 0},{\"friendly_name\": \"Busy\",\"sid\": \"WAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"workers\": 0},{\"friendly_name\": \"817ca1c5-3a05-11e5-9292-98e0d9a1eb73\",\"sid\": \"WAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"workers\": 0}],\"longest_task_waiting_age\": 0,\"longest_task_waiting_sid\": null,\"tasks_by_status\": {\"assigned\": 0,\"pending\": 0,\"reserved\": 0,\"wrapping\": 0},\"total_available_workers\": 0,\"total_eligible_workers\": 0,\"total_tasks\": 0},\"task_queue_sid\": \"WQaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"workspace_sid\": \"WSaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\"}]}" )); var response = TaskQueuesStatisticsResource.Read("WSaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa", client: twilioRestClient); diff --git a/test/Twilio.Test/Rest/Taskrouter/V1/Workspace/Workflow/WorkflowStatisticsResourceTest.cs b/test/Twilio.Test/Rest/Taskrouter/V1/Workspace/Workflow/WorkflowStatisticsResourceTest.cs index 34aaa3ed1..d79ba5e4a 100644 --- a/test/Twilio.Test/Rest/Taskrouter/V1/Workspace/Workflow/WorkflowStatisticsResourceTest.cs +++ b/test/Twilio.Test/Rest/Taskrouter/V1/Workspace/Workflow/WorkflowStatisticsResourceTest.cs @@ -44,7 +44,7 @@ public void TestFetchResponse() twilioRestClient.Request(Arg.Any()) .Returns(new Response( System.Net.HttpStatusCode.OK, - "{\"account_sid\": \"ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"url\": \"https://taskrouter.twilio.com/v1/Workspaces/WSaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Workflows/WWaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Statistics\",\"cumulative\": {\"avg_task_acceptance_time\": 0.0,\"end_time\": \"2008-01-02T00:00:00Z\",\"reservations_accepted\": 0,\"reservations_rejected\": 0,\"reservations_timed_out\": 0,\"start_time\": \"2008-01-02T00:00:00Z\",\"tasks_canceled\": 0,\"tasks_entered\": 0,\"tasks_moved\": 0,\"tasks_timed_out_in_workflow\": 0},\"realtime\": {\"longest_task_waiting_age\": 0,\"longest_task_waiting_sid\": null,\"tasks_by_status\": {\"assigned\": 1,\"pending\": 0,\"reserved\": 0},\"total_tasks\": 1},\"workflow_sid\": \"WWaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"workspace_sid\": \"WSaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\"}" + "{\"account_sid\": \"ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"url\": \"https://taskrouter.twilio.com/v1/Workspaces/WSaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Workflows/WWaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Statistics\",\"cumulative\": {\"avg_task_acceptance_time\": 0.0,\"end_time\": \"2008-01-02T00:00:00Z\",\"reservations_accepted\": 0,\"reservations_rejected\": 0,\"reservations_timed_out\": 0,\"start_time\": \"2008-01-02T00:00:00Z\",\"tasks_canceled\": 0,\"tasks_entered\": 0,\"tasks_moved\": 0,\"tasks_timed_out_in_workflow\": 0},\"realtime\": {\"longest_task_waiting_age\": 0,\"longest_task_waiting_sid\": null,\"tasks_by_status\": {\"assigned\": 1,\"pending\": 0,\"reserved\": 0,\"wrapping\": 0},\"total_tasks\": 1},\"workflow_sid\": \"WWaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"workspace_sid\": \"WSaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\"}" )); var response = WorkflowStatisticsResource.Fetch("WSaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa", "WWaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa", client: twilioRestClient); diff --git a/test/Twilio.Test/Rest/Taskrouter/V1/Workspace/WorkspaceStatisticsResourceTest.cs b/test/Twilio.Test/Rest/Taskrouter/V1/Workspace/WorkspaceStatisticsResourceTest.cs index adf26144f..a700cd2d8 100644 --- a/test/Twilio.Test/Rest/Taskrouter/V1/Workspace/WorkspaceStatisticsResourceTest.cs +++ b/test/Twilio.Test/Rest/Taskrouter/V1/Workspace/WorkspaceStatisticsResourceTest.cs @@ -44,7 +44,7 @@ public void TestFetchResponse() twilioRestClient.Request(Arg.Any()) .Returns(new Response( System.Net.HttpStatusCode.OK, - "{\"account_sid\": \"ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"url\": \"https://taskrouter.twilio.com/v1/Workspaces/WSaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Statistics\",\"cumulative\": {\"avg_task_acceptance_time\": 0.0,\"start_time\": \"2008-01-02T00:00:00Z\",\"reservations_accepted\": 0,\"reservations_canceled\": 0,\"reservations_created\": 0,\"reservations_rejected\": 0,\"reservations_rescinded\": 0,\"reservations_timed_out\": 0,\"end_time\": \"2008-01-02T00:00:00Z\",\"tasks_canceled\": 0,\"tasks_created\": 0,\"tasks_deleted\": 0,\"tasks_moved\": 0,\"tasks_timed_out_in_workflow\": 0},\"realtime\": {\"activity_statistics\": [{\"friendly_name\": \"Offline\",\"sid\": \"WAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"workers\": 1},{\"friendly_name\": \"Idle\",\"sid\": \"WAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"workers\": 0},{\"friendly_name\": \"80fa2beb-3a05-11e5-8fc8-98e0d9a1eb73\",\"sid\": \"WAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"workers\": 0},{\"friendly_name\": \"Reserved\",\"sid\": \"WAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"workers\": 0},{\"friendly_name\": \"Busy\",\"sid\": \"WAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"workers\": 0},{\"friendly_name\": \"817ca1c5-3a05-11e5-9292-98e0d9a1eb73\",\"sid\": \"WAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"workers\": 0}],\"longest_task_waiting_age\": 0,\"longest_task_waiting_sid\": null,\"tasks_by_status\": {\"assigned\": 0,\"pending\": 0,\"reserved\": 0},\"total_tasks\": 0,\"total_workers\": 1},\"workspace_sid\": \"WSaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\"}" + "{\"account_sid\": \"ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"url\": \"https://taskrouter.twilio.com/v1/Workspaces/WSaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Statistics\",\"cumulative\": {\"avg_task_acceptance_time\": 0.0,\"start_time\": \"2008-01-02T00:00:00Z\",\"reservations_accepted\": 0,\"reservations_canceled\": 0,\"reservations_created\": 0,\"reservations_rejected\": 0,\"reservations_rescinded\": 0,\"reservations_timed_out\": 0,\"end_time\": \"2008-01-02T00:00:00Z\",\"tasks_canceled\": 0,\"tasks_created\": 0,\"tasks_deleted\": 0,\"tasks_moved\": 0,\"tasks_timed_out_in_workflow\": 0},\"realtime\": {\"activity_statistics\": [{\"friendly_name\": \"Offline\",\"sid\": \"WAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"workers\": 1},{\"friendly_name\": \"Idle\",\"sid\": \"WAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"workers\": 0},{\"friendly_name\": \"80fa2beb-3a05-11e5-8fc8-98e0d9a1eb73\",\"sid\": \"WAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"workers\": 0},{\"friendly_name\": \"Reserved\",\"sid\": \"WAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"workers\": 0},{\"friendly_name\": \"Busy\",\"sid\": \"WAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"workers\": 0},{\"friendly_name\": \"817ca1c5-3a05-11e5-9292-98e0d9a1eb73\",\"sid\": \"WAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\"workers\": 0}],\"longest_task_waiting_age\": 0,\"longest_task_waiting_sid\": null,\"tasks_by_status\": {\"assigned\": 0,\"pending\": 0,\"reserved\": 0,\"wrapping\": 0},\"total_tasks\": 0,\"total_workers\": 1},\"workspace_sid\": \"WSaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\"}" )); var response = WorkspaceStatisticsResource.Fetch("WSaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa", client: twilioRestClient);