通过 AWS API Gateway 的无服务器框架设置响应模型

Tho*_* W. 6 aws-api-gateway serverless-framework

我正在尝试通过无服务器框架设置我的 AWS API 网关。到目前为止,效果很好,但我正在努力将方法响应设置为模型。我让它适用于请求,但不适用于响应,并且我没有在文档中找到提示。

      ...
      request:
        passThrough: NEVER
        schema:
          application/json: ${file(requestModel.json)}
        template:
          application/json: ${file(requestMapping.template)}
      response:
        headers:
          Content-Type: "'application/json'"
        template: $input.body
      ...
Run Code Online (Sandbox Code Playgroud)

如果我在响应中包含架构,它将被忽略......