@aws-sdk/client-pinpoint 3.42.0 → 3.47.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (44) hide show
  1. package/CHANGELOG.md +50 -0
  2. package/dist-cjs/Pinpoint.js +30 -0
  3. package/dist-cjs/commands/SendOTPMessageCommand.js +36 -0
  4. package/dist-cjs/commands/VerifyOTPMessageCommand.js +36 -0
  5. package/dist-cjs/commands/index.js +2 -0
  6. package/dist-cjs/endpoints.js +1 -0
  7. package/dist-cjs/models/models_0.js +5 -53
  8. package/dist-cjs/models/models_1.js +44 -2
  9. package/dist-cjs/protocols/Aws_restJson1.js +294 -4
  10. package/dist-cjs/runtimeConfig.browser.js +7 -2
  11. package/dist-cjs/runtimeConfig.js +9 -3
  12. package/dist-es/Pinpoint.js +30 -0
  13. package/dist-es/commands/SendOTPMessageCommand.js +39 -0
  14. package/dist-es/commands/VerifyOTPMessageCommand.js +39 -0
  15. package/dist-es/commands/index.js +2 -0
  16. package/dist-es/endpoints.js +1 -0
  17. package/dist-es/models/models_0.js +0 -32
  18. package/dist-es/models/models_1.js +28 -0
  19. package/dist-es/protocols/Aws_restJson1.js +310 -0
  20. package/dist-es/runtimeConfig.browser.js +12 -3
  21. package/dist-es/runtimeConfig.js +13 -6
  22. package/dist-types/Pinpoint.d.ts +14 -0
  23. package/dist-types/PinpointClient.d.ts +9 -3
  24. package/dist-types/commands/SendOTPMessageCommand.d.ts +35 -0
  25. package/dist-types/commands/VerifyOTPMessageCommand.d.ts +35 -0
  26. package/dist-types/commands/index.d.ts +2 -0
  27. package/dist-types/models/models_0.d.ts +0 -48
  28. package/dist-types/models/models_1.d.ts +149 -0
  29. package/dist-types/protocols/Aws_restJson1.d.ts +6 -0
  30. package/dist-types/runtimeConfig.browser.d.ts +3 -2
  31. package/dist-types/runtimeConfig.d.ts +4 -3
  32. package/dist-types/runtimeConfig.native.d.ts +1 -0
  33. package/dist-types/ts3.4/Pinpoint.d.ts +10 -0
  34. package/dist-types/ts3.4/PinpointClient.d.ts +7 -3
  35. package/dist-types/ts3.4/commands/SendOTPMessageCommand.d.ts +17 -0
  36. package/dist-types/ts3.4/commands/VerifyOTPMessageCommand.d.ts +17 -0
  37. package/dist-types/ts3.4/commands/index.d.ts +2 -0
  38. package/dist-types/ts3.4/models/models_0.d.ts +0 -32
  39. package/dist-types/ts3.4/models/models_1.d.ts +87 -0
  40. package/dist-types/ts3.4/protocols/Aws_restJson1.d.ts +6 -0
  41. package/dist-types/ts3.4/runtimeConfig.browser.d.ts +3 -2
  42. package/dist-types/ts3.4/runtimeConfig.d.ts +4 -3
  43. package/dist-types/ts3.4/runtimeConfig.native.d.ts +1 -0
  44. package/package.json +38 -45
@@ -1,10 +1,10 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.serializeAws_restJson1GetCampaignVersionCommand = exports.serializeAws_restJson1GetCampaignsCommand = exports.serializeAws_restJson1GetCampaignDateRangeKpiCommand = exports.serializeAws_restJson1GetCampaignActivitiesCommand = exports.serializeAws_restJson1GetCampaignCommand = exports.serializeAws_restJson1GetBaiduChannelCommand = exports.serializeAws_restJson1GetAppsCommand = exports.serializeAws_restJson1GetApplicationSettingsCommand = exports.serializeAws_restJson1GetApplicationDateRangeKpiCommand = exports.serializeAws_restJson1GetAppCommand = exports.serializeAws_restJson1GetApnsVoipSandboxChannelCommand = exports.serializeAws_restJson1GetApnsVoipChannelCommand = exports.serializeAws_restJson1GetApnsSandboxChannelCommand = exports.serializeAws_restJson1GetApnsChannelCommand = exports.serializeAws_restJson1GetAdmChannelCommand = exports.serializeAws_restJson1DeleteVoiceTemplateCommand = exports.serializeAws_restJson1DeleteVoiceChannelCommand = exports.serializeAws_restJson1DeleteUserEndpointsCommand = exports.serializeAws_restJson1DeleteSmsTemplateCommand = exports.serializeAws_restJson1DeleteSmsChannelCommand = exports.serializeAws_restJson1DeleteSegmentCommand = exports.serializeAws_restJson1DeleteRecommenderConfigurationCommand = exports.serializeAws_restJson1DeletePushTemplateCommand = exports.serializeAws_restJson1DeleteJourneyCommand = exports.serializeAws_restJson1DeleteInAppTemplateCommand = exports.serializeAws_restJson1DeleteGcmChannelCommand = exports.serializeAws_restJson1DeleteEventStreamCommand = exports.serializeAws_restJson1DeleteEndpointCommand = exports.serializeAws_restJson1DeleteEmailTemplateCommand = exports.serializeAws_restJson1DeleteEmailChannelCommand = exports.serializeAws_restJson1DeleteCampaignCommand = exports.serializeAws_restJson1DeleteBaiduChannelCommand = exports.serializeAws_restJson1DeleteAppCommand = exports.serializeAws_restJson1DeleteApnsVoipSandboxChannelCommand = exports.serializeAws_restJson1DeleteApnsVoipChannelCommand = exports.serializeAws_restJson1DeleteApnsSandboxChannelCommand = exports.serializeAws_restJson1DeleteApnsChannelCommand = exports.serializeAws_restJson1DeleteAdmChannelCommand = exports.serializeAws_restJson1CreateVoiceTemplateCommand = exports.serializeAws_restJson1CreateSmsTemplateCommand = exports.serializeAws_restJson1CreateSegmentCommand = exports.serializeAws_restJson1CreateRecommenderConfigurationCommand = exports.serializeAws_restJson1CreatePushTemplateCommand = exports.serializeAws_restJson1CreateJourneyCommand = exports.serializeAws_restJson1CreateInAppTemplateCommand = exports.serializeAws_restJson1CreateImportJobCommand = exports.serializeAws_restJson1CreateExportJobCommand = exports.serializeAws_restJson1CreateEmailTemplateCommand = exports.serializeAws_restJson1CreateCampaignCommand = exports.serializeAws_restJson1CreateAppCommand = void 0;
4
- exports.serializeAws_restJson1UpdateBaiduChannelCommand = exports.serializeAws_restJson1UpdateApplicationSettingsCommand = exports.serializeAws_restJson1UpdateApnsVoipSandboxChannelCommand = exports.serializeAws_restJson1UpdateApnsVoipChannelCommand = exports.serializeAws_restJson1UpdateApnsSandboxChannelCommand = exports.serializeAws_restJson1UpdateApnsChannelCommand = exports.serializeAws_restJson1UpdateAdmChannelCommand = exports.serializeAws_restJson1UntagResourceCommand = exports.serializeAws_restJson1TagResourceCommand = exports.serializeAws_restJson1SendUsersMessagesCommand = exports.serializeAws_restJson1SendMessagesCommand = exports.serializeAws_restJson1RemoveAttributesCommand = exports.serializeAws_restJson1PutEventStreamCommand = exports.serializeAws_restJson1PutEventsCommand = exports.serializeAws_restJson1PhoneNumberValidateCommand = exports.serializeAws_restJson1ListTemplateVersionsCommand = exports.serializeAws_restJson1ListTemplatesCommand = exports.serializeAws_restJson1ListTagsForResourceCommand = exports.serializeAws_restJson1ListJourneysCommand = exports.serializeAws_restJson1GetVoiceTemplateCommand = exports.serializeAws_restJson1GetVoiceChannelCommand = exports.serializeAws_restJson1GetUserEndpointsCommand = exports.serializeAws_restJson1GetSmsTemplateCommand = exports.serializeAws_restJson1GetSmsChannelCommand = exports.serializeAws_restJson1GetSegmentVersionsCommand = exports.serializeAws_restJson1GetSegmentVersionCommand = exports.serializeAws_restJson1GetSegmentsCommand = exports.serializeAws_restJson1GetSegmentImportJobsCommand = exports.serializeAws_restJson1GetSegmentExportJobsCommand = exports.serializeAws_restJson1GetSegmentCommand = exports.serializeAws_restJson1GetRecommenderConfigurationsCommand = exports.serializeAws_restJson1GetRecommenderConfigurationCommand = exports.serializeAws_restJson1GetPushTemplateCommand = exports.serializeAws_restJson1GetJourneyExecutionMetricsCommand = exports.serializeAws_restJson1GetJourneyExecutionActivityMetricsCommand = exports.serializeAws_restJson1GetJourneyDateRangeKpiCommand = exports.serializeAws_restJson1GetJourneyCommand = exports.serializeAws_restJson1GetInAppTemplateCommand = exports.serializeAws_restJson1GetInAppMessagesCommand = exports.serializeAws_restJson1GetImportJobsCommand = exports.serializeAws_restJson1GetImportJobCommand = exports.serializeAws_restJson1GetGcmChannelCommand = exports.serializeAws_restJson1GetExportJobsCommand = exports.serializeAws_restJson1GetExportJobCommand = exports.serializeAws_restJson1GetEventStreamCommand = exports.serializeAws_restJson1GetEndpointCommand = exports.serializeAws_restJson1GetEmailTemplateCommand = exports.serializeAws_restJson1GetEmailChannelCommand = exports.serializeAws_restJson1GetChannelsCommand = exports.serializeAws_restJson1GetCampaignVersionsCommand = void 0;
5
- exports.deserializeAws_restJson1DeleteUserEndpointsCommand = exports.deserializeAws_restJson1DeleteSmsTemplateCommand = exports.deserializeAws_restJson1DeleteSmsChannelCommand = exports.deserializeAws_restJson1DeleteSegmentCommand = exports.deserializeAws_restJson1DeleteRecommenderConfigurationCommand = exports.deserializeAws_restJson1DeletePushTemplateCommand = exports.deserializeAws_restJson1DeleteJourneyCommand = exports.deserializeAws_restJson1DeleteInAppTemplateCommand = exports.deserializeAws_restJson1DeleteGcmChannelCommand = exports.deserializeAws_restJson1DeleteEventStreamCommand = exports.deserializeAws_restJson1DeleteEndpointCommand = exports.deserializeAws_restJson1DeleteEmailTemplateCommand = exports.deserializeAws_restJson1DeleteEmailChannelCommand = exports.deserializeAws_restJson1DeleteCampaignCommand = exports.deserializeAws_restJson1DeleteBaiduChannelCommand = exports.deserializeAws_restJson1DeleteAppCommand = exports.deserializeAws_restJson1DeleteApnsVoipSandboxChannelCommand = exports.deserializeAws_restJson1DeleteApnsVoipChannelCommand = exports.deserializeAws_restJson1DeleteApnsSandboxChannelCommand = exports.deserializeAws_restJson1DeleteApnsChannelCommand = exports.deserializeAws_restJson1DeleteAdmChannelCommand = exports.deserializeAws_restJson1CreateVoiceTemplateCommand = exports.deserializeAws_restJson1CreateSmsTemplateCommand = exports.deserializeAws_restJson1CreateSegmentCommand = exports.deserializeAws_restJson1CreateRecommenderConfigurationCommand = exports.deserializeAws_restJson1CreatePushTemplateCommand = exports.deserializeAws_restJson1CreateJourneyCommand = exports.deserializeAws_restJson1CreateInAppTemplateCommand = exports.deserializeAws_restJson1CreateImportJobCommand = exports.deserializeAws_restJson1CreateExportJobCommand = exports.deserializeAws_restJson1CreateEmailTemplateCommand = exports.deserializeAws_restJson1CreateCampaignCommand = exports.deserializeAws_restJson1CreateAppCommand = exports.serializeAws_restJson1UpdateVoiceTemplateCommand = exports.serializeAws_restJson1UpdateVoiceChannelCommand = exports.serializeAws_restJson1UpdateTemplateActiveVersionCommand = exports.serializeAws_restJson1UpdateSmsTemplateCommand = exports.serializeAws_restJson1UpdateSmsChannelCommand = exports.serializeAws_restJson1UpdateSegmentCommand = exports.serializeAws_restJson1UpdateRecommenderConfigurationCommand = exports.serializeAws_restJson1UpdatePushTemplateCommand = exports.serializeAws_restJson1UpdateJourneyStateCommand = exports.serializeAws_restJson1UpdateJourneyCommand = exports.serializeAws_restJson1UpdateInAppTemplateCommand = exports.serializeAws_restJson1UpdateGcmChannelCommand = exports.serializeAws_restJson1UpdateEndpointsBatchCommand = exports.serializeAws_restJson1UpdateEndpointCommand = exports.serializeAws_restJson1UpdateEmailTemplateCommand = exports.serializeAws_restJson1UpdateEmailChannelCommand = exports.serializeAws_restJson1UpdateCampaignCommand = void 0;
6
- exports.deserializeAws_restJson1ListTagsForResourceCommand = exports.deserializeAws_restJson1ListJourneysCommand = exports.deserializeAws_restJson1GetVoiceTemplateCommand = exports.deserializeAws_restJson1GetVoiceChannelCommand = exports.deserializeAws_restJson1GetUserEndpointsCommand = exports.deserializeAws_restJson1GetSmsTemplateCommand = exports.deserializeAws_restJson1GetSmsChannelCommand = exports.deserializeAws_restJson1GetSegmentVersionsCommand = exports.deserializeAws_restJson1GetSegmentVersionCommand = exports.deserializeAws_restJson1GetSegmentsCommand = exports.deserializeAws_restJson1GetSegmentImportJobsCommand = exports.deserializeAws_restJson1GetSegmentExportJobsCommand = exports.deserializeAws_restJson1GetSegmentCommand = exports.deserializeAws_restJson1GetRecommenderConfigurationsCommand = exports.deserializeAws_restJson1GetRecommenderConfigurationCommand = exports.deserializeAws_restJson1GetPushTemplateCommand = exports.deserializeAws_restJson1GetJourneyExecutionMetricsCommand = exports.deserializeAws_restJson1GetJourneyExecutionActivityMetricsCommand = exports.deserializeAws_restJson1GetJourneyDateRangeKpiCommand = exports.deserializeAws_restJson1GetJourneyCommand = exports.deserializeAws_restJson1GetInAppTemplateCommand = exports.deserializeAws_restJson1GetInAppMessagesCommand = exports.deserializeAws_restJson1GetImportJobsCommand = exports.deserializeAws_restJson1GetImportJobCommand = exports.deserializeAws_restJson1GetGcmChannelCommand = exports.deserializeAws_restJson1GetExportJobsCommand = exports.deserializeAws_restJson1GetExportJobCommand = exports.deserializeAws_restJson1GetEventStreamCommand = exports.deserializeAws_restJson1GetEndpointCommand = exports.deserializeAws_restJson1GetEmailTemplateCommand = exports.deserializeAws_restJson1GetEmailChannelCommand = exports.deserializeAws_restJson1GetChannelsCommand = exports.deserializeAws_restJson1GetCampaignVersionsCommand = exports.deserializeAws_restJson1GetCampaignVersionCommand = exports.deserializeAws_restJson1GetCampaignsCommand = exports.deserializeAws_restJson1GetCampaignDateRangeKpiCommand = exports.deserializeAws_restJson1GetCampaignActivitiesCommand = exports.deserializeAws_restJson1GetCampaignCommand = exports.deserializeAws_restJson1GetBaiduChannelCommand = exports.deserializeAws_restJson1GetAppsCommand = exports.deserializeAws_restJson1GetApplicationSettingsCommand = exports.deserializeAws_restJson1GetApplicationDateRangeKpiCommand = exports.deserializeAws_restJson1GetAppCommand = exports.deserializeAws_restJson1GetApnsVoipSandboxChannelCommand = exports.deserializeAws_restJson1GetApnsVoipChannelCommand = exports.deserializeAws_restJson1GetApnsSandboxChannelCommand = exports.deserializeAws_restJson1GetApnsChannelCommand = exports.deserializeAws_restJson1GetAdmChannelCommand = exports.deserializeAws_restJson1DeleteVoiceTemplateCommand = exports.deserializeAws_restJson1DeleteVoiceChannelCommand = void 0;
7
- exports.deserializeAws_restJson1UpdateVoiceTemplateCommand = exports.deserializeAws_restJson1UpdateVoiceChannelCommand = exports.deserializeAws_restJson1UpdateTemplateActiveVersionCommand = exports.deserializeAws_restJson1UpdateSmsTemplateCommand = exports.deserializeAws_restJson1UpdateSmsChannelCommand = exports.deserializeAws_restJson1UpdateSegmentCommand = exports.deserializeAws_restJson1UpdateRecommenderConfigurationCommand = exports.deserializeAws_restJson1UpdatePushTemplateCommand = exports.deserializeAws_restJson1UpdateJourneyStateCommand = exports.deserializeAws_restJson1UpdateJourneyCommand = exports.deserializeAws_restJson1UpdateInAppTemplateCommand = exports.deserializeAws_restJson1UpdateGcmChannelCommand = exports.deserializeAws_restJson1UpdateEndpointsBatchCommand = exports.deserializeAws_restJson1UpdateEndpointCommand = exports.deserializeAws_restJson1UpdateEmailTemplateCommand = exports.deserializeAws_restJson1UpdateEmailChannelCommand = exports.deserializeAws_restJson1UpdateCampaignCommand = exports.deserializeAws_restJson1UpdateBaiduChannelCommand = exports.deserializeAws_restJson1UpdateApplicationSettingsCommand = exports.deserializeAws_restJson1UpdateApnsVoipSandboxChannelCommand = exports.deserializeAws_restJson1UpdateApnsVoipChannelCommand = exports.deserializeAws_restJson1UpdateApnsSandboxChannelCommand = exports.deserializeAws_restJson1UpdateApnsChannelCommand = exports.deserializeAws_restJson1UpdateAdmChannelCommand = exports.deserializeAws_restJson1UntagResourceCommand = exports.deserializeAws_restJson1TagResourceCommand = exports.deserializeAws_restJson1SendUsersMessagesCommand = exports.deserializeAws_restJson1SendMessagesCommand = exports.deserializeAws_restJson1RemoveAttributesCommand = exports.deserializeAws_restJson1PutEventStreamCommand = exports.deserializeAws_restJson1PutEventsCommand = exports.deserializeAws_restJson1PhoneNumberValidateCommand = exports.deserializeAws_restJson1ListTemplateVersionsCommand = exports.deserializeAws_restJson1ListTemplatesCommand = void 0;
4
+ exports.serializeAws_restJson1UpdateApplicationSettingsCommand = exports.serializeAws_restJson1UpdateApnsVoipSandboxChannelCommand = exports.serializeAws_restJson1UpdateApnsVoipChannelCommand = exports.serializeAws_restJson1UpdateApnsSandboxChannelCommand = exports.serializeAws_restJson1UpdateApnsChannelCommand = exports.serializeAws_restJson1UpdateAdmChannelCommand = exports.serializeAws_restJson1UntagResourceCommand = exports.serializeAws_restJson1TagResourceCommand = exports.serializeAws_restJson1SendUsersMessagesCommand = exports.serializeAws_restJson1SendOTPMessageCommand = exports.serializeAws_restJson1SendMessagesCommand = exports.serializeAws_restJson1RemoveAttributesCommand = exports.serializeAws_restJson1PutEventStreamCommand = exports.serializeAws_restJson1PutEventsCommand = exports.serializeAws_restJson1PhoneNumberValidateCommand = exports.serializeAws_restJson1ListTemplateVersionsCommand = exports.serializeAws_restJson1ListTemplatesCommand = exports.serializeAws_restJson1ListTagsForResourceCommand = exports.serializeAws_restJson1ListJourneysCommand = exports.serializeAws_restJson1GetVoiceTemplateCommand = exports.serializeAws_restJson1GetVoiceChannelCommand = exports.serializeAws_restJson1GetUserEndpointsCommand = exports.serializeAws_restJson1GetSmsTemplateCommand = exports.serializeAws_restJson1GetSmsChannelCommand = exports.serializeAws_restJson1GetSegmentVersionsCommand = exports.serializeAws_restJson1GetSegmentVersionCommand = exports.serializeAws_restJson1GetSegmentsCommand = exports.serializeAws_restJson1GetSegmentImportJobsCommand = exports.serializeAws_restJson1GetSegmentExportJobsCommand = exports.serializeAws_restJson1GetSegmentCommand = exports.serializeAws_restJson1GetRecommenderConfigurationsCommand = exports.serializeAws_restJson1GetRecommenderConfigurationCommand = exports.serializeAws_restJson1GetPushTemplateCommand = exports.serializeAws_restJson1GetJourneyExecutionMetricsCommand = exports.serializeAws_restJson1GetJourneyExecutionActivityMetricsCommand = exports.serializeAws_restJson1GetJourneyDateRangeKpiCommand = exports.serializeAws_restJson1GetJourneyCommand = exports.serializeAws_restJson1GetInAppTemplateCommand = exports.serializeAws_restJson1GetInAppMessagesCommand = exports.serializeAws_restJson1GetImportJobsCommand = exports.serializeAws_restJson1GetImportJobCommand = exports.serializeAws_restJson1GetGcmChannelCommand = exports.serializeAws_restJson1GetExportJobsCommand = exports.serializeAws_restJson1GetExportJobCommand = exports.serializeAws_restJson1GetEventStreamCommand = exports.serializeAws_restJson1GetEndpointCommand = exports.serializeAws_restJson1GetEmailTemplateCommand = exports.serializeAws_restJson1GetEmailChannelCommand = exports.serializeAws_restJson1GetChannelsCommand = exports.serializeAws_restJson1GetCampaignVersionsCommand = void 0;
5
+ exports.deserializeAws_restJson1DeleteSmsChannelCommand = exports.deserializeAws_restJson1DeleteSegmentCommand = exports.deserializeAws_restJson1DeleteRecommenderConfigurationCommand = exports.deserializeAws_restJson1DeletePushTemplateCommand = exports.deserializeAws_restJson1DeleteJourneyCommand = exports.deserializeAws_restJson1DeleteInAppTemplateCommand = exports.deserializeAws_restJson1DeleteGcmChannelCommand = exports.deserializeAws_restJson1DeleteEventStreamCommand = exports.deserializeAws_restJson1DeleteEndpointCommand = exports.deserializeAws_restJson1DeleteEmailTemplateCommand = exports.deserializeAws_restJson1DeleteEmailChannelCommand = exports.deserializeAws_restJson1DeleteCampaignCommand = exports.deserializeAws_restJson1DeleteBaiduChannelCommand = exports.deserializeAws_restJson1DeleteAppCommand = exports.deserializeAws_restJson1DeleteApnsVoipSandboxChannelCommand = exports.deserializeAws_restJson1DeleteApnsVoipChannelCommand = exports.deserializeAws_restJson1DeleteApnsSandboxChannelCommand = exports.deserializeAws_restJson1DeleteApnsChannelCommand = exports.deserializeAws_restJson1DeleteAdmChannelCommand = exports.deserializeAws_restJson1CreateVoiceTemplateCommand = exports.deserializeAws_restJson1CreateSmsTemplateCommand = exports.deserializeAws_restJson1CreateSegmentCommand = exports.deserializeAws_restJson1CreateRecommenderConfigurationCommand = exports.deserializeAws_restJson1CreatePushTemplateCommand = exports.deserializeAws_restJson1CreateJourneyCommand = exports.deserializeAws_restJson1CreateInAppTemplateCommand = exports.deserializeAws_restJson1CreateImportJobCommand = exports.deserializeAws_restJson1CreateExportJobCommand = exports.deserializeAws_restJson1CreateEmailTemplateCommand = exports.deserializeAws_restJson1CreateCampaignCommand = exports.deserializeAws_restJson1CreateAppCommand = exports.serializeAws_restJson1VerifyOTPMessageCommand = exports.serializeAws_restJson1UpdateVoiceTemplateCommand = exports.serializeAws_restJson1UpdateVoiceChannelCommand = exports.serializeAws_restJson1UpdateTemplateActiveVersionCommand = exports.serializeAws_restJson1UpdateSmsTemplateCommand = exports.serializeAws_restJson1UpdateSmsChannelCommand = exports.serializeAws_restJson1UpdateSegmentCommand = exports.serializeAws_restJson1UpdateRecommenderConfigurationCommand = exports.serializeAws_restJson1UpdatePushTemplateCommand = exports.serializeAws_restJson1UpdateJourneyStateCommand = exports.serializeAws_restJson1UpdateJourneyCommand = exports.serializeAws_restJson1UpdateInAppTemplateCommand = exports.serializeAws_restJson1UpdateGcmChannelCommand = exports.serializeAws_restJson1UpdateEndpointsBatchCommand = exports.serializeAws_restJson1UpdateEndpointCommand = exports.serializeAws_restJson1UpdateEmailTemplateCommand = exports.serializeAws_restJson1UpdateEmailChannelCommand = exports.serializeAws_restJson1UpdateCampaignCommand = exports.serializeAws_restJson1UpdateBaiduChannelCommand = void 0;
6
+ exports.deserializeAws_restJson1GetVoiceTemplateCommand = exports.deserializeAws_restJson1GetVoiceChannelCommand = exports.deserializeAws_restJson1GetUserEndpointsCommand = exports.deserializeAws_restJson1GetSmsTemplateCommand = exports.deserializeAws_restJson1GetSmsChannelCommand = exports.deserializeAws_restJson1GetSegmentVersionsCommand = exports.deserializeAws_restJson1GetSegmentVersionCommand = exports.deserializeAws_restJson1GetSegmentsCommand = exports.deserializeAws_restJson1GetSegmentImportJobsCommand = exports.deserializeAws_restJson1GetSegmentExportJobsCommand = exports.deserializeAws_restJson1GetSegmentCommand = exports.deserializeAws_restJson1GetRecommenderConfigurationsCommand = exports.deserializeAws_restJson1GetRecommenderConfigurationCommand = exports.deserializeAws_restJson1GetPushTemplateCommand = exports.deserializeAws_restJson1GetJourneyExecutionMetricsCommand = exports.deserializeAws_restJson1GetJourneyExecutionActivityMetricsCommand = exports.deserializeAws_restJson1GetJourneyDateRangeKpiCommand = exports.deserializeAws_restJson1GetJourneyCommand = exports.deserializeAws_restJson1GetInAppTemplateCommand = exports.deserializeAws_restJson1GetInAppMessagesCommand = exports.deserializeAws_restJson1GetImportJobsCommand = exports.deserializeAws_restJson1GetImportJobCommand = exports.deserializeAws_restJson1GetGcmChannelCommand = exports.deserializeAws_restJson1GetExportJobsCommand = exports.deserializeAws_restJson1GetExportJobCommand = exports.deserializeAws_restJson1GetEventStreamCommand = exports.deserializeAws_restJson1GetEndpointCommand = exports.deserializeAws_restJson1GetEmailTemplateCommand = exports.deserializeAws_restJson1GetEmailChannelCommand = exports.deserializeAws_restJson1GetChannelsCommand = exports.deserializeAws_restJson1GetCampaignVersionsCommand = exports.deserializeAws_restJson1GetCampaignVersionCommand = exports.deserializeAws_restJson1GetCampaignsCommand = exports.deserializeAws_restJson1GetCampaignDateRangeKpiCommand = exports.deserializeAws_restJson1GetCampaignActivitiesCommand = exports.deserializeAws_restJson1GetCampaignCommand = exports.deserializeAws_restJson1GetBaiduChannelCommand = exports.deserializeAws_restJson1GetAppsCommand = exports.deserializeAws_restJson1GetApplicationSettingsCommand = exports.deserializeAws_restJson1GetApplicationDateRangeKpiCommand = exports.deserializeAws_restJson1GetAppCommand = exports.deserializeAws_restJson1GetApnsVoipSandboxChannelCommand = exports.deserializeAws_restJson1GetApnsVoipChannelCommand = exports.deserializeAws_restJson1GetApnsSandboxChannelCommand = exports.deserializeAws_restJson1GetApnsChannelCommand = exports.deserializeAws_restJson1GetAdmChannelCommand = exports.deserializeAws_restJson1DeleteVoiceTemplateCommand = exports.deserializeAws_restJson1DeleteVoiceChannelCommand = exports.deserializeAws_restJson1DeleteUserEndpointsCommand = exports.deserializeAws_restJson1DeleteSmsTemplateCommand = void 0;
7
+ exports.deserializeAws_restJson1VerifyOTPMessageCommand = exports.deserializeAws_restJson1UpdateVoiceTemplateCommand = exports.deserializeAws_restJson1UpdateVoiceChannelCommand = exports.deserializeAws_restJson1UpdateTemplateActiveVersionCommand = exports.deserializeAws_restJson1UpdateSmsTemplateCommand = exports.deserializeAws_restJson1UpdateSmsChannelCommand = exports.deserializeAws_restJson1UpdateSegmentCommand = exports.deserializeAws_restJson1UpdateRecommenderConfigurationCommand = exports.deserializeAws_restJson1UpdatePushTemplateCommand = exports.deserializeAws_restJson1UpdateJourneyStateCommand = exports.deserializeAws_restJson1UpdateJourneyCommand = exports.deserializeAws_restJson1UpdateInAppTemplateCommand = exports.deserializeAws_restJson1UpdateGcmChannelCommand = exports.deserializeAws_restJson1UpdateEndpointsBatchCommand = exports.deserializeAws_restJson1UpdateEndpointCommand = exports.deserializeAws_restJson1UpdateEmailTemplateCommand = exports.deserializeAws_restJson1UpdateEmailChannelCommand = exports.deserializeAws_restJson1UpdateCampaignCommand = exports.deserializeAws_restJson1UpdateBaiduChannelCommand = exports.deserializeAws_restJson1UpdateApplicationSettingsCommand = exports.deserializeAws_restJson1UpdateApnsVoipSandboxChannelCommand = exports.deserializeAws_restJson1UpdateApnsVoipChannelCommand = exports.deserializeAws_restJson1UpdateApnsSandboxChannelCommand = exports.deserializeAws_restJson1UpdateApnsChannelCommand = exports.deserializeAws_restJson1UpdateAdmChannelCommand = exports.deserializeAws_restJson1UntagResourceCommand = exports.deserializeAws_restJson1TagResourceCommand = exports.deserializeAws_restJson1SendUsersMessagesCommand = exports.deserializeAws_restJson1SendOTPMessageCommand = exports.deserializeAws_restJson1SendMessagesCommand = exports.deserializeAws_restJson1RemoveAttributesCommand = exports.deserializeAws_restJson1PutEventStreamCommand = exports.deserializeAws_restJson1PutEventsCommand = exports.deserializeAws_restJson1PhoneNumberValidateCommand = exports.deserializeAws_restJson1ListTemplateVersionsCommand = exports.deserializeAws_restJson1ListTemplatesCommand = exports.deserializeAws_restJson1ListTagsForResourceCommand = exports.deserializeAws_restJson1ListJourneysCommand = void 0;
8
8
  const protocol_http_1 = require("@aws-sdk/protocol-http");
9
9
  const smithy_client_1 = require("@aws-sdk/smithy-client");
10
10
  const serializeAws_restJson1CreateAppCommand = async (input, context) => {
@@ -2940,6 +2940,41 @@ const serializeAws_restJson1SendMessagesCommand = async (input, context) => {
2940
2940
  });
2941
2941
  };
2942
2942
  exports.serializeAws_restJson1SendMessagesCommand = serializeAws_restJson1SendMessagesCommand;
2943
+ const serializeAws_restJson1SendOTPMessageCommand = async (input, context) => {
2944
+ const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
2945
+ const headers = {
2946
+ "content-type": "application/json",
2947
+ };
2948
+ let resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/v1/apps/{ApplicationId}/otp";
2949
+ if (input.ApplicationId !== undefined) {
2950
+ const labelValue = input.ApplicationId;
2951
+ if (labelValue.length <= 0) {
2952
+ throw new Error("Empty value provided for input HTTP label: ApplicationId.");
2953
+ }
2954
+ resolvedPath = resolvedPath.replace("{ApplicationId}", smithy_client_1.extendedEncodeURIComponent(labelValue));
2955
+ }
2956
+ else {
2957
+ throw new Error("No value provided for input HTTP label: ApplicationId.");
2958
+ }
2959
+ let body;
2960
+ if (input.SendOTPMessageRequestParameters !== undefined) {
2961
+ body = serializeAws_restJson1SendOTPMessageRequestParameters(input.SendOTPMessageRequestParameters, context);
2962
+ }
2963
+ if (body === undefined) {
2964
+ body = {};
2965
+ }
2966
+ body = JSON.stringify(body);
2967
+ return new protocol_http_1.HttpRequest({
2968
+ protocol,
2969
+ hostname,
2970
+ port,
2971
+ method: "POST",
2972
+ headers,
2973
+ path: resolvedPath,
2974
+ body,
2975
+ });
2976
+ };
2977
+ exports.serializeAws_restJson1SendOTPMessageCommand = serializeAws_restJson1SendOTPMessageCommand;
2943
2978
  const serializeAws_restJson1SendUsersMessagesCommand = async (input, context) => {
2944
2979
  const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
2945
2980
  const headers = {
@@ -3974,6 +4009,41 @@ const serializeAws_restJson1UpdateVoiceTemplateCommand = async (input, context)
3974
4009
  });
3975
4010
  };
3976
4011
  exports.serializeAws_restJson1UpdateVoiceTemplateCommand = serializeAws_restJson1UpdateVoiceTemplateCommand;
4012
+ const serializeAws_restJson1VerifyOTPMessageCommand = async (input, context) => {
4013
+ const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
4014
+ const headers = {
4015
+ "content-type": "application/json",
4016
+ };
4017
+ let resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/v1/apps/{ApplicationId}/verify-otp";
4018
+ if (input.ApplicationId !== undefined) {
4019
+ const labelValue = input.ApplicationId;
4020
+ if (labelValue.length <= 0) {
4021
+ throw new Error("Empty value provided for input HTTP label: ApplicationId.");
4022
+ }
4023
+ resolvedPath = resolvedPath.replace("{ApplicationId}", smithy_client_1.extendedEncodeURIComponent(labelValue));
4024
+ }
4025
+ else {
4026
+ throw new Error("No value provided for input HTTP label: ApplicationId.");
4027
+ }
4028
+ let body;
4029
+ if (input.VerifyOTPMessageRequestParameters !== undefined) {
4030
+ body = serializeAws_restJson1VerifyOTPMessageRequestParameters(input.VerifyOTPMessageRequestParameters, context);
4031
+ }
4032
+ if (body === undefined) {
4033
+ body = {};
4034
+ }
4035
+ body = JSON.stringify(body);
4036
+ return new protocol_http_1.HttpRequest({
4037
+ protocol,
4038
+ hostname,
4039
+ port,
4040
+ method: "POST",
4041
+ headers,
4042
+ path: resolvedPath,
4043
+ body,
4044
+ });
4045
+ };
4046
+ exports.serializeAws_restJson1VerifyOTPMessageCommand = serializeAws_restJson1VerifyOTPMessageCommand;
3977
4047
  const deserializeAws_restJson1CreateAppCommand = async (output, context) => {
3978
4048
  if (output.statusCode !== 201 && output.statusCode >= 300) {
3979
4049
  return deserializeAws_restJson1CreateAppCommandError(output, context);
@@ -12282,6 +12352,100 @@ const deserializeAws_restJson1SendMessagesCommandError = async (output, context)
12282
12352
  delete response.Message;
12283
12353
  return Promise.reject(Object.assign(new Error(message), response));
12284
12354
  };
12355
+ const deserializeAws_restJson1SendOTPMessageCommand = async (output, context) => {
12356
+ if (output.statusCode !== 200 && output.statusCode >= 300) {
12357
+ return deserializeAws_restJson1SendOTPMessageCommandError(output, context);
12358
+ }
12359
+ const contents = {
12360
+ $metadata: deserializeMetadata(output),
12361
+ MessageResponse: undefined,
12362
+ };
12363
+ const data = smithy_client_1.expectObject(await parseBody(output.body, context));
12364
+ contents.MessageResponse = deserializeAws_restJson1MessageResponse(data, context);
12365
+ return Promise.resolve(contents);
12366
+ };
12367
+ exports.deserializeAws_restJson1SendOTPMessageCommand = deserializeAws_restJson1SendOTPMessageCommand;
12368
+ const deserializeAws_restJson1SendOTPMessageCommandError = async (output, context) => {
12369
+ const parsedOutput = {
12370
+ ...output,
12371
+ body: await parseBody(output.body, context),
12372
+ };
12373
+ let response;
12374
+ let errorCode = "UnknownError";
12375
+ errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
12376
+ switch (errorCode) {
12377
+ case "BadRequestException":
12378
+ case "com.amazonaws.pinpoint#BadRequestException":
12379
+ response = {
12380
+ ...(await deserializeAws_restJson1BadRequestExceptionResponse(parsedOutput, context)),
12381
+ name: errorCode,
12382
+ $metadata: deserializeMetadata(output),
12383
+ };
12384
+ break;
12385
+ case "ForbiddenException":
12386
+ case "com.amazonaws.pinpoint#ForbiddenException":
12387
+ response = {
12388
+ ...(await deserializeAws_restJson1ForbiddenExceptionResponse(parsedOutput, context)),
12389
+ name: errorCode,
12390
+ $metadata: deserializeMetadata(output),
12391
+ };
12392
+ break;
12393
+ case "InternalServerErrorException":
12394
+ case "com.amazonaws.pinpoint#InternalServerErrorException":
12395
+ response = {
12396
+ ...(await deserializeAws_restJson1InternalServerErrorExceptionResponse(parsedOutput, context)),
12397
+ name: errorCode,
12398
+ $metadata: deserializeMetadata(output),
12399
+ };
12400
+ break;
12401
+ case "MethodNotAllowedException":
12402
+ case "com.amazonaws.pinpoint#MethodNotAllowedException":
12403
+ response = {
12404
+ ...(await deserializeAws_restJson1MethodNotAllowedExceptionResponse(parsedOutput, context)),
12405
+ name: errorCode,
12406
+ $metadata: deserializeMetadata(output),
12407
+ };
12408
+ break;
12409
+ case "NotFoundException":
12410
+ case "com.amazonaws.pinpoint#NotFoundException":
12411
+ response = {
12412
+ ...(await deserializeAws_restJson1NotFoundExceptionResponse(parsedOutput, context)),
12413
+ name: errorCode,
12414
+ $metadata: deserializeMetadata(output),
12415
+ };
12416
+ break;
12417
+ case "PayloadTooLargeException":
12418
+ case "com.amazonaws.pinpoint#PayloadTooLargeException":
12419
+ response = {
12420
+ ...(await deserializeAws_restJson1PayloadTooLargeExceptionResponse(parsedOutput, context)),
12421
+ name: errorCode,
12422
+ $metadata: deserializeMetadata(output),
12423
+ };
12424
+ break;
12425
+ case "TooManyRequestsException":
12426
+ case "com.amazonaws.pinpoint#TooManyRequestsException":
12427
+ response = {
12428
+ ...(await deserializeAws_restJson1TooManyRequestsExceptionResponse(parsedOutput, context)),
12429
+ name: errorCode,
12430
+ $metadata: deserializeMetadata(output),
12431
+ };
12432
+ break;
12433
+ default:
12434
+ const parsedBody = parsedOutput.body;
12435
+ errorCode = parsedBody.code || parsedBody.Code || errorCode;
12436
+ response = {
12437
+ ...parsedBody,
12438
+ name: `${errorCode}`,
12439
+ message: parsedBody.message || parsedBody.Message || errorCode,
12440
+ $fault: "client",
12441
+ $metadata: deserializeMetadata(output),
12442
+ };
12443
+ }
12444
+ const message = response.message || response.Message || errorCode;
12445
+ response.message = message;
12446
+ delete response.Message;
12447
+ return Promise.reject(Object.assign(new Error(message), response));
12448
+ };
12285
12449
  const deserializeAws_restJson1SendUsersMessagesCommand = async (output, context) => {
12286
12450
  if (output.statusCode !== 200 && output.statusCode >= 300) {
12287
12451
  return deserializeAws_restJson1SendUsersMessagesCommandError(output, context);
@@ -14712,6 +14876,100 @@ const deserializeAws_restJson1UpdateVoiceTemplateCommandError = async (output, c
14712
14876
  delete response.Message;
14713
14877
  return Promise.reject(Object.assign(new Error(message), response));
14714
14878
  };
14879
+ const deserializeAws_restJson1VerifyOTPMessageCommand = async (output, context) => {
14880
+ if (output.statusCode !== 200 && output.statusCode >= 300) {
14881
+ return deserializeAws_restJson1VerifyOTPMessageCommandError(output, context);
14882
+ }
14883
+ const contents = {
14884
+ $metadata: deserializeMetadata(output),
14885
+ VerificationResponse: undefined,
14886
+ };
14887
+ const data = smithy_client_1.expectObject(await parseBody(output.body, context));
14888
+ contents.VerificationResponse = deserializeAws_restJson1VerificationResponse(data, context);
14889
+ return Promise.resolve(contents);
14890
+ };
14891
+ exports.deserializeAws_restJson1VerifyOTPMessageCommand = deserializeAws_restJson1VerifyOTPMessageCommand;
14892
+ const deserializeAws_restJson1VerifyOTPMessageCommandError = async (output, context) => {
14893
+ const parsedOutput = {
14894
+ ...output,
14895
+ body: await parseBody(output.body, context),
14896
+ };
14897
+ let response;
14898
+ let errorCode = "UnknownError";
14899
+ errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
14900
+ switch (errorCode) {
14901
+ case "BadRequestException":
14902
+ case "com.amazonaws.pinpoint#BadRequestException":
14903
+ response = {
14904
+ ...(await deserializeAws_restJson1BadRequestExceptionResponse(parsedOutput, context)),
14905
+ name: errorCode,
14906
+ $metadata: deserializeMetadata(output),
14907
+ };
14908
+ break;
14909
+ case "ForbiddenException":
14910
+ case "com.amazonaws.pinpoint#ForbiddenException":
14911
+ response = {
14912
+ ...(await deserializeAws_restJson1ForbiddenExceptionResponse(parsedOutput, context)),
14913
+ name: errorCode,
14914
+ $metadata: deserializeMetadata(output),
14915
+ };
14916
+ break;
14917
+ case "InternalServerErrorException":
14918
+ case "com.amazonaws.pinpoint#InternalServerErrorException":
14919
+ response = {
14920
+ ...(await deserializeAws_restJson1InternalServerErrorExceptionResponse(parsedOutput, context)),
14921
+ name: errorCode,
14922
+ $metadata: deserializeMetadata(output),
14923
+ };
14924
+ break;
14925
+ case "MethodNotAllowedException":
14926
+ case "com.amazonaws.pinpoint#MethodNotAllowedException":
14927
+ response = {
14928
+ ...(await deserializeAws_restJson1MethodNotAllowedExceptionResponse(parsedOutput, context)),
14929
+ name: errorCode,
14930
+ $metadata: deserializeMetadata(output),
14931
+ };
14932
+ break;
14933
+ case "NotFoundException":
14934
+ case "com.amazonaws.pinpoint#NotFoundException":
14935
+ response = {
14936
+ ...(await deserializeAws_restJson1NotFoundExceptionResponse(parsedOutput, context)),
14937
+ name: errorCode,
14938
+ $metadata: deserializeMetadata(output),
14939
+ };
14940
+ break;
14941
+ case "PayloadTooLargeException":
14942
+ case "com.amazonaws.pinpoint#PayloadTooLargeException":
14943
+ response = {
14944
+ ...(await deserializeAws_restJson1PayloadTooLargeExceptionResponse(parsedOutput, context)),
14945
+ name: errorCode,
14946
+ $metadata: deserializeMetadata(output),
14947
+ };
14948
+ break;
14949
+ case "TooManyRequestsException":
14950
+ case "com.amazonaws.pinpoint#TooManyRequestsException":
14951
+ response = {
14952
+ ...(await deserializeAws_restJson1TooManyRequestsExceptionResponse(parsedOutput, context)),
14953
+ name: errorCode,
14954
+ $metadata: deserializeMetadata(output),
14955
+ };
14956
+ break;
14957
+ default:
14958
+ const parsedBody = parsedOutput.body;
14959
+ errorCode = parsedBody.code || parsedBody.Code || errorCode;
14960
+ response = {
14961
+ ...parsedBody,
14962
+ name: `${errorCode}`,
14963
+ message: parsedBody.message || parsedBody.Message || errorCode,
14964
+ $fault: "client",
14965
+ $metadata: deserializeMetadata(output),
14966
+ };
14967
+ }
14968
+ const message = response.message || response.Message || errorCode;
14969
+ response.message = message;
14970
+ delete response.Message;
14971
+ return Promise.reject(Object.assign(new Error(message), response));
14972
+ };
14715
14973
  const deserializeAws_restJson1BadRequestExceptionResponse = async (parsedOutput, context) => {
14716
14974
  const contents = {
14717
14975
  name: "BadRequestException",
@@ -16222,6 +16480,25 @@ const serializeAws_restJson1SegmentReference = (input, context) => {
16222
16480
  ...(input.Version !== undefined && input.Version !== null && { Version: input.Version }),
16223
16481
  };
16224
16482
  };
16483
+ const serializeAws_restJson1SendOTPMessageRequestParameters = (input, context) => {
16484
+ return {
16485
+ ...(input.AllowedAttempts !== undefined &&
16486
+ input.AllowedAttempts !== null && { AllowedAttempts: input.AllowedAttempts }),
16487
+ ...(input.BrandName !== undefined && input.BrandName !== null && { BrandName: input.BrandName }),
16488
+ ...(input.Channel !== undefined && input.Channel !== null && { Channel: input.Channel }),
16489
+ ...(input.CodeLength !== undefined && input.CodeLength !== null && { CodeLength: input.CodeLength }),
16490
+ ...(input.DestinationIdentity !== undefined &&
16491
+ input.DestinationIdentity !== null && { DestinationIdentity: input.DestinationIdentity }),
16492
+ ...(input.EntityId !== undefined && input.EntityId !== null && { EntityId: input.EntityId }),
16493
+ ...(input.Language !== undefined && input.Language !== null && { Language: input.Language }),
16494
+ ...(input.OriginationIdentity !== undefined &&
16495
+ input.OriginationIdentity !== null && { OriginationIdentity: input.OriginationIdentity }),
16496
+ ...(input.ReferenceId !== undefined && input.ReferenceId !== null && { ReferenceId: input.ReferenceId }),
16497
+ ...(input.TemplateId !== undefined && input.TemplateId !== null && { TemplateId: input.TemplateId }),
16498
+ ...(input.ValidityPeriod !== undefined &&
16499
+ input.ValidityPeriod !== null && { ValidityPeriod: input.ValidityPeriod }),
16500
+ };
16501
+ };
16225
16502
  const serializeAws_restJson1SendUsersMessageRequest = (input, context) => {
16226
16503
  return {
16227
16504
  ...(input.Context !== undefined &&
@@ -16409,6 +16686,14 @@ const serializeAws_restJson1UpdateRecommenderConfigurationShape = (input, contex
16409
16686
  input.RecommendationsPerMessage !== null && { RecommendationsPerMessage: input.RecommendationsPerMessage }),
16410
16687
  };
16411
16688
  };
16689
+ const serializeAws_restJson1VerifyOTPMessageRequestParameters = (input, context) => {
16690
+ return {
16691
+ ...(input.DestinationIdentity !== undefined &&
16692
+ input.DestinationIdentity !== null && { DestinationIdentity: input.DestinationIdentity }),
16693
+ ...(input.Otp !== undefined && input.Otp !== null && { Otp: input.Otp }),
16694
+ ...(input.ReferenceId !== undefined && input.ReferenceId !== null && { ReferenceId: input.ReferenceId }),
16695
+ };
16696
+ };
16412
16697
  const serializeAws_restJson1VoiceChannelRequest = (input, context) => {
16413
16698
  return {
16414
16699
  ...(input.Enabled !== undefined && input.Enabled !== null && { Enabled: input.Enabled }),
@@ -18573,6 +18858,11 @@ const deserializeAws_restJson1TreatmentResource = (output, context) => {
18573
18858
  TreatmentName: smithy_client_1.expectString(output.TreatmentName),
18574
18859
  };
18575
18860
  };
18861
+ const deserializeAws_restJson1VerificationResponse = (output, context) => {
18862
+ return {
18863
+ Valid: smithy_client_1.expectBoolean(output.Valid),
18864
+ };
18865
+ };
18576
18866
  const deserializeAws_restJson1VoiceChannelResponse = (output, context) => {
18577
18867
  return {
18578
18868
  ApplicationId: smithy_client_1.expectString(output.ApplicationId),
@@ -13,13 +13,18 @@ const util_body_length_browser_1 = require("@aws-sdk/util-body-length-browser");
13
13
  const util_user_agent_browser_1 = require("@aws-sdk/util-user-agent-browser");
14
14
  const util_utf8_browser_1 = require("@aws-sdk/util-utf8-browser");
15
15
  const runtimeConfig_shared_1 = require("./runtimeConfig.shared");
16
+ const smithy_client_1 = require("@aws-sdk/smithy-client");
17
+ const util_defaults_mode_browser_1 = require("@aws-sdk/util-defaults-mode-browser");
16
18
  const getRuntimeConfig = (config) => {
17
19
  var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q;
20
+ const defaultsMode = util_defaults_mode_browser_1.resolveDefaultsModeConfig(config);
21
+ const defaultConfigProvider = () => defaultsMode().then(smithy_client_1.loadConfigsForDefaultMode);
18
22
  const clientSharedValues = runtimeConfig_shared_1.getRuntimeConfig(config);
19
23
  return {
20
24
  ...clientSharedValues,
21
25
  ...config,
22
26
  runtime: "browser",
27
+ defaultsMode,
23
28
  base64Decoder: (_a = config === null || config === void 0 ? void 0 : config.base64Decoder) !== null && _a !== void 0 ? _a : util_base64_browser_1.fromBase64,
24
29
  base64Encoder: (_b = config === null || config === void 0 ? void 0 : config.base64Encoder) !== null && _b !== void 0 ? _b : util_base64_browser_1.toBase64,
25
30
  bodyLengthChecker: (_c = config === null || config === void 0 ? void 0 : config.bodyLengthChecker) !== null && _c !== void 0 ? _c : util_body_length_browser_1.calculateBodyLength,
@@ -27,8 +32,8 @@ const getRuntimeConfig = (config) => {
27
32
  defaultUserAgentProvider: (_e = config === null || config === void 0 ? void 0 : config.defaultUserAgentProvider) !== null && _e !== void 0 ? _e : util_user_agent_browser_1.defaultUserAgent({ serviceId: clientSharedValues.serviceId, clientVersion: package_json_1.default.version }),
28
33
  maxAttempts: (_f = config === null || config === void 0 ? void 0 : config.maxAttempts) !== null && _f !== void 0 ? _f : middleware_retry_1.DEFAULT_MAX_ATTEMPTS,
29
34
  region: (_g = config === null || config === void 0 ? void 0 : config.region) !== null && _g !== void 0 ? _g : invalid_dependency_1.invalidProvider("Region is missing"),
30
- requestHandler: (_h = config === null || config === void 0 ? void 0 : config.requestHandler) !== null && _h !== void 0 ? _h : new fetch_http_handler_1.FetchHttpHandler(),
31
- retryMode: (_j = config === null || config === void 0 ? void 0 : config.retryMode) !== null && _j !== void 0 ? _j : (() => Promise.resolve(middleware_retry_1.DEFAULT_RETRY_MODE)),
35
+ requestHandler: (_h = config === null || config === void 0 ? void 0 : config.requestHandler) !== null && _h !== void 0 ? _h : new fetch_http_handler_1.FetchHttpHandler(defaultConfigProvider),
36
+ retryMode: (_j = config === null || config === void 0 ? void 0 : config.retryMode) !== null && _j !== void 0 ? _j : (async () => (await defaultConfigProvider()).retryMode || middleware_retry_1.DEFAULT_RETRY_MODE),
32
37
  sha256: (_k = config === null || config === void 0 ? void 0 : config.sha256) !== null && _k !== void 0 ? _k : sha256_browser_1.Sha256,
33
38
  streamCollector: (_l = config === null || config === void 0 ? void 0 : config.streamCollector) !== null && _l !== void 0 ? _l : fetch_http_handler_1.streamCollector,
34
39
  useDualstackEndpoint: (_m = config === null || config === void 0 ? void 0 : config.useDualstackEndpoint) !== null && _m !== void 0 ? _m : (() => Promise.resolve(config_resolver_1.DEFAULT_USE_DUALSTACK_ENDPOINT)),
@@ -16,14 +16,17 @@ const util_user_agent_node_1 = require("@aws-sdk/util-user-agent-node");
16
16
  const util_utf8_node_1 = require("@aws-sdk/util-utf8-node");
17
17
  const runtimeConfig_shared_1 = require("./runtimeConfig.shared");
18
18
  const smithy_client_1 = require("@aws-sdk/smithy-client");
19
+ const util_defaults_mode_node_1 = require("@aws-sdk/util-defaults-mode-node");
19
20
  const getRuntimeConfig = (config) => {
20
21
  var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q;
21
- smithy_client_1.emitWarningIfUnsupportedVersion(process.version);
22
+ const defaultsMode = util_defaults_mode_node_1.resolveDefaultsModeConfig(config);
23
+ const defaultConfigProvider = () => defaultsMode().then(smithy_client_1.loadConfigsForDefaultMode);
22
24
  const clientSharedValues = runtimeConfig_shared_1.getRuntimeConfig(config);
23
25
  return {
24
26
  ...clientSharedValues,
25
27
  ...config,
26
28
  runtime: "node",
29
+ defaultsMode,
27
30
  base64Decoder: (_a = config === null || config === void 0 ? void 0 : config.base64Decoder) !== null && _a !== void 0 ? _a : util_base64_node_1.fromBase64,
28
31
  base64Encoder: (_b = config === null || config === void 0 ? void 0 : config.base64Encoder) !== null && _b !== void 0 ? _b : util_base64_node_1.toBase64,
29
32
  bodyLengthChecker: (_c = config === null || config === void 0 ? void 0 : config.bodyLengthChecker) !== null && _c !== void 0 ? _c : util_body_length_node_1.calculateBodyLength,
@@ -31,8 +34,11 @@ const getRuntimeConfig = (config) => {
31
34
  defaultUserAgentProvider: (_e = config === null || config === void 0 ? void 0 : config.defaultUserAgentProvider) !== null && _e !== void 0 ? _e : util_user_agent_node_1.defaultUserAgent({ serviceId: clientSharedValues.serviceId, clientVersion: package_json_1.default.version }),
32
35
  maxAttempts: (_f = config === null || config === void 0 ? void 0 : config.maxAttempts) !== null && _f !== void 0 ? _f : node_config_provider_1.loadConfig(middleware_retry_1.NODE_MAX_ATTEMPT_CONFIG_OPTIONS),
33
36
  region: (_g = config === null || config === void 0 ? void 0 : config.region) !== null && _g !== void 0 ? _g : node_config_provider_1.loadConfig(config_resolver_1.NODE_REGION_CONFIG_OPTIONS, config_resolver_1.NODE_REGION_CONFIG_FILE_OPTIONS),
34
- requestHandler: (_h = config === null || config === void 0 ? void 0 : config.requestHandler) !== null && _h !== void 0 ? _h : new node_http_handler_1.NodeHttpHandler(),
35
- retryMode: (_j = config === null || config === void 0 ? void 0 : config.retryMode) !== null && _j !== void 0 ? _j : node_config_provider_1.loadConfig(middleware_retry_1.NODE_RETRY_MODE_CONFIG_OPTIONS),
37
+ requestHandler: (_h = config === null || config === void 0 ? void 0 : config.requestHandler) !== null && _h !== void 0 ? _h : new node_http_handler_1.NodeHttpHandler(defaultConfigProvider),
38
+ retryMode: (_j = config === null || config === void 0 ? void 0 : config.retryMode) !== null && _j !== void 0 ? _j : node_config_provider_1.loadConfig({
39
+ ...middleware_retry_1.NODE_RETRY_MODE_CONFIG_OPTIONS,
40
+ default: async () => (await defaultConfigProvider()).retryMode || middleware_retry_1.DEFAULT_RETRY_MODE,
41
+ }),
36
42
  sha256: (_k = config === null || config === void 0 ? void 0 : config.sha256) !== null && _k !== void 0 ? _k : hash_node_1.Hash.bind(null, "sha256"),
37
43
  streamCollector: (_l = config === null || config === void 0 ? void 0 : config.streamCollector) !== null && _l !== void 0 ? _l : node_http_handler_1.streamCollector,
38
44
  useDualstackEndpoint: (_m = config === null || config === void 0 ? void 0 : config.useDualstackEndpoint) !== null && _m !== void 0 ? _m : node_config_provider_1.loadConfig(config_resolver_1.NODE_USE_DUALSTACK_ENDPOINT_CONFIG_OPTIONS),
@@ -89,6 +89,7 @@ import { PutEventsCommand } from "./commands/PutEventsCommand";
89
89
  import { PutEventStreamCommand, } from "./commands/PutEventStreamCommand";
90
90
  import { RemoveAttributesCommand, } from "./commands/RemoveAttributesCommand";
91
91
  import { SendMessagesCommand, } from "./commands/SendMessagesCommand";
92
+ import { SendOTPMessageCommand, } from "./commands/SendOTPMessageCommand";
92
93
  import { SendUsersMessagesCommand, } from "./commands/SendUsersMessagesCommand";
93
94
  import { TagResourceCommand } from "./commands/TagResourceCommand";
94
95
  import { UntagResourceCommand, } from "./commands/UntagResourceCommand";
@@ -116,6 +117,7 @@ import { UpdateSmsTemplateCommand, } from "./commands/UpdateSmsTemplateCommand";
116
117
  import { UpdateTemplateActiveVersionCommand, } from "./commands/UpdateTemplateActiveVersionCommand";
117
118
  import { UpdateVoiceChannelCommand, } from "./commands/UpdateVoiceChannelCommand";
118
119
  import { UpdateVoiceTemplateCommand, } from "./commands/UpdateVoiceTemplateCommand";
120
+ import { VerifyOTPMessageCommand, } from "./commands/VerifyOTPMessageCommand";
119
121
  import { PinpointClient } from "./PinpointClient";
120
122
  var Pinpoint = (function (_super) {
121
123
  __extends(Pinpoint, _super);
@@ -1382,6 +1384,20 @@ var Pinpoint = (function (_super) {
1382
1384
  return this.send(command, optionsOrCb);
1383
1385
  }
1384
1386
  };
1387
+ Pinpoint.prototype.sendOTPMessage = function (args, optionsOrCb, cb) {
1388
+ var command = new SendOTPMessageCommand(args);
1389
+ if (typeof optionsOrCb === "function") {
1390
+ this.send(command, optionsOrCb);
1391
+ }
1392
+ else if (typeof cb === "function") {
1393
+ if (typeof optionsOrCb !== "object")
1394
+ throw new Error("Expect http options but get " + typeof optionsOrCb);
1395
+ this.send(command, optionsOrCb || {}, cb);
1396
+ }
1397
+ else {
1398
+ return this.send(command, optionsOrCb);
1399
+ }
1400
+ };
1385
1401
  Pinpoint.prototype.sendUsersMessages = function (args, optionsOrCb, cb) {
1386
1402
  var command = new SendUsersMessagesCommand(args);
1387
1403
  if (typeof optionsOrCb === "function") {
@@ -1760,6 +1776,20 @@ var Pinpoint = (function (_super) {
1760
1776
  return this.send(command, optionsOrCb);
1761
1777
  }
1762
1778
  };
1779
+ Pinpoint.prototype.verifyOTPMessage = function (args, optionsOrCb, cb) {
1780
+ var command = new VerifyOTPMessageCommand(args);
1781
+ if (typeof optionsOrCb === "function") {
1782
+ this.send(command, optionsOrCb);
1783
+ }
1784
+ else if (typeof cb === "function") {
1785
+ if (typeof optionsOrCb !== "object")
1786
+ throw new Error("Expect http options but get " + typeof optionsOrCb);
1787
+ this.send(command, optionsOrCb || {}, cb);
1788
+ }
1789
+ else {
1790
+ return this.send(command, optionsOrCb);
1791
+ }
1792
+ };
1763
1793
  return Pinpoint;
1764
1794
  }(PinpointClient));
1765
1795
  export { Pinpoint };
@@ -0,0 +1,39 @@
1
+ import { __extends } from "tslib";
2
+ import { getSerdePlugin } from "@aws-sdk/middleware-serde";
3
+ import { Command as $Command } from "@aws-sdk/smithy-client";
4
+ import { SendOTPMessageRequest, SendOTPMessageResponse } from "../models/models_1";
5
+ import { deserializeAws_restJson1SendOTPMessageCommand, serializeAws_restJson1SendOTPMessageCommand, } from "../protocols/Aws_restJson1";
6
+ var SendOTPMessageCommand = (function (_super) {
7
+ __extends(SendOTPMessageCommand, _super);
8
+ function SendOTPMessageCommand(input) {
9
+ var _this = _super.call(this) || this;
10
+ _this.input = input;
11
+ return _this;
12
+ }
13
+ SendOTPMessageCommand.prototype.resolveMiddleware = function (clientStack, configuration, options) {
14
+ this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize));
15
+ var stack = clientStack.concat(this.middlewareStack);
16
+ var logger = configuration.logger;
17
+ var clientName = "PinpointClient";
18
+ var commandName = "SendOTPMessageCommand";
19
+ var handlerExecutionContext = {
20
+ logger: logger,
21
+ clientName: clientName,
22
+ commandName: commandName,
23
+ inputFilterSensitiveLog: SendOTPMessageRequest.filterSensitiveLog,
24
+ outputFilterSensitiveLog: SendOTPMessageResponse.filterSensitiveLog,
25
+ };
26
+ var requestHandler = configuration.requestHandler;
27
+ return stack.resolve(function (request) {
28
+ return requestHandler.handle(request.request, options || {});
29
+ }, handlerExecutionContext);
30
+ };
31
+ SendOTPMessageCommand.prototype.serialize = function (input, context) {
32
+ return serializeAws_restJson1SendOTPMessageCommand(input, context);
33
+ };
34
+ SendOTPMessageCommand.prototype.deserialize = function (output, context) {
35
+ return deserializeAws_restJson1SendOTPMessageCommand(output, context);
36
+ };
37
+ return SendOTPMessageCommand;
38
+ }($Command));
39
+ export { SendOTPMessageCommand };
@@ -0,0 +1,39 @@
1
+ import { __extends } from "tslib";
2
+ import { getSerdePlugin } from "@aws-sdk/middleware-serde";
3
+ import { Command as $Command } from "@aws-sdk/smithy-client";
4
+ import { VerifyOTPMessageRequest, VerifyOTPMessageResponse } from "../models/models_1";
5
+ import { deserializeAws_restJson1VerifyOTPMessageCommand, serializeAws_restJson1VerifyOTPMessageCommand, } from "../protocols/Aws_restJson1";
6
+ var VerifyOTPMessageCommand = (function (_super) {
7
+ __extends(VerifyOTPMessageCommand, _super);
8
+ function VerifyOTPMessageCommand(input) {
9
+ var _this = _super.call(this) || this;
10
+ _this.input = input;
11
+ return _this;
12
+ }
13
+ VerifyOTPMessageCommand.prototype.resolveMiddleware = function (clientStack, configuration, options) {
14
+ this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize));
15
+ var stack = clientStack.concat(this.middlewareStack);
16
+ var logger = configuration.logger;
17
+ var clientName = "PinpointClient";
18
+ var commandName = "VerifyOTPMessageCommand";
19
+ var handlerExecutionContext = {
20
+ logger: logger,
21
+ clientName: clientName,
22
+ commandName: commandName,
23
+ inputFilterSensitiveLog: VerifyOTPMessageRequest.filterSensitiveLog,
24
+ outputFilterSensitiveLog: VerifyOTPMessageResponse.filterSensitiveLog,
25
+ };
26
+ var requestHandler = configuration.requestHandler;
27
+ return stack.resolve(function (request) {
28
+ return requestHandler.handle(request.request, options || {});
29
+ }, handlerExecutionContext);
30
+ };
31
+ VerifyOTPMessageCommand.prototype.serialize = function (input, context) {
32
+ return serializeAws_restJson1VerifyOTPMessageCommand(input, context);
33
+ };
34
+ VerifyOTPMessageCommand.prototype.deserialize = function (output, context) {
35
+ return deserializeAws_restJson1VerifyOTPMessageCommand(output, context);
36
+ };
37
+ return VerifyOTPMessageCommand;
38
+ }($Command));
39
+ export { VerifyOTPMessageCommand };
@@ -88,6 +88,7 @@ export * from "./PutEventStreamCommand";
88
88
  export * from "./PutEventsCommand";
89
89
  export * from "./RemoveAttributesCommand";
90
90
  export * from "./SendMessagesCommand";
91
+ export * from "./SendOTPMessageCommand";
91
92
  export * from "./SendUsersMessagesCommand";
92
93
  export * from "./TagResourceCommand";
93
94
  export * from "./UntagResourceCommand";
@@ -115,3 +116,4 @@ export * from "./UpdateSmsTemplateCommand";
115
116
  export * from "./UpdateTemplateActiveVersionCommand";
116
117
  export * from "./UpdateVoiceChannelCommand";
117
118
  export * from "./UpdateVoiceTemplateCommand";
119
+ export * from "./VerifyOTPMessageCommand";
@@ -52,6 +52,7 @@ var partitionHash = {
52
52
  "ap-south-1",
53
53
  "ap-southeast-1",
54
54
  "ap-southeast-2",
55
+ "ap-southeast-3",
55
56
  "ca-central-1",
56
57
  "eu-central-1",
57
58
  "eu-north-1",