stampCreateFiatOnRampCredential method
Future<TSignedRequest>
stampCreateFiatOnRampCredential({
- required TCreateFiatOnRampCredentialBody input,
Produce a SignedRequest from TCreateFiatOnRampCredentialBody by using the client's stamp function.
See also: CreateFiatOnRampCredential.
Implementation
Future<TSignedRequest> stampCreateFiatOnRampCredential({
required TCreateFiatOnRampCredentialBody input,
}) async {
final fullUrl =
'${config.baseUrl}/public/v1/submit/create_fiat_on_ramp_credential';
final body = packActivityBody(
bodyJson: input.toJson(),
fallbackOrganizationId: input.organizationId ??
config.organizationId ??
(throw Exception(
"Missing organization ID, please pass in a sub-organizationId or instantiate the client with one.")),
activityType: 'ACTIVITY_TYPE_CREATE_FIAT_ON_RAMP_CREDENTIAL',
);
final bodyJson = jsonEncode(body);
final stamp = await stamper.stamp(bodyJson);
return TSignedRequest(
body: bodyJson,
stamp: stamp,
url: fullUrl,
);
}