There is a lot of this API class that is forced to use XML (such as getting all subscriptions) which is kinda silly.
Why doesn't this class operate the same between 1 extended class rather than 8 different ones?
Example:
[MAIN CLASS] $chargify = new Chargify($APIKEY,$DOMAINKEY,$RESPONSE='JSON');
[BUILD REQUEST] $chargify->subscriptions->getAll();
[GET REQUEST] $chargify->getRequest(); // already in format
done
current format
[EXTERNAL CLASS $subscriptions = new ChargifySubscription();
OPENS MAIN CLASS] $this->connector = new ChargifyConnector($test_mode); // wut?
[BUILD REQUEST $subscriptions->getAll($vars['page'],$vars['perpage']);
SET RESPONSE TYPE] // why should each function define it?? This is a global setting!!! GRRRR
[GET DATA] $customers = $subscriptions->getXML(); // seemingly unnecessary
There is a lot of this API class that is forced to use XML (such as getting all subscriptions) which is kinda silly.
Why doesn't this class operate the same between 1 extended class rather than 8 different ones?
Example:
[MAIN CLASS] $chargify = new Chargify($APIKEY,$DOMAINKEY,$RESPONSE='JSON');
[BUILD REQUEST] $chargify->subscriptions->getAll();
[GET REQUEST] $chargify->getRequest(); // already in format
done
current format
[EXTERNAL CLASS $subscriptions = new ChargifySubscription();
OPENS MAIN CLASS] $this->connector = new ChargifyConnector($test_mode); // wut?
[BUILD REQUEST $subscriptions->getAll($vars['page'],$vars['perpage']);
SET RESPONSE TYPE] // why should each function define it?? This is a global setting!!! GRRRR
[GET DATA] $customers = $subscriptions->getXML(); // seemingly unnecessary