@@ -0,0 +1,17 @@
+module UserProvidedService
+  def credentials(service_name)
+    user_provided_service[service_name]
+  end
+
+  def use_env_var?
+    Rails.env.development? || Rails.env.test?
+  end
+
+  def user_provided_service
+    vcap_services["user-provided"][0]["credentials"]
+  end
+
+  def vcap_services
+    JSON.parse(ENV["VCAP_SERVICES"])
+  end
+end
Surely the arg here is the attribute, since they're all being pulled from the same service?