---
title: "Discussion on \"Protect APIs from over-fetching/under-fetching - REST vs GraphQL in .NET core\" | Hashnode"
description: "Discussion on \"Protect APIs from over-fetching/under-fetching - REST vs GraphQL in .NET core\". Best Practices Summary\nFor REST in .NET:\n\nUse projection to DTOs (Select instead of .Include() when possible).\n\nDefine endpoint-specific contracts to prevent over-fetch.\n\nUse AsNoTracking and async LI"
url: "https://hashnode.com/posts/protect-apis-from-over-fetching-under-fetching-rest-vs-graphql-in-net-core/6a3e62773bec443709a2e24d"
---

[Feed](https://hashnode.com/feed) /

Discussion

# [Protect APIs from over-fetching/under-fetching - REST vs GraphQL in .NET core](https://nova-globen.hashnode.dev/protect-apis-from-over-fetching-under-fetching-rest-vs-graphql-in-net-core?utm_source=hashnode&utm_medium=feed)

Best Practices Summary For REST in .NET: Use projection to DTOs (Select instead of .Include() when possible). Define endpoint-specific contracts to prevent over-fetch. Use AsNoTracking and async LI

Jun 26 · 3 min read · nova-globen.hashnode.dev  
Read the article

-   [#protect](https://hashnode.com/tag/protect)
-   [#api](https://hashnode.com/tag/api)
-   [#fetching](https://hashnode.com/tag/fetching)
-   [#under](https://hashnode.com/tag/under)

## Written by

[Hossein Esmati](https://hashnode.com/@desmati)

@desmati · Stockholm, Sweden

  
[View profile](https://hashnode.com/@desmati)

## Responses

Markdown supported · ⌘↵ to post

No responses yet.
