| name | alibabacloud-icpba-sucessdata-query |
| description | Alibaba Cloud ICP Filing Success Data Query Skill. Use for querying ICP filing success information including entity, website, app details and risk alerts after successful filing.
Triggers: "ICP filing query", "beian query", "filing information", "filing risk", "query filing success", "备案查询", "备案信息", "备案风险".
|
Alibaba Cloud ICP Filing Success Data Query
Scenario Description
After successfully completing ICP filing (beian) on Alibaba Cloud, customers need to:
- Login to the filing system to view their filing success information
- Query filing details including entity information, website information, and APP information
- Check if there are any risks associated with their filing that need attention
This skill enables automated querying of ICP filing success data and associated risk information through Alibaba Cloud APIs.
Architecture: Alibaba Cloud Beian Service → QuerySuccessIcpData API → Filing Information (Entity + Websites + APPs + Risks)
Installation
Alibaba Cloud CLI
This skill requires Aliyun CLI version >= 3.3.3.
Pre-check: Aliyun CLI >= 3.3.3 required
Run aliyun version to verify >= 3.3.3. If not installed or version too low,
run curl -fsSL https://aliyuncli.alicdn.com/setup.sh | bash to install/update,
or see references/cli-installation-guide.md for installation instructions.
Pre-check: Aliyun CLI plugin update required
[MUST] run aliyun configure set --auto-plugin-install true to enable automatic plugin installation.
[MUST] run aliyun plugin update to ensure that any existing plugins are always up-to-date.
Python Dependencies
Since the CLI command is not yet available in the current plugin version, this skill uses the Python Common SDK:
pip install -r scripts/requirements.txt
Authentication
Pre-check: Alibaba Cloud Credentials Required
Security Rules:
- NEVER read, echo, or print AK/SK values (e.g.,
echo $ALIBABA_CLOUD_ACCESS_KEY_ID is FORBIDDEN)
- NEVER ask the user to input AK/SK directly in the conversation or command line
- NEVER use
aliyun configure set with literal credential values
- ONLY use
aliyun configure list to check credential status
aliyun configure list
Check the output for a valid profile (AK, STS, or OAuth identity).
If no valid profile exists, STOP here.
- Obtain credentials from Alibaba Cloud Console
- Configure credentials outside of this session (via
aliyun configure in terminal or environment variables in shell profile)
- Return and re-run after
aliyun configure list shows a valid profile
RAM Policy
This skill requires the beian:QuerySuccessIcpData permission. For the complete RAM policy JSON and configuration instructions, see references/ram-policies.md.
[MUST] Permission Failure Handling: When any command or API call fails due to permission errors at any point during execution, follow this process:
- Read
references/ram-policies.md to get the full list of permissions required by this SKILL
- Use
ram-permission-diagnose skill to guide the user through requesting the necessary permissions
- Pause and wait until the user confirms that the required permissions have been granted
Parameter Confirmation
IMPORTANT: Parameter Confirmation — Before executing any command or API call,
ALL user-customizable parameters (e.g., RegionId, instance names, CIDR blocks,
passwords, domain names, resource specifications, etc.) MUST be confirmed with the
user. Do NOT assume or use default values without explicit user approval.
| Parameter Name | Required/Optional | Description | Default Value |
|---|
| Caller | Required | Caller identifier for API request | skill (fixed value) |
| Region | Optional | Alibaba Cloud region | cn-hangzhou |
Core Workflow
At the start of the Core Workflow (before any CLI invocation):
[MUST] Enable AI-Mode — AI-mode is required for Agent Skill execution.
Run the following commands before any CLI invocation:
aliyun configure ai-mode enable
aliyun configure ai-mode set-user-agent --user-agent "AlibabaCloud-Agent-Skills/alibabacloud-icpba-sucessdata-query"
Step 1: Query ICP Filing Success Data
Since the CLI command aliyun companyreg query-success-icp-data is not yet available in the current plugin version, we'll use the Python Common SDK to call the API directly.
Create a Python script to query the filing data:
from alibabacloud_credentials.client import Client as CredentialClient
from alibabacloud_tea_openapi.client import Client as OpenApiClient
from alibabacloud_tea_openapi import models as open_api_models
from alibabacloud_tea_util import models as util_models
import json
def create_client() -> OpenApiClient:
"""
Create an OpenAPI client with credential authentication.
"""
credential = CredentialClient()
config = open_api_models.Config(
credential=credential,
endpoint='companyreg.aliyuncs.com',
region_id='cn-hangzhou',
user_agent='AlibabaCloud-Agent-Skills/alibabacloud-icpba-sucessdata-query'
)
return OpenApiClient(config)
def query_success_icp_data(caller: str = 'skill') -> dict:
"""
Query ICP filing success data including entity, website, app, and risk information.
Args:
caller: Caller identifier (fixed value: 'skill')
Returns:
dict: Filing success data response
"""
client = create_client()
params = open_api_models.Params(
action='QuerySuccessIcpData',
version='2026-04-23',
protocol='HTTPS',
method='POST',
auth_type='AK',
style='RPC',
pathname='/',
req_body_type='formData',
body_type='json'
)
queries = {
: caller
}
request = open_api_models.OpenApiRequest(
query=queries
)
runtime = util_models.RuntimeOptions(
connect_timeout=,
read_timeout=
)
:
response = client.call_api(params, request, runtime)
response.get(, {})
Exception e:
()
():
()
( * )
result = query_success_icp_data(caller=)
(json.dumps(result, indent=, ensure_ascii=))
result.get():
ba_list = result.get(, [])
( + * )
()
idx, ba_data (ba_list, ):
()
()
()
()
()
websites = ba_data.get(, [])
()
site websites:
()
()
apps = ba_data.get(, [])
apps:
()
app apps:
()
()
risks = ba_data.get(, [])
risks:
()
risk risks:
()
detail risk.get(, []):
()
suggest detail.get(, []):
()
:
()
__name__ == :
main()
Save this script as query_icp_filing.py and run:
python3 query_icp_filing.py
Step 2: Analyze Results
The API returns the following information structure:
-
Entity Information (主体信息):
- ICP Number (备案号)
- Entity Name (主体名称)
- Entity Type (主体性质: 企业/个人)
- Responsible Person (负责人)
-
Website Information (网站信息):
- Site Record Number (网站备案号)
- Site Name (网站名称)
- Domain List (域名列表)
- Responsible Person (网站负责人)
-
APP Information (APP信息):
- APP Record Number (APP备案号)
- APP Name (APP名称)
- Domain List (域名列表)
- Responsible Person (APP负责人)
-
Risk Information (风险信息):
- Deadline (处理截止日期)
- Risk Source (风险来源)
- Rectify Suggestions (整改建议)
Example Response Data
Example 1: Filing with Entity, Websites, and Risks
{
"RequestId": "79732597-AB14-1341-9131-D94F48D1AFD7",
"Success": true,
"BaSuccessDataWithRiskList": [
{
"IcpNumber": "粤ICP测50000001号",
"OrganizersName": "深圳市星澜美容有限公司变更",
"OrganizersNature": "企业",
"ResponsiblePersonName": "于婷",
"WebsiteList": [
{
"SiteRecordNum": "粤ICP测50000001号-1",
"DomainList": ["13011160846019.com"],
"SiteName": "于婷广东",
"ResponsiblePersonName": "于婷"
},
{
"SiteRecordNum"
Example 2: Filing with Entity, Websites, and APPs
{
"RequestId": "E36C463A-0869-1318-A851-84C53711984A",
"Success": true,
"BaSuccessDataWithRiskList": [
{
"IcpNumber": "测BA20251231094500051号",
"OrganizersName": "LXtest001变更测试",
"OrganizersNature": "企业",
"ResponsiblePersonName": "李四",
"WebsiteList": [
{
"SiteRecordNum": "测BA20251231094500051号-1",
"DomainList": ["lxtest001.com"],
"SiteName": "测试迁移使用11111111111111111111",
"ResponsiblePersonName": "张三"
},
{
"SiteRecordNum"
[MUST] Disable AI-Mode at EVERY exit point — Before delivering the final response for ANY reason, always disable AI-mode first. This applies to ALL exit paths: workflow success, workflow failure, error/exception, user cancellation, session end, or any other scenario where no further CLI commands will be executed.
AI-mode is only used for Agent Skill invocation scenarios and MUST NOT remain enabled after the skill stops running.
aliyun configure ai-mode disable
Success Verification Method
To verify the query was successful:
- Check the
Success field in the response is true
- Verify
BaSuccessDataWithRiskList contains filing records
- Confirm each record has:
- Valid
IcpNumber
- Entity information (
OrganizersName, OrganizersNature)
- At least one website in
WebsiteList or one app in AppList
For detailed verification steps, see references/verification-method.md.
Cleanup
This is a read-only query operation with no resources to clean up.
Best Practices
- Regular Monitoring: Query filing data regularly to stay informed of any new risks
- Risk Response: When risks are identified, respond before the deadline to avoid filing cancellation
- Data Consistency: Ensure website/APP content matches the filed information to prevent risks
- Permission Management: Use RAM policies to grant minimal required permissions
- Error Handling: Implement proper error handling and retry logic for API calls
- Credential Security: Never hardcode credentials; always use environment variables or credential files
- Response Parsing: Handle both scenarios where AppList or RiskList may be empty arrays
- HTML Content: Be aware that risk suggestions may contain HTML tags for formatting
Reference Links