[Solved] Yapi Secondary deploy error: xxx validation failed: mock: Path `xxx` is required

Previously on

Although the mongodb server declares that this field can be stored
and the front-end page also carries the parameter
when sending a request like the node service, it cannot be stored in the database and an error is reported

Error prompt

When the server reports an error

adv_source_mock validation failed: mock: Path `mock` is required.
数据表名称                                                 字段

Cause of error

I personally understand that the “mock” field is not declared in the node service
so the node service will not store the path without this field in the database and report an error
or he doesn’t know where it exists

Solution:

You can solve this problem by declaring line 92 of this field in data

Read More: