<!-- mobian-agent-page publisher="dailydev" canonical="https://daily.dev/posts/batch-endpoints-still-need-per-item-authorization-96pks0nmx" -->

---
title: Batch endpoints still need per-item authorization
description: Batch API endpoints that accept multiple resource IDs must authorize each individual ID rather than relying on a single check for the whole request. Without...
canonical: https://daily.dev/posts/batch-endpoints-still-need-per-item-authorization-96pks0nmx
twitter:card: summary_large_image
twitter:site: @dailydotdev
og:type: website
og:site_name: daily.dev
og:title: Batch endpoints still need per-item authorization | daily.dev
og:description: Batch API endpoints that accept multiple resource IDs must authorize each individual ID rather than relying on a single check for the whole request. Without...
og:url: https://daily.dev/posts/batch-endpoints-still-need-per-item-authorization-96pks0nmx
og:image: https://api.daily.dev/og/posts/96PKS0NMx.png
og:image:alt: Batch endpoints still need per-item authorization
og:image:width: 1200
og:image:height: 630
og:locale: en
---

> ## Documentation Index
> Fetch the complete documentation index at: https://daily.dev/llms.txt
> Use this file to discover all available pages before exploring further.

# Batch endpoints still need per-item authorization

**[Auth By Example](https://daily.dev/sources/7eadcwhmohx0bchehapmt)** · [@authbyexample](https://daily.dev/authbyexample) · 1 min read · 0 upvotes · 0 comments

## Summary

Batch API endpoints that accept multiple resource IDs must authorize each individual ID rather than relying on a single check for the whole request. Without per-item checks, an attacker could include one authorized ID alongside unauthorized ones to gain access to resources they shouldn't. The recommended approach is to validate every resource in the batch, or reject the entire batch, before returning or mutating any data.

## Content

A batch API that accepts fifty resource IDs still needs an authorization check on every ID. One allowed item must not unlock the rest of the list. Check each resource (or fail the whole batch) before you return or mutate anything.

## Similar posts on daily.dev

- [Designing safer listItems and getItem permissions](https://daily.dev/posts/designing-safer-listitems-and-getitem-permissions-knn0orlvr) · Advanced Web Machinery · 81 upvotes · 0 comments
- [How to Prevent IDOR Vulnerabilities in Next.js API Routes](https://daily.dev/posts/how-to-prevent-idor-vulnerabilities-in-next-js-api-routes-dmkrw7ol0) · freeCodeCamp · 1 upvotes · 0 comments
- [Everyone Knows About Broken Authorization – So Why Does It Still Work for Attackers?](https://daily.dev/posts/everyone-knows-about-broken-authorization-so-why-does-it-still-work-for-attackers--exddy4tnt) · Security Boulevard · 1 upvotes · 0 comments
- [BOLA: Enumerating an Entire Employee Directory Through a Predictable ID](https://daily.dev/posts/bola-enumerating-an-entire-employee-directory-through-a-predictable-id-5lh2ad7fu) · InfoSec Write-ups · 0 upvotes · 0 comments

---

Tags: [#security](https://daily.dev/tags/security), [#authorization](https://daily.dev/tags/authorization)

[View this post on daily.dev](https://daily.dev/posts/batch-endpoints-still-need-per-item-authorization-96pks0nmx)

```json
{"@context":"https://schema.org","@graph":[{"@type":"Organization","@id":"https://daily.dev/#organization","name":"daily.dev","url":"https://daily.dev","logo":{"@type":"ImageObject","url":"https://daily.dev/apple-touch-icon.png","width":180,"height":180},"sameAs":["https://twitter.com/dailydotdev","https://github.com/dailydotdev","https://www.linkedin.com/company/daily-dev-ltd"]},{"@type":"WebSite","@id":"https://daily.dev/#website","url":"https://daily.dev","name":"daily.dev","publisher":{"@id":"https://daily.dev/#organization"},"potentialAction":{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https://daily.dev/search?q={search_term_string}"},"query-input":"required name=search_term_string"}}]}
{"@context":"https://schema.org","@type":"DiscussionForumPosting","mainEntityOfPage":"https://daily.dev/posts/batch-endpoints-still-need-per-item-authorization-96pks0nmx","headline":"Batch endpoints still need per-item authorization","text":"Batch API endpoints that accept multiple resource IDs must authorize each individual ID rather than relying on a single check for the whole request. Without per-item checks, an attacker could include one authorized ID alongside unauthorized ones to gain access to resources they shouldn't. The recommended approach is to validate every resource in the batch, or reject the entire batch, before returning or mutating any data.","url":"https://daily.dev/posts/batch-endpoints-still-need-per-item-authorization-96pks0nmx","datePublished":"2026-09-25T14:13:20.783Z","dateModified":"2026-09-25T14:13:34.776Z","author":{"@type":"Person","name":"Auth By Example","url":"https://daily.dev/authbyexample","image":"https://media.daily.dev/image/upload/s--Fgz7IgGQ--/f_auto/v1789653205/avatars/avatar_7EADCwHmOHX0bChEhAPmt?_a=BAMAMicg0","interactionStatistic":{"@type":"InteractionCounter","interactionType":{"@type":"EndorseAction"},"userInteractionCount":60}},"interactionStatistic":[{"@type":"InteractionCounter","interactionType":{"@type":"LikeAction"},"userInteractionCount":0},{"@type":"InteractionCounter","interactionType":{"@type":"CommentAction"},"userInteractionCount":0}],"isPartOf":{"@type":"WebPage","url":"https://daily.dev/sources/7eadcwhmohx0bchehapmt","name":"Auth By Example"}}
{"@context":"https://schema.org","@type":"BreadcrumbList","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https://daily.dev"},{"@type":"ListItem","position":2,"name":"Auth By Example","item":"https://daily.dev/sources/7eadcwhmohx0bchehapmt"},{"@type":"ListItem","position":3,"name":"Batch endpoints still need per-item authorization"}]}
```

