getCampaignStatus method
Gets the status of a campaign in the Instantly API.
Implementation
Future<Campaign?> getCampaignStatus({required String campaignId}) async {
final response = await _dio.get<Map<String, dynamic>>(
'/campaign/get/status',
queryParameters: {
'campaign_id': campaignId,
},
);
if (response.data == null) {
// TODO(@a-wallen): throw a custom exception
return null;
}
return Campaign.fromJson(response.data!);
}