#paulocentr-subscriptions
1 messages · Page 1 of 1 (latest)
its creatin this arra like this
array*
"customer" => "cus_LkqRPyn0CNbCIF",
"default_payment_method" => "pm_1L3NLcJfhgQ5vfDAvSizvpFf",
"items" => [
"price" => "price_1L3KjjJfhgQ5vfDAtxpaHcm8",
],
"cancel_at" => 1661447779,
]```
Is that not working?
no its returning invalid array
Stripe\Exception\InvalidRequestException with message 'Invalid array'
any clues?
Ah, I think the issue is with what you have in items - you need to be doing this instead:
[
"customer" => "cus_LkqRPyn0CNbCIF",
"default_payment_method" => "pm_1L3NLcJfhgQ5vfDAvSizvpFf",
"items" => [
["price" => "price_1L3KjjJfhgQ5vfDAtxpaHcm8",]
],
"cancel_at" => 1661447779,
]
(note the extra set of brackets around price)
@foggy kestrel Did that solve your issue?