public function datefromApi($date, $std = false) {
         $object = \DateTime::createFromFormat(API::API_DATE_FORMAT, $date);
      
          if ($std) {
            return getdate($object->getTimestamp());
          }

          return $object;
        }