getCouponById method
Returns a WooCoupon object with the specified id
.
Implementation
Future<WooCoupon> getCouponById(int id) async {
_setApiResourceUrl(path: 'coupons/' + id.toString());
final response = await get(queryUri.toString());
return WooCoupon.fromJson(response);
}