have you looked at
API Examples · adamhathcock/sharpcompress Wiki · GitHub[
^]
A Sample ...
using (Stream stream = File.OpenRead(@"C:\Code\sharpcompress.rar"))
{
var reader = ReaderFactory.Open(stream);
while (reader.MoveToNextEntry())
{
if (!reader.Entry.IsDirectory)
{
Console.WriteLine(reader.Entry.Key);
reader.WriteEntryToDirectory(@"C:\temp", ExtractOptions.ExtractFullPath | ExtractOptions.Overwrite);
}
}
}
it proves that identifying directories in rar files is possible - doubtless there are other API's out there that may be able to help