# INVALID_SORT

- Surface: API
- HTTP status: 400
- Details: `{ field: string, allowedFields: string[] }`

## Cause

The requested sort field is not sortable on this collection.

## Fix

Pick a field from `details.allowedFields`. The list is exact: sorting on an unlisted field is refused rather than silently ignored, which would return a differently ordered page than you asked for.

## Related

- [INVALID_PAGINATION](https://splitch.dev/docs/error/INVALID_PAGINATION)
- [VALIDATION_ERROR](https://splitch.dev/docs/error/VALIDATION_ERROR)

Source: https://splitch.dev/docs/error/INVALID_SORT