0

私の.apibドキュメントには、次の応答が定義されています。

 21 + Response 200 (application/json)
 22 
 23     + Body
 24 
 25         {
 26             "Datetime: "2017-04-23T18:25:43.700Z",
 27             "UserId": "1",
 28             "Goal": "25",
 29             "MaxReps": "8",
 30             "Workout":
 31                 [
 32                     {
 33                         "SequenceNo": "1",
 34                         "Action": "Pullups",
 35                         "Units": "3"
 36                     },
 37                     {
 38                         "SequenceNo": "2",
 39                         "Action": "Rest",
 40                         "Units": "60"
 41                     },
 42                     {
 43                         "SequenceNo": "3",
 44                         "Action": "Pullups",
 45                         "Units": "5"
 46                     },
 47                     {
 48                         "SequenceNo": "4",
 49                         "Action": "Rest",
 50                         "Units": "60"
 51                     },
 52                     {
 53                         "SequenceNo": "5",
 54                         "Action": "Pullups",
 55                         "Units": "4"
 56                     }
 57                 ]
 58         }

ただしdredd、次のエラーで実行すると失敗します。

warn: Parser warning in file '/root/pullapi/api-description.apib': (warning code 10) message-body asset is expected to be a pre-formatted cod
e block, every of its line indented by exactly 12 spaces or 3 tabs on lines 25-58

ただし、これはapiblueprint examplesの構造と一致します。

私が間違っていることについて何か考えはありますか?

4

1 に答える 1