/// <summary> /// Initializes a new instance of the <see cref="SendSmsToMultipleRecipientsRequest" /> class. /// </summary> /// <param name="definitionKey">Unique, user-generated key to access the definition object. (required).</param> /// <param name="recipients">Array of recipient objects that contain parameters and metadata for the recipients, such as send tracking and personalization attributes. Use this parameter to send to multiple recipients in one request. Use either the recipient or recipients parameter, but not both. (required).</param> /// <param name="subscriptions">subscriptions.</param> /// <param name="content">content.</param> /// <param name="attributes">attributes.</param> public SendSmsToMultipleRecipientsRequest(string definitionKey = default(string), List <Recipient> recipients = default(List <Recipient>), SendSmsToMultipleRecipientsSubscriptionsRequest subscriptions = default(SendSmsToMultipleRecipientsSubscriptionsRequest), SendSmsContentRequest content = default(SendSmsContentRequest), Attributes attributes = default(Attributes)) { // to ensure "definitionKey" is required (not null) if (definitionKey == null) { throw new InvalidDataException("definitionKey is a required property for SendSmsToMultipleRecipientsRequest and cannot be null"); } else { this.DefinitionKey = definitionKey; } // to ensure "recipients" is required (not null) if (recipients == null) { throw new InvalidDataException("recipients is a required property for SendSmsToMultipleRecipientsRequest and cannot be null"); } else { this.Recipients = recipients; } this.Subscriptions = subscriptions; this.Content = content; this.Attributes = attributes; }
/// <summary> /// Initializes a new instance of the <see cref="SendSmsToSingleRecipientRequest" /> class. /// </summary> /// <param name="definitionKey">Unique identifier of the definition. (required).</param> /// <param name="recipient">recipient (required).</param> /// <param name="content">content.</param> public SendSmsToSingleRecipientRequest(string definitionKey = default(string), Recipient recipient = default(Recipient), SendSmsContentRequest content = default(SendSmsContentRequest)) { // to ensure "definitionKey" is required (not null) if (definitionKey == null) { throw new InvalidDataException("definitionKey is a required property for SendSmsToSingleRecipientRequest and cannot be null"); } else { this.DefinitionKey = definitionKey; } // to ensure "recipient" is required (not null) if (recipient == null) { throw new InvalidDataException("recipient is a required property for SendSmsToSingleRecipientRequest and cannot be null"); } else { this.Recipient = recipient; } this.Content = content; }