I would like to add additional json data to a plan, so that our application can read this data during a webhook event. This data should not be visible in the customer portal. Is this possible?
Best Answer
J
Joe Daniel
said
about 7 years ago
@Christian,
We've released support for adding JSON content to different objects in Chargebee. You can use this to add JSON data to your plans.
Here's more on that: https://apidocs.chargebee.com/docs/api#meta_data
Please try it out and let us know if you have questions.
We're currently working on supporting json data addition to a plan/subscription. This will be released in the next couple of weeks and we'll keep you updated on the same.
C
Christian Utama
said
about 7 years ago
Thanks.
Joe Daniel
said
about 7 years ago
Answer
@Christian,
We've released support for adding JSON content to different objects in Chargebee. You can use this to add JSON data to your plans.
Here's more on that: https://apidocs.chargebee.com/docs/api#meta_data
Please try it out and let us know if you have questions.
s
sara
said
over 6 years ago
Hi all,
I'm trying to use the meta_data field both in the customer and in the subscription object, but I can't make it work.
I'm using a hosted page embedded in my webpage. First I use checkout_new to get the hosted page id and that's when I provide the options for the subscription (and the customer), including the meta_data field. Everything goes well after the subscription is submitted in the hosted page, I even get redirected to the correct page, though when I check the customer details and the subscription details, there's no meta data there. I even tried to make the content of the field a string. Doesn't work either.
Unfortunately, there is no option to pass meta data as a parameter when using hosted page APIs. However, you could use the hidden custom fields at the customer/subscription level or use the pass_thru_content parameter to pass the meta data to the hosted pages.
Kindly let us know if you’ve any queries.
1 person likes this
s
sara
said
over 6 years ago
Ok, thanks for the insight!
I've managed to make it work for the customer using the custom fields, but not for the subscription, where I'm doing exactly the same thing.
Christian Utama
I would like to add additional json data to a plan, so that our application can read this data during a webhook event. This data should not be visible in the customer portal. Is this possible?
@Christian,
We've released support for adding JSON content to different objects in Chargebee. You can use this to add JSON data to your plans.
Here's more on that: https://apidocs.chargebee.com/docs/api#meta_data
Please try it out and let us know if you have questions.
- Oldest First
- Popular
- Newest First
Sorted by Oldest FirstCharanya
Hey Christian,
We're currently working on supporting json data addition to a plan/subscription. This will be released in the next couple of weeks and we'll keep you updated on the same.
Christian Utama
Thanks.
Joe Daniel
@Christian,
We've released support for adding JSON content to different objects in Chargebee. You can use this to add JSON data to your plans.
Here's more on that: https://apidocs.chargebee.com/docs/api#meta_data
Please try it out and let us know if you have questions.
sara
Hi all,
I'm trying to use the meta_data field both in the customer and in the subscription object, but I can't make it work.
I'm using a hosted page embedded in my webpage. First I use checkout_new to get the hosted page id and that's when I provide the options for the subscription (and the customer), including the meta_data field. Everything goes well after the subscription is submitted in the hosted page, I even get redirected to the correct page, though when I check the customer details and the subscription details, there's no meta data there. I even tried to make the content of the field a string. Doesn't work either.
Attached are some screenshots.
I wonder if anyone can help me.
Thanks!
Sara
Rajesh Kashyap
Hey Sara,
Unfortunately, there is no option to pass meta data as a parameter when using hosted page APIs. However, you could use the hidden custom fields at the customer/subscription level or use the pass_thru_content parameter to pass the meta data to the hosted pages.
Kindly let us know if you’ve any queries.
1 person likes this
sara
Ok, thanks for the insight!
I've managed to make it work for the customer using the custom fields, but not for the subscription, where I'm doing exactly the same thing.
Any ideas of what can be happening?
Thanks!
Ahana Das
Hey there,
Appologies for missing your message.
To pass the subscription level custom fields with the checkout page URLs, you can use this format : https://domain.chargebee.com/hosted_pages/plans/plan-id?subscription[cf_custom_field_id]=“value.
Say for example you have a custom field named Vat, you can set it’s value in the URL as shown here:
https://vaishnavi-test.chargebee.com/hosted_pages/plans/test-1year?subscription[cf_vat]=“testing”. When customers sign up via this url the custom field will be visible at the Subscription level.
-
Plan price with taxes
-
Can I move my existing subscriptions into ChargeBee?
-
How to create multiple subscriptions for a single customer?
-
Can I change the renewal date of a subscription?
-
Edit/Delete my plans
-
Is there a possibility to add PO number, or a customer's reference number
-
How do I create coupons to offer discount on specific plans/packages or additional services?
-
Proration and credits on plan change
-
Multiple currency support? (Multiple sites)
-
Volume based pricing.
See all 65 topics