The process of building custom applications and tools that interact with Microsoft SharePoint, including SharePoint Online in Microsoft 365.
Hi, you can use below method:
list.TemplateFeatureId == new Guid("f0b085c0-04b6-4b86-b8dc-0b5144d96464")
list.BaseTemplate == 101
list.Title == "Preservation Hold Library";