private function timestampIsValid($timestamp) { if (!preg_match('/^[\\d]{4}-[\\d]{2}-[\\d]{2}T[\\d]{2}:[\\d]{2}:[\\d]{2}(?:\\.\\d+)?Z$/', $timestamp)) { return false; } return true; }