/** * Get exchange rate detail * @param null $currencyCode */ public function getRate($currencyCode = null) { if (!isset($currencyCode)) { $this->sendError('INVALID_PARAMS', 400); } $data = Rate::getRate($currencyCode); if ($data) { $this->sendSuccess($data); } else { $this->sendError('RATE_NOT_FOUND', 404); } }