> ## Documentation Index
> Fetch the complete documentation index at: https://apidocs.fohlio.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Create areas in bulk



## OpenAPI

````yaml /swagger.yaml post /projects/{id}/areas/batch
openapi: 3.0.1
info:
  title: Fohlio REST API
  description: This is the documentation for the Fohlio REST API.
  version: 1.0.0
servers:
  - url: /openapi
  - url: https://app.fohlio.com/be/openapi
security: []
paths:
  /projects/{id}/areas/batch:
    parameters:
      - name: id
        in: path
        required: true
        schema:
          type: string
    post:
      tags:
        - Area
      summary: Create areas in bulk
      operationId: areas#bulk_create
      parameters: []
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/requestBodyAreaBulkCreate'
        required: true
      responses:
        '201':
          description: Created
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/areas'
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/error'
        '401':
          description: Unauthorized
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/error'
        '403':
          description: Forbidden
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/error'
        '404':
          description: Not Found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/error'
      security:
        - apiKey: []
components:
  schemas:
    requestBodyAreaBulkCreate:
      type: object
      properties:
        areas:
          type: array
          items:
            type: object
            properties:
              name:
                type: string
              code:
                type: string
              layer_id:
                type: integer
              quantity:
                type: number
              parent_ids:
                type: array
                items:
                  type: integer
            required:
              - name
              - layer_id
      required:
        - areas
    areas:
      type: array
      items:
        $ref: '#/components/schemas/area'
    error:
      type: object
      properties:
        error:
          type: string
    area:
      type: object
      properties:
        id:
          type: integer
        code:
          type: string
          nullable: true
        name:
          type: string
          nullable: true
        position:
          type: integer
        layer_id:
          type: integer
        project_id:
          type: integer
        is_used:
          type: boolean
  securitySchemes:
    apiKey:
      type: apiKey
      name: authorization
      in: header

````