Is it Possible to Use an ORM Like Subsonic for API Integration?

I’m just starting to explore ORMs and I’m embarking on a new .Net MVC project. In my design, I’ll be constructing model classes, such as one for Video, while using APIs like BrightCove and YouTube to handle data interactions instead of a traditional relational database. This setup leads me to wonder if an ORM like Subsonic can efficiently manage API-based data layers. Any insights or recommendations would be greatly appreciated.

I have experimented with integrating APIs in a .NET MVC project and encountered similar issues. Using an ORM like Subsonic designed for relational databases means you need to implement additional layers to map API responses to your domain models. In my recent project, custom adapters helped bridge the gap between the API data and the ORM’s expectations. Although it is feasible, careful design and management of caching or transformation layers are essential to ensure performance and consistency.

I have experimented with similar implementations and found that integrating an ORM with API endpoints demands additional work. Building an abstraction layer that converts API responses to compatible objects worked better than trying to force the ORM to manage raw API data. In my recent project, I found that carefully planning the data flow and ensuring that the conversion logic was robust allowed for a cleaner separation of concerns. This approach though not plug-and-play does offer flexibility when handling diverse data sources.

i tried a similar approach and had to custom write adapter code. subsonic is designed for dbs so forcing it with api data can messy. consider a direct adapter layer that normalizes your api responses instead. may save you headaches in the long run.