Mock:Intercept and directly return data

Mock:Intercept and directly return data

拦截请求并直接返回 Mock 数据,包括 XMLHttpRequest、fetch类接口

What is Mock:Intercept and directly return data?
Mock:Intercept and directly return data is a Chrome extension that allows you to intercept and simulate various types of HTTP requests, including XMLHttpRequest and fetch. It helps reduce dependency on live APIs during development and enables clear logic for code development and testing. The extension supports automatic generation of mock data based on Swagger 2.0 documentation, GraphQL requests, and offers various matching patterns for API interception. You can redirect matched requests and set response delay to imitate real API responses. It also supports configuration import/export, dual language (English and Chinese), and grouping of mock configurations.
Merlin
Stats
Users: 832 ▲ 21
Rating: 4.75 (4)
Version: 1.3.2 (Last updated: 2023-11-29)
Creation date: 2023-06-20
Risk impact: Moderate risk impact
Risk likelihood: Moderate risk likelihood
Manifest version: 3
Permissions:
  • storage
  • declarativeNetRequest
Host permissions:
  • http://*/*
  • https://*/*
Size: 483.33K
Stats date:

Other platforms

Not available on Firefox
Not available on Edge
Want to check extension ranking and stats more quickly for other Chrome extensions? Install Chrome-Stats extension to view Chrome-Stats data as you browse the Chrome Web Store.
Chrome-Stats extension
Merlin
Summary

这是一款拦截对应请求并直接返回配置数据的 Mock 工具。它能帮助我们在开发过程中,减少对接口的依赖,尽可能保证我们能及更加清晰的逻辑来开发或者测试代码。

具体以下功能:

  1. 支持拦截和模拟使用 XMLHttpRequest 或 fetch 方法来请求的接口。
  2. 根据 swagger2.0 文档自动生成 Mock 数据。
  3. 支持 GraphQL 请求的 Mock。
  4. 允许对匹配的接口进行 Redirect 操作。
  5. 提供 contains、equals 和 regexp 三种匹配模式,以满足不同的接口匹配需求。
  6. 成功拦截匹配的接口,直接返回对应的 Mock 数据,无需进行实际的网络请求,Mock 时就不用等待接口返回 200 后才能继续进行后面的操作。
  7. 可以设置延迟返回时间,以模拟真实接口的响应。
  8. 支持导入、导出配置数据。
  9. 支持中英文两种语言。根据浏览器语言环境,自动显示对应的语言。
  10. 支持一键重置。
  11. 支持对 Mock 的配置进行 Clone。
  12. 支持 Mock 列表分组。
User reviews
I give 4 because, this extension able to do redirect to another url too.

Великолепно, отлично подменяет Response Body. Если будите развивать расширение, можно было бы сделать включение/выключение всей группы сразу. И думаю, у вас отлично получились бы и другие виды управления запросами. Удачи!
View all user reviews
Safety
Risk impact

Mock:Intercept and directly return data may not be safe to use and it requires some risky permissions. Exercise caution when installing this extension. Review carefully before installing.

Risk likelihood

Mock:Intercept and directly return data is probably trust-worthy. Prefer other publishers if available. Exercise caution when installing this extension.

Upgrade to see risk analysis details
Promo video
Screenshots
Promo images
Mock:Intercept and directly return data small promo image
Small promo image
Similar extensions

Here are some Chrome extensions that are similar to Mock:Intercept and directly return data: