Can't send post request with an array as body

I have this schema that gets correctly parsed on Swagger Editor:

openapi: 3.0.0
info:
  title: My API
  description: This API allows users to search for car parts and report missing parts.
  version: 1.0.0
servers:
  - url: https://app.myserver.com
    description: Mechanic Invoice Check REST API
paths:
  /report_missing_car_parts:
    post:
      operationId: reportMissingCarParts
      summary: Report a list of missing car parts in the database.
      description: Report missing car parts of the database, including the model and the make of the car.
      requestBody:
        required: true
        content:
          'application/json':
            schema:
              type: array
              items:
                type: object
                required:
                  - Make
                  - Model
                  - Car_Part
                  - Query
                properties:
                  Make:
                    type: string
                    description: Make of the car.
                  Model:
                    type: string
                    description: Model of the car.
                  Car_Part:
                    type: string
                    description: Specific car part that is missing.
                  Query:
                    type: string
                    description: Additional query or information related to the missing car part.
      responses:
        "201":
          description: The missing car part report was successfully submitted.

But when pasting it as action I get this error:

In path /report_missing_car_parts, method post, operationId reportMissingCarParts, request body schema is not an object schema; skipping
In path /report_missing_car_parts, method post, operationId reportMissingCarParts, skipping function due to errors

Can somebody help?

I was able to fix this this partially. I created a schema that works for OpenAI actions (I had just to wrap the array into a property “car_parts”):

/report_missing_car_parts:
    post:
      operationId: reportMissingCarParts
      summary: Report a list of missing car parts in the database.
      description: Report missing car parts of the database, including the model and the make of the car.
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                car_parts:
                  type: array
                  items:
                    type: object
                    required:
                      - Make
                      - Model
                      - Car_Part
                      - Query
                    properties:
                      Make:
                        type: string
                        description: Make of the car.
                      Model:
                        type: string
                        description: Model of the car.
                      Car_Part:
                        type: string
                        description: Specific car part that is missing.
                      Query:
                        type: string
                        description: Additional query or information related to the missing car part.
      responses:
        "201":
          description: The missing car part report was successfully submitted.

I also updated the code server side. The problem is that now GPT is sending data in the params for some reason, not in the body. This the “[debug ] Calling HTTP endpoint”:

{
  "domain": "app.myapi.com",
  "method": "post",
  "path": "/report_missing_car_parts",
  "operation": "reportMissingCarParts",
  "operation_hash": "d540a6a961115ab1af2385c8bb3404c082ecbc33",
  "is_consequential": true,
  "params": {
    "car_parts": [
      {
        "Make": "Mercedes",
        "Model": "Test",
        "Car_Part": "Brutal 145 Top Refrigerator",
        "Query": "Merceds Test brutal 145 top refrigerator"
      }
    ]
  }
}

I fixed it using the second YAML. Do you want to know the problem? If I changed the YAML without saving and I tested the GPT it would return the error that I showed you, if instead I saved the GPT and then run the same prompt, it would work just fine…