# 400: the request is wrong, fix it

## The error

`400 Invalid Argument: Your request contains invalid parameters.`

## Common sub-causes

1. **Oversize upsert.** A single upsert request is capped (about 2 MB). Stuffing tens of thousands of vectors into one call 400s. Split into batches that fit.
2. **Bad parameter shapes.** `values` not a flat list of numbers, `id` over 512 characters, metadata over 40 KB per record, more than 2048 non-zero sparse values.
3. **Wrong types in filters.** Comparing a string field with `$gt`, or passing a single value where `$in` needs a list.

## Fix

Validate client-side before sending: batch size, id length, metadata size, vector shape. The 400 is deterministic; the same bytes fail the same way every time, so reproduce once, fix the bytes, resend.

## Trap

Retrying a 400 with backoff. The error-handling guide says not to retry client errors (except 429). A 400 retry loop is a very expensive no-op.