fetch method
Future<Response<RazorpaySettlement> >
fetch({
- required String settlementId,
- void callback(
- RazorpayApiException?,
- Response<
RazorpaySettlement> ?
Fetches a standard settlement given Settlement ID
@param settlementId - The unique identifier of the settlement.
Implementation
Future<Response<RazorpaySettlement>> fetch({
required String settlementId,
void Function(RazorpayApiException?, Response<RazorpaySettlement>?)?
callback,
}) async {
if (settlementId.isEmpty) {
throw ArgumentError('settlementId is mandatory');
}
return api.get<RazorpaySettlement>(
{'url': '$BASE_URL/$settlementId'},
fromJsonFactory: RazorpaySettlement.fromJson,
callback: callback,
);
}