let subscription = client
.subscriptions()
.create()
.body(dodopayments::models::SubscriptionCreateParams {
billing: dodopayments::models::BillingAddress {
country: "US".to_string(),
city: "San Francisco".to_string(),
state: "CA".to_string(),
street: "1 Market St".to_string(),
zipcode: "94105".to_string(),
},
customer: dodopayments::models::CustomerRequest::AttachExisting(
dodopayments::models::AttachExistingCustomer {
customer_id: "cus_123".to_string(),
},
),
product_id: "pdt_456".to_string(),
quantity: 1,
..Default::default()
})
.await?;
println!("{subscription:?}");