Skip to main content

Get Community Configuration

Retrieve the specific configuration settings tailored for our community by utilizing the designated API. This process ensures you access the customized parameters essential for our community's unique requirements.

Steps to fetch community configuration

  1. Create a GetCommunityConfigurationRequest object using GetCommunityConfigurationRequest.builder() class by passing all the required parameters.
  2. Call getCommunityConfiguration() function using the instance of LMFeedClient.
  3. Process the response LMResponse<GetCommunityConfigurationResponse> as per your requirement.
// object of GetCommunityConfigurationRequest
let request = GetCommunityConfigurationRequest.builder()
.configurationTypes([configurationTypes]) // Types of Configuration you want to fetch
.build()
LMFeedClient.shared.getCommunityConfiguration(request) { [weak self] result in
// get response (LMResponse<GetCommunityConfigurationResponse>)
if (response.success) {
// your function to process the response data
processResponse(response.data)
} else {
// your function to process error message
processError(response.errorMessage)
}
}

Models

GetCommunityConfigurationRequest

VARIABLETYPEDESCRIPTIONOPTIONAL
configurationTypesString[]Types of Configuration

GetCommunityConfigurationResponse

VARIABLETYPEDESCRIPTIONOPTIONAL
communityConfigurationsCommunityConfiguration[]List of Community Configurations

CommunityConfiguration

VARIABLETYPEDESCRIPTIONOPTIONAL
typeStringName of Configuration
descriptionStringDescription of Configuration
valueJSONPreset Values in Configuration