Apply an atomic add/remove membership batch
Apply a mixed set of add + remove operations across multiple agents and multiple groups in a single call, all-or-nothing. The whole batch executes inside one database transaction: if any id is invalid, inaccessible, or belongs to a foreign org, the entire batch is rejected and nothing is applied. Membership is a set — an add of an existing member and a remove of a non-member are idempotent no-ops (reported via the *_noop_count fields), so re-sending an identical batch changes nothing and returns 200. Duplicate operations within one request are deduped; the same (agent, group) pair appearing as both an add and a remove is contradictory and rejected. At most 50 operations per request.
Request
- Base URL: https://api.mnemom.ai/v1
- URL: https://api.mnemom.ai/v1/agents/groups:batch
- Auth: one of:
- HTTP bearer
- API key in header X-Mnemom-Api-Key
Request body
Response
Batch applied atomically. added/removed are the ids that actually CHANGED; the *_noop_count fields count operations that were already in the requested state; ops_applied (post-dedupe) may be less than ops_received (raw count) when duplicate operations were collapsed.
Changes
No recorded changes to this operation across all 1 revision of this API.