Mule json架构的任意点平台模拟抛出错误

Mule json架构的任意点平台模拟抛出错误,mule,anypoint-studio,Mule,Anypoint Studio,我已经在anypoint平台中创建了一个raml,下面是我的raml文件 #%RAML 0.8 title: es-be-crm-dev version: 001-dev #baseUri: http://localhost:8081/api baseUri: https://mocksvc.mulesoft.com/mocks/44267573-73b2-4369-8e2d- 3a6abbf20e34/api traits: - rate-limited:

我已经在anypoint平台中创建了一个raml,下面是我的raml文件

#%RAML 0.8
title: es-be-crm-dev
version: 001-dev
#baseUri: http://localhost:8081/api     
baseUri: https://mocksvc.mulesoft.com/mocks/44267573-73b2-4369-8e2d-         3a6abbf20e34/api
traits: 
 - rate-limited: 
   queryParameters: 
   client_id: 
    type: string 
   client_secret: 
    type: string   
schemas:
  - api-request-schema: !include schemas/api-request-schema.json


/teams/{teamId}/teamMembers:
post:
  description: Delete Team Member(s) from specified Team

  headers:
    Accept:
      displayName: Accepted response format
      description: Caller accepted response content Type
      type: string
      example: application/json
      required: true
      default: application/json
    Content-Type:
      displayName: body Mime Type
      description: Caller accepted response content Type
      type: string
      example: application/json
      required: true
      default: application/json
  body: 
    application/json:
      schema: api-request-schema
      example: !include examples/api-request-example.json

  responses:
    201:
      description: Returned when the entity has been successfully created
      headers:
        ETag:
          displayName: Entity Tag
          description: Hash of the previously requested resource
          type: string
          example: asd8asd98hlk209u098asdfmoiun4023
          required: false          
    401:
      description: Returned when the user is not authorized to add a member


delete:
  description: Adds Team Member(s) in specified Team

  headers:
    Accept:
      displayName: Accepted response format
      description: Caller accepted response content Type
      type: string
      example: application/json
      required: true
      default: application/json
    Content-Type:
      displayName: body Mime Type
      description: Caller accepted response content Type
      type: string
      example: application/json
      required: true
      default: application/json

  body: 
    application/json:
      schema: api-request-schema
      example: !include examples/api-request-example.json

  responses:
    201:
      description: Returned when the entity has been successfully created
      headers:
        ETag:
          displayName: Entity Tag
          description: Hash of the previously requested resource
          type: string
          example: asd8asd98hlk209u098asdfmoiun4023
          required: false          
    401:
      description: Returned when the user is not authorized to delete a member       
下面是api-request-example.json

{
  "$schema": "http://json-schema.org/draft-04/schema#",
   "type": "object",
   "properties": {
  "teamMembers": {
    "type": "array",
     "items": {
     "type": "object",
    "properties": {
      "teamMember": {
        "type": "object",
        "properties": {
          "empID": {
            "type": "string"
          },
          "sourceSystemId": {
            "type": "string"
          },
          "sourceSystemObjectId": {
            "type": "string"
          }
        },
        "required": [
          "empID",
          "sourceSystemId",
          "sourceSystemObjectId"
        ]
      }
      },
      "required": [
      "teamMember"
    ]
    }
  }
  },
 "required": [
"teamMembers"
 ]
}
下面是示例文件

 {
  "teamMembers": [{
    "teamMember": {
        "empID": "d3193f53-5f07-e611-80e3-a45d36fc4f90",
        "sourceSystemId": "abc",
        "sourceSystemObjectId": "abc"

    }
    }]
}
每当我试图模拟我的api时,它就会抛出一个状态代码为400的错误

{
 "error": "schema did not parse: Unexpected token a"
}

这里有我遗漏的东西吗

有错误消息说mule无法解析您的模式,这可能是因为您使用的ApiKit版本不支持别名。 他就是这么说的,
不能解析一个

使用直接包含更改它

schema: !include api-request-schema.json

我知道这并不理想,但只需要编写多一点。

有错误消息说mule无法解析您的模式,这可能是因为您使用的ApiKit版本不支持别名。 他就是这么说的,
不能解析一个

使用直接包含更改它

schema: !include api-request-schema.json

我知道这并不理想,但还有一点需要编写。

您好,我现在看到了别名,但您使用的是哪个版本的Mule和ApiKit?可能不支持架构别名。我使用的是最新版本。。当我不使用别名btwHi时,它工作正常,我认为可能不受支持。更新了澄清的答案您好,我现在看到了别名,但是您使用的是哪个版本的Mule和ApiKit?可能不支持架构别名。我使用的是最新版本。。当我不使用别名btwHi时,它工作正常,我认为可能不受支持。更新了答案以便澄清