added support and testing for the plans endpoint