微信域名拦截检测API

实时检测域名是否被微信拦截,适用于各种依赖于微信生态圈的互联网产品,降低服务中断时间,有效提升转化效果!

Go技术栈
调用次数超5000万次
10台服务器
120ms响应
微服务架构
限免APPKEY
免费 / 3小时 / 试用

付费购买CDKEY

节点服务器状态

联系与反馈

若遇到问题或其他建议等,请邮件联系wuxingsanren2008#gmail.com[#改为@]进行反馈!

API文档

API接口说明

名称 说明
接口地址 https://api.example.com/v2/wechat_url_check
返回格式 JSON
请求方式 GET
请求示例 https://api.example.com/v2/wechat_url_check?app_key=您的App key&url=www.qq.com
接口备注 如果您处于登录状态,请求示例中的App Key即是您真实的App Key,不需要再去我的APPKEY查询

请求参数说明

名称 必填 类型 说明
app_key string 用户的App Key,在我的APPKEY可查询到,用于API调用
url string 需要检测的url或域名,例:https://www.qq.com/ 或 www.qq.com

返回参数说明

名称 类型 说明
code integer 状态码,0表示正常,非0表示错误
msg string 提示信息
data.status string 域名状态,取值:ok(正常)、blocked(被封)
data.err_code integer 域名被封的原因,0(正常)、30001(页面被转码)、30002(已停止访问该网页)、30998(如需浏览,请长按网址复制后使用浏览器访问)、30999(其他未知错误)
data.err_msg string 错误说明
data.sub_err_msg string 详细的错误说明

JSON返回示例

//请求频率过快
{
    "code": 10001,
    "msg": "接口调用频率过快",
    "data": []
}

//服务端处理请求出现异常
{
    "code": 10004,
    "msg": "系统内部错误,请重试",
    "data": []
}

//请求成功且域名正常
{
    "code": 0,
    "msg": "OK",
    "data": {
        "status": "ok",
        "err_code": 0,
        "err_msg": "",
        "sub_err_msg": ""
    }
}

//请求成功但域名被封
//被封原因:已停止访问该网页 - 网页包含侵权内容
{
    "code": 0,
    "msg": "OK",
    "data": {
        "status": "blocked",
        "err_code": 30002,
        "err_msg": "已停止访问该网页",
        "sub_err_msg": "网页包含侵权内容"
    }
}

//请求成功但域名被封
//被封原因:页面被转码 - 非微信官方网页
{
    "code": 0,
    "msg": "OK",
    "data": {
        "status": "blocked",
        "err_code": 30001,
        "err_msg": "页面被转码",
        "sub_err_msg": "非微信官方网页"
    }
}

//请求成功但域名被封,需要长按网址复制后使用浏览器访问
{
    "code": 0,
    "msg": "OK",
    "data": {
        "status": "blocked",
        "err_code": 30998,
        "err_msg": "如需浏览,请长按网址复制后使用浏览器访问",
        "sub_err_msg": ""
    }
}

错误码参照

错误码 说明
10001 接口调用频率过快
10003 参数有误
10004 系统内部错误
20001 App Key无效
20002 未购买服务或服务已过期
20006 url参数的值有误

示例代码

Python

# -*- coding: utf-8 -*-

import json, urllib
from urllib import urlencode

def main():
# 您的App Key,在我的APPKEY可查询到
appKey = "*********************"

url = "https://api.example.com/v2/wechat_url_check"
params = {
"url" : "www.qq.com", #需要检测的地址或域名
"app_key" : appKey,

}
params = urlencode(params)
f = urllib.urlopen("%s?%s" % (url, params))

content = f.read()
res = json.loads(content)
if res:
code = res["code"]
if code == 0:
#成功请求
print res["result"]
else:
print "%s: %s" % (res["code"],res["msg"])
else:
print "request api error"

if __name__ == '__main__':
main()

PHP

<?php
/**
* @author 野猫
* @copyright 2024
* @see https://yemao.in/open/weixin_jiance
*/
try {
    //您的App Key,在我的APPKEY可查询到
    $appKey = "********************************";
    //需要检测的地址或域名
    $reqUrl = "www.qq.com";
    $url = sprintf("https://api.example.com/v2/wechat_url_check?app_key=%s&url=%s", $appKey, $reqUrl);
    $ch = curl_init($url);
    curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
    curl_setopt($ch, CURLOPT_BINARYTRANSFER, true);
    //禁止cURL验证对等证书(peer's certificate),不建议生产环境这么配置
    //如果出现证书问题,建议在https://curl.haxx.se/docs/caextract.html下载最新证书
    //并打开php.ini添加:curl.cainfo=/path/to/cacert.pem
    curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false);
    $responseBody = curl_exec($ch);
    if ($responseBody === false) {
        printf("Curl error: %s\n", curl_error($ch));
        return;
    }
    $responseArr = json_decode($responseBody, true);
    if (json_last_error() != JSON_ERROR_NONE) {
        printf("JSON解析接口结果出错:%s\n", json_last_error_msg());
        return;
    }
    if (isset($responseArr['code']) && $responseArr['code'] == 0) {
        //接口正确返回
        //$responseArr['data']['status'] 的取值范围:ok、blocked
        //ok:表示正常;blocked:表示被封
        printf("测试地址(%s)的状态为:%s\n", $reqUrl, $responseArr['data']['status']);
    } else {
        printf("接口异常:%s\n", var_export($responseArr, true));
    }
} catch(Exception $e) {
    printf("出现异常:%s\n", $e->getMessage());
}

常见问题

实时检测域名是否被微信屏蔽,降低您的产品服务中断时间,并检测出各种屏蔽情况,让您第一时间获取服务状态。

微信域名拦截检测系统不限制用户的调用次数、支持多域名查询、提供API接口,用户可以很方便的集成到自己的系统或应用上。

限制用户最多检测域名数:500个。

续费时间是按照1秒1次的时长算的,最终是折算成当前套餐的时长。比如续费30天,接口频率限制为1秒1次,则续费时长折算为30天。

累积消费满500元以上的用户可以申请开《增值税电子普通发票》,请联系客服并提供贵公司的发票抬头。

我的App Key

登录后再查看哦!

充值续费

 
 

查询CDKEY

 
 
SOC2TypeII认证
系统与组织控制(Ⅱ类)
HIPAA合规性
健康保险携带和责任法案
GDPR认证
欧盟通用数据保护条例
PCIDSS认证
支付卡行业数据安全标准