edit method
Future<Response<RazorpayAccount> >
edit({
- required String accountId,
- required RazorpayAccountUpdateRequestBody params,
- void callback(
- RazorpayApiException?,
- Response<
RazorpayAccount> ?
Update an account
@param accountId - The unique identifier of the account. @param params - Check doc for required params
Implementation
Future<Response<RazorpayAccount>> edit({
required String accountId,
required RazorpayAccountUpdateRequestBody params,
void Function(RazorpayApiException?, Response<RazorpayAccount>?)? callback,
}) async {
if (accountId.isEmpty) {
throw ArgumentError('accountId is required');
}
return api.patch<RazorpayAccount>(
{
'version': 'v2',
'url': '$BASE_URL/$accountId',
'data': params.toJson(),
},
fromJsonFactory: RazorpayAccount.fromJson,
callback: callback,
);
}