Get Community Configurations
The getCommunityConfigurations
function retrieves configuration details for the communities. It provides a list of configurations that include a description, type, and associated values.
Usage
- Call the
getCommunityConfigurations()
method to fetch the configurations. - The response will include a list of community configurations if successful.
Example
final LMResponse<GetCommunityConfigurationsResponse> response =
await lmChatClient.getCommunityConfigurations();
if (response.success) {
final configurations = response.data?.communityConfigurations ?? [];
for (final config in configurations) {
print('Description: ${config.description}');
print('Type: ${config.type}');
print('Value: ${config.value}');
}
} else {
print('Failed to fetch configurations: ${response.errorMessage}');
}
Models
GetCommunityConfigurationsResponse
Parameter | Type | Description | Optional |
---|---|---|---|
communityConfigurations | List<CommunityConfigurations> | A list of community configurations |
CommunityConfigurations
Parameter | Type | Description | Optional |
---|---|---|---|
description | String? | A description of the configuration | ✔️ |
type | String? | The type of configuration | ✔️ |
value | Map<String, dynamic>? | The value associated with the configuration | ✔️ |