CheckoutObject.fromJson constructor
CheckoutObject.fromJson(
- Map data
Implementation
factory CheckoutObject.fromJson(Map data) {
return CheckoutObject(
description: data['description'],
id: data['id'],
isSuccessful: !data.containsKey('message'),
error: data.containsKey('message')
? ErrorObject.fromJson(data)
: ErrorObject(),
name: data['name'],
url: "https://commerce.coinbase.com/checkout/${data['id']}",
pricingType: data['pricing_type'],
requestedInfo: data['requested_info'],
);
}