Skip to content

BatchResultItem

type BatchResultItem =
| {
id?: string;
index: number;
ok: true;
}
| {
code: string;
index: number;
ok: false;
};

The outcome of one item in a batch import. index is the item’s position in the request array; on failure code is the stable error code (e.g. “INVALID_ARGUMENT”), never a message — collect the failed indexes and retry just those.