countVotesPublication method
Implementation
@override
Future<CountVotesPublication> countVotesPublication({String? distinctId, required String targetId}) async {
final response = await dio.post(
'/votes/target_count',
data: {
'api_key': Environment.apiKey,
'campaign': Environment.campaign,
'distinct_id': distinctId,
'target_id': targetId,
}
);
final Map<String, dynamic> responseData = _parseResponse(response.data);
return _jsonToCountVotesPublication(responseData);
}