@loopback/docs
Version:
Documentation files rendered at [https://loopback.io](https://loopback.io)
35 lines (23 loc) • 972 B
Markdown
lang: en
title: 'API docs: rest.resthttperrors.invaliddata'
keywords: LoopBack 4.0, LoopBack 4, Node.js, TypeScript, OpenAPI
sidebar: lb4_sidebar
editurl: https://github.com/loopbackio/loopback-next/tree/master/packages/rest
permalink: /doc/en/lb4/apidocs.rest.resthttperrors.invaliddata.html
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
[Home](./index.md) > [@loopback/rest](./rest.md) > [RestHttpErrors](./rest.resthttperrors.md) > [invalidData](./rest.resthttperrors.invaliddata.md)
## RestHttpErrors.invalidData() function
<b>Signature:</b>
```typescript
function invalidData<T, Props extends object = {}>(data: T, name: string, extraProperties?: Props): HttpErrors.HttpError & Props;
```
## Parameters
| Parameter | Type | Description |
| --- | --- | --- |
| data | T | |
| name | string | |
| extraProperties | Props | |
<b>Returns:</b>
HttpErrors.HttpError & Props