JsonApiOptions¶
class in JsonApiToolkit.Configuration
Configuration options for JsonApiToolkit query processing and security limits.
Constructors¶
JsonApiOptions()¶
Properties¶
MaxFilters : int¶
Maximum number of individual filter conditions allowed in a query. Default: 50. Set to int.MaxValue to disable.
MaxFilterGroups : int¶
Maximum number of logical filter groups (OR/NOT blocks) allowed. Default: 10. Set to int.MaxValue to disable.
MaxFilterDepth : int¶
Maximum nesting depth for filter groups. Default: 3. Set to int.MaxValue to disable.
MaxFilterValueLength : int¶
Maximum length for a single filter value string. Default: 1000. Set to int.MaxValue to disable.
MaxIncludeDepth : int¶
Maximum include depth (e.g., "author.posts.comments" = depth 3). Default: 3. Set to int.MaxValue to disable.
MaxPageSize : int¶
Maximum page size allowed. Requests exceeding this are clamped. Default: 100.
DefaultPageSize : int¶
Default page size when not specified in request. Default: 10.
StrictPagination : bool¶
When true, returns 400 Bad Request for invalid pagination values instead of silently clamping. Invalid page numbers (less than 1) and page sizes (less than 1 or exceeding MaxPageSize) will return errors. Default: false (clamp for backwards compatibility).
EnableDatabaseProjection : bool¶
When true, applies database-level column filtering via EF Core Select() projection when fields[type] is specified in the request. Only fetches requested columns from the database instead of loading full entities and filtering in memory. Not compatible with NativeAOT compilation. Default: false.