dmonaldo Posted May 28, 2015 Report Share Posted May 28, 2015 I am attempting to provision services based on the data posted to a URL when a service is added, suspended, canceled, etc. The data posted when a service is added is adequate, but unfortunately very little information is posted when a service is suspended or canceled. The JSON below is returned when a service is added. When a service is suspended, only the package options are returned (domain_prefix, maximum_contacts, provisioning_id). It would be nice if the client_id and other information was returned when a service is suspended or canceled. { "domain_prefix":"mobile", "maximum_contacts":"100000", "provisioning_id":"123456", "_other":{ "status":"active", "meta":{ "domain_prefix":"mobile" }, "notify_order":"true", "use_module":"true", "pricing_id":"32", "qty":"1", "current_qty":"1", "client_id":"1" } } So I am trying to create a list of all the pricing_id's in order to build a table to provision the services based on what the customer ordered. Does anyone have a simple way of creating a master list of pricing_id's? Any help is appreciated. Quote Link to comment Share on other sites More sharing options...
Jonathan Posted May 28, 2015 Report Share Posted May 28, 2015 Sounds like you need to get the plan name from the pricing ID? You're going to need to do a MySQL query or use Packages::getByPricingId Something like this should get you headed in the right direction if you go the MySQL route: select * from package_pricing left join packages on package_pricing.package_id=packages.id left join pricings on package_pricing.pricing_id=pricings.id; Quote Link to comment Share on other sites More sharing options...
dmonaldo Posted May 28, 2015 Author Report Share Posted May 28, 2015 Actually I want to get a list of all pricing options. That way I can differentiate between monthly and yearly price options for a package. Am I correct in assuming that each price option in a package has a unique pricing_id? Quote Link to comment Share on other sites More sharing options...
Jonathan Posted May 28, 2015 Report Share Posted May 28, 2015 If you use that MySQL query I posed it returns that data Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.