Stay organized with collections
    
    
      
      Save and categorize content based on your preferences.
    
  
  
    
  
  
  
  
    
  
  
    
    
    
    Builder
    class Builder
    
    Builder for ChangeLogTokenRequest
    Summary
    
    
    Public constructors
    
    Public methods
    
      addDataOriginFilter
      
      fun addDataOriginFilter(dataOriginFilter: DataOrigin): ChangeLogTokenRequest.Builder
      
        
          
            | Parameters | 
          
          
            dataOriginFilter | 
            DataOrigin: list of package names on which to filter the data. 
               If not set logs from all the sources will be returned This value cannot be null. 
             | 
          
        
      
      
     
    
      addMedicalResourceType
      
      fun addMedicalResourceType(medicalResourceType: Int): ChangeLogTokenRequest.Builder
      Add a Medical Resource type to the list of types for which change logs are requested. Record type or Medical Resource types can't both be set.
      
        
          
            | Parameters | 
          
          
            medicalResourceType | 
            Int: Value is android.health.connect.datatypes.MedicalResource#MEDICAL_RESOURCE_TYPE_ALLERGIES_INTOLERANCES, android.health.connect.datatypes.MedicalResource#MEDICAL_RESOURCE_TYPE_CONDITIONS, android.health.connect.datatypes.MedicalResource#MEDICAL_RESOURCE_TYPE_LABORATORY_RESULTS, android.health.connect.datatypes.MedicalResource#MEDICAL_RESOURCE_TYPE_MEDICATIONS, android.health.connect.datatypes.MedicalResource#MEDICAL_RESOURCE_TYPE_PERSONAL_DETAILS, android.health.connect.datatypes.MedicalResource#MEDICAL_RESOURCE_TYPE_PRACTITIONER_DETAILS, android.health.connect.datatypes.MedicalResource#MEDICAL_RESOURCE_TYPE_PREGNANCY, android.health.connect.datatypes.MedicalResource#MEDICAL_RESOURCE_TYPE_PROCEDURES, android.health.connect.datatypes.MedicalResource#MEDICAL_RESOURCE_TYPE_SOCIAL_HISTORY, android.health.connect.datatypes.MedicalResource#MEDICAL_RESOURCE_TYPE_VACCINES, android.health.connect.datatypes.MedicalResource#MEDICAL_RESOURCE_TYPE_VISITS, android.health.connect.datatypes.MedicalResource#MEDICAL_RESOURCE_TYPE_VITAL_SIGNS, or android.health.connect.datatypes.MedicalResource.MEDICAL_RESOURCE_TYPE_DEVICES | 
          
        
      
      
     
    
      addRecordType
      
      fun addRecordType(recordType: Class<out Record!>): ChangeLogTokenRequest.Builder
      Add a Record type to the list of types for which change logs are requested. Record type or Medical Resource types can't both be set.
      
        
          
            | Parameters | 
          
          
            recordType | 
            Class<out Record!>: This value cannot be null. | 
          
        
      
      
     
    
      build
      
      fun build(): ChangeLogTokenRequest
      Returns Object of ChangeLogTokenRequest
      
      
        
          
            | Exceptions | 
          
          
            java.lang.IllegalArgumentException | 
            if validation fails: 
               
                - At least one Record type or Medical Resource type must be set 
 
                - Record type or Medical Resource types can't both be set 
 
               
             | 
          
        
      
     
  
  
  
    
  
 
  
    
    
      
       
    
    
  
  
  Content and code samples on this page are subject to the licenses described in the Content License. Java and OpenJDK are trademarks or registered trademarks of Oracle and/or its affiliates.
  Last updated 2025-09-17 UTC.