Page Contents
Home > @loopback/repository-json-schema > getScopeFilterJsonSchemaFor
getScopeFilterJsonSchemaFor() function
Build a JSON schema describing the format of the “scope” object used to query model instances.
Note we don’t take the model properties into account yet and return a generic json schema allowing any “where” condition.
Signature:
export declare function getScopeFilterJsonSchemaFor(modelCtor: typeof Model, options?: FilterSchemaOptions): JsonSchema;
Parameters
| Parameter | Type | Description |
|---|---|---|
| modelCtor | typeof Model | The model constructor to build the filter schema for. |
| options | [FilterSchemaOptions](/doc/en/lb4/apidocs.repository-json-schema.filterschemaoptions.html) | _(Optional)_ |
Returns:
JsonSchema