@loopback/docs
Version:
Documentation for LoopBack 4
37 lines (23 loc) • 959 B
Markdown
lang: en
title: 'API docs: repository.crudrepository.createall'
keywords: LoopBack 4.0, LoopBack 4
sidebar: lb4_sidebar
permalink: /doc/en/lb4/apidocs.repository.crudrepository.createall.html
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
[Home](./index.md) > [@loopback/repository](./repository.md) > [CrudRepository](./repository.crudrepository.md) > [createAll](./repository.crudrepository.createall.md)
## CrudRepository.createAll() method
Create all records
<b>Signature:</b>
```typescript
createAll(dataObjects: DataObject<T>[], options?: Options): Promise<T[]>;
```
## Parameters
| Parameter | Type | Description |
| --- | --- | --- |
| dataObjects | <code>DataObject<T>[]</code> | An array of data to be created |
| options | <code>Options</code> | Options for the operations |
<b>Returns:</b>
`Promise<T[]>`
A promise of an array of records created