:doc:`ConnectCampaignServiceV2 <../../connectcampaignsv2>` / Client / update_campaign_communication_time

**********************************
update_campaign_communication_time
**********************************



.. py:method:: ConnectCampaignServiceV2.Client.update_campaign_communication_time(**kwargs)

  

  Updates the communication time config for a campaign. This API is idempotent.

  

  See also: `AWS API Documentation <https://docs.aws.amazon.com/goto/WebAPI/connectcampaignsv2-2024-04-23/UpdateCampaignCommunicationTime>`_  


  **Request Syntax**
  ::

    response = client.update_campaign_communication_time(
        id='string',
        communicationTimeConfig={
            'localTimeZoneConfig': {
                'defaultTimeZone': 'string',
                'localTimeZoneDetection': [
                    'ZIP_CODE'|'AREA_CODE',
                ]
            },
            'telephony': {
                'openHours': {
                    'dailyHours': {
                        'string': [
                            {
                                'startTime': 'string',
                                'endTime': 'string'
                            },
                        ]
                    }
                },
                'restrictedPeriods': {
                    'restrictedPeriodList': [
                        {
                            'name': 'string',
                            'startDate': 'string',
                            'endDate': 'string'
                        },
                    ]
                }
            },
            'sms': {
                'openHours': {
                    'dailyHours': {
                        'string': [
                            {
                                'startTime': 'string',
                                'endTime': 'string'
                            },
                        ]
                    }
                },
                'restrictedPeriods': {
                    'restrictedPeriodList': [
                        {
                            'name': 'string',
                            'startDate': 'string',
                            'endDate': 'string'
                        },
                    ]
                }
            },
            'email': {
                'openHours': {
                    'dailyHours': {
                        'string': [
                            {
                                'startTime': 'string',
                                'endTime': 'string'
                            },
                        ]
                    }
                },
                'restrictedPeriods': {
                    'restrictedPeriodList': [
                        {
                            'name': 'string',
                            'startDate': 'string',
                            'endDate': 'string'
                        },
                    ]
                }
            },
            'whatsApp': {
                'openHours': {
                    'dailyHours': {
                        'string': [
                            {
                                'startTime': 'string',
                                'endTime': 'string'
                            },
                        ]
                    }
                },
                'restrictedPeriods': {
                    'restrictedPeriodList': [
                        {
                            'name': 'string',
                            'startDate': 'string',
                            'endDate': 'string'
                        },
                    ]
                }
            }
        }
    )
    
  :type id: string
  :param id: **[REQUIRED]** 

    Identifier representing a Campaign

    

  
  :type communicationTimeConfig: dict
  :param communicationTimeConfig: **[REQUIRED]** 

    Campaign communication time config

    

  
    - **localTimeZoneConfig** *(dict) --* **[REQUIRED]** 

      Local time zone config

      

    
      - **defaultTimeZone** *(string) --* 

        Time Zone Id in the IANA format

        

      
      - **localTimeZoneDetection** *(list) --* 

        Local TimeZone Detection method list

        

      
        - *(string) --* 

          Local TimeZone Detection method.

          

        
    
    
    - **telephony** *(dict) --* 

      Time window config

      

    
      - **openHours** *(dict) --* **[REQUIRED]** 

        Open Hours config

        .. note::    This is a Tagged Union structure. Only one of the     following top level keys can be set: ``dailyHours``. 

      
        - **dailyHours** *(dict) --* 

          Daily Hours map

          

        
          - *(string) --* 

            Day of week enum

            

          
            - *(list) --* 

              List of time range

              

            
              - *(dict) --* 

                Time range in 24 hour format

                

              
                - **startTime** *(string) --* **[REQUIRED]** 

                  Time in ISO 8601 format, e.g. T23:11

                  

                
                - **endTime** *(string) --* **[REQUIRED]** 

                  Time in ISO 8601 format, e.g. T23:11

                  

                
              
          
      
    
      
      - **restrictedPeriods** *(dict) --* 

        Restricted period config

        .. note::    This is a Tagged Union structure. Only one of the     following top level keys can be set: ``restrictedPeriodList``. 

      
        - **restrictedPeriodList** *(list) --* 

          List of restricted period

          

        
          - *(dict) --* 

            Restricted period

            

          
            - **name** *(string) --* 

              The name of a restricted period.

              

            
            - **startDate** *(string) --* **[REQUIRED]** 

              Date in ISO 8601 format, e.g. 2024-01-01

              

            
            - **endDate** *(string) --* **[REQUIRED]** 

              Date in ISO 8601 format, e.g. 2024-01-01

              

            
          
      
      
    
    - **sms** *(dict) --* 

      Time window config

      

    
      - **openHours** *(dict) --* **[REQUIRED]** 

        Open Hours config

        .. note::    This is a Tagged Union structure. Only one of the     following top level keys can be set: ``dailyHours``. 

      
        - **dailyHours** *(dict) --* 

          Daily Hours map

          

        
          - *(string) --* 

            Day of week enum

            

          
            - *(list) --* 

              List of time range

              

            
              - *(dict) --* 

                Time range in 24 hour format

                

              
                - **startTime** *(string) --* **[REQUIRED]** 

                  Time in ISO 8601 format, e.g. T23:11

                  

                
                - **endTime** *(string) --* **[REQUIRED]** 

                  Time in ISO 8601 format, e.g. T23:11

                  

                
              
          
      
    
      
      - **restrictedPeriods** *(dict) --* 

        Restricted period config

        .. note::    This is a Tagged Union structure. Only one of the     following top level keys can be set: ``restrictedPeriodList``. 

      
        - **restrictedPeriodList** *(list) --* 

          List of restricted period

          

        
          - *(dict) --* 

            Restricted period

            

          
            - **name** *(string) --* 

              The name of a restricted period.

              

            
            - **startDate** *(string) --* **[REQUIRED]** 

              Date in ISO 8601 format, e.g. 2024-01-01

              

            
            - **endDate** *(string) --* **[REQUIRED]** 

              Date in ISO 8601 format, e.g. 2024-01-01

              

            
          
      
      
    
    - **email** *(dict) --* 

      Time window config

      

    
      - **openHours** *(dict) --* **[REQUIRED]** 

        Open Hours config

        .. note::    This is a Tagged Union structure. Only one of the     following top level keys can be set: ``dailyHours``. 

      
        - **dailyHours** *(dict) --* 

          Daily Hours map

          

        
          - *(string) --* 

            Day of week enum

            

          
            - *(list) --* 

              List of time range

              

            
              - *(dict) --* 

                Time range in 24 hour format

                

              
                - **startTime** *(string) --* **[REQUIRED]** 

                  Time in ISO 8601 format, e.g. T23:11

                  

                
                - **endTime** *(string) --* **[REQUIRED]** 

                  Time in ISO 8601 format, e.g. T23:11

                  

                
              
          
      
    
      
      - **restrictedPeriods** *(dict) --* 

        Restricted period config

        .. note::    This is a Tagged Union structure. Only one of the     following top level keys can be set: ``restrictedPeriodList``. 

      
        - **restrictedPeriodList** *(list) --* 

          List of restricted period

          

        
          - *(dict) --* 

            Restricted period

            

          
            - **name** *(string) --* 

              The name of a restricted period.

              

            
            - **startDate** *(string) --* **[REQUIRED]** 

              Date in ISO 8601 format, e.g. 2024-01-01

              

            
            - **endDate** *(string) --* **[REQUIRED]** 

              Date in ISO 8601 format, e.g. 2024-01-01

              

            
          
      
      
    
    - **whatsApp** *(dict) --* 

      Time window config

      

    
      - **openHours** *(dict) --* **[REQUIRED]** 

        Open Hours config

        .. note::    This is a Tagged Union structure. Only one of the     following top level keys can be set: ``dailyHours``. 

      
        - **dailyHours** *(dict) --* 

          Daily Hours map

          

        
          - *(string) --* 

            Day of week enum

            

          
            - *(list) --* 

              List of time range

              

            
              - *(dict) --* 

                Time range in 24 hour format

                

              
                - **startTime** *(string) --* **[REQUIRED]** 

                  Time in ISO 8601 format, e.g. T23:11

                  

                
                - **endTime** *(string) --* **[REQUIRED]** 

                  Time in ISO 8601 format, e.g. T23:11

                  

                
              
          
      
    
      
      - **restrictedPeriods** *(dict) --* 

        Restricted period config

        .. note::    This is a Tagged Union structure. Only one of the     following top level keys can be set: ``restrictedPeriodList``. 

      
        - **restrictedPeriodList** *(list) --* 

          List of restricted period

          

        
          - *(dict) --* 

            Restricted period

            

          
            - **name** *(string) --* 

              The name of a restricted period.

              

            
            - **startDate** *(string) --* **[REQUIRED]** 

              Date in ISO 8601 format, e.g. 2024-01-01

              

            
            - **endDate** *(string) --* **[REQUIRED]** 

              Date in ISO 8601 format, e.g. 2024-01-01

              

            
          
      
      
    
  
  
  :returns: None
  **Exceptions**
  
  *   :py:class:`ConnectCampaignServiceV2.Client.exceptions.InternalServerException`

  
  *   :py:class:`ConnectCampaignServiceV2.Client.exceptions.ResourceNotFoundException`

  
  *   :py:class:`ConnectCampaignServiceV2.Client.exceptions.ValidationException`

  
  *   :py:class:`ConnectCampaignServiceV2.Client.exceptions.ConflictException`

  
  *   :py:class:`ConnectCampaignServiceV2.Client.exceptions.InvalidCampaignStateException`

  
  *   :py:class:`ConnectCampaignServiceV2.Client.exceptions.AccessDeniedException`

  