Skill: cinience/alicloud-database-rds-supabase (version 1.0.1)

--- name: alicloud-database-rds-supabase description: Manage Alibaba Cloud RDS Supabase (RDS AI Service 2025-05-07) via OpenAPI. Use for creating, starting/stopping/restarting instances, resetting passwords, querying endpoints/auth/storage, configuring auth/RAG/SSL/IP whitelist, and listing instance details or conversations. version: 1.0.0 --- Category: service # Alibaba Cloud RDS Supabase (RDS AI Service 2025-05-07) Manage RDS Supabase app instances and related configurations via RDS AI Service OpenAPI, including lifecycle, auth, storage, RAG, IP whitelist, and SSL. ## Prerequisites - Use least-privilege RAM user/role AccessKey and prefer environment variables for AK/SK. - OpenAPI uses RPC signing; prefer official SDKs or OpenAPI Explorer. ## Workflow 1) Confirm resource type: instance / auth / storage / RAG / security configuration. 2) Locate operations in `references/api_overview.md`. 3) Choose invocation method (SDK / OpenAPI Explorer / custom signing). 4) After changes, verify state and configuration with query APIs. ## AccessKey Priority (Required) 1) Environment variables (preferred):`ALICLOUD_ACCESS_KEY_ID` / `ALICLOUD_ACCESS_KEY_SECRET` / `ALICLOUD_REGION_ID` Region policy: `ALICLOUD_REGION_ID` is optional default; if unset choose the most reasonable region and ask when unclear. 2) Standard credentials file:`~/.alibabacloud/credentials` ## Default Region Strategy - If region is not specified, choose the most reasonable region; ask the user when unclear. - Only run all-region queries when explicitly needed or user-approved (call `ListRegions` first, then query each region). - If user provides region, query only that region. ## Common Operation Map - Instance:`CreateAppInstance` / `DeleteAppInstance` / `StartInstance` / `StopInstance` / `RestartInstance` - Connectivity and auth:`DescribeInstanceEndpoints` / `DescribeInstanceAuthInfo` / `ModifyInstanceAuthConfig` - Storage:`DescribeInstanceStorageConfig` / `ModifyInstanceStorageConfig` - Security:`ModifyInstanceIpWhitelist` / `DescribeInstanceIpWhitelist` / `ModifyInstanceSSL` / `DescribeInstanceSSL` - RAG：`ModifyInstanceRAGConfig` / `DescribeInstanceRAGConfig` ## Clarifying questions (ask when uncertain) 1. What is the target instance ID and region? 2. Is this instance lifecycle management or configuration changes (auth/storage/RAG/IP whitelist/SSL)? 3. Do you need batch operations or an initial state query first? ## Output Policy If you need to save results or responses, write to: `output/database-rds-supabase/` ## Validation ```bash mkdir -p output/alicloud-database-rds-supabase echo "validation_placeholder" > output/alicloud-database-rds-supabase/validate.txt ``` Pass criteria: command exits 0 and `output/alicloud-database-rds-supabase/validate.txt` is generated. ## Output And Evidence - Save artifacts, command outputs, and API response summaries under [REDACTED_SECRET]. - Include key parameters (region/resource id/time range) in evidence files for reproducibility. ## Prerequisites - Configure least-privilege Alibaba Cloud credentials before execution. - Prefer environment variables: `ALICLOUD_ACCESS_KEY_ID`, `ALICLOUD_ACCESS_KEY_SECRET`, optional `ALICLOUD_REGION_ID`. - If region is unclear, ask the user before running mutating operations. ## Workflow 1) Confirm user intent, region, identifiers, and whether the operation is read-only or mutating. 2) Run one minimal read-only query first to verify connectivity and permissions. 3) Execute the target operation with explicit parameters and bounded scope. 4) Verify results and save output/evidence files. ## References - API overview and operation groups:`references/api_overview.md` - Core API parameter quick reference:`references/api_reference.md` - All-region query examples:`references/query-examples.md` - Official source list:`references/sources.md`

path: agents/openai.yaml
content: interface:
  display_name: "Alibaba Cloud Database RDS Supabase"
  short_description: "RDS instance and database workflows"
  default_prompt: "Use $alicloud-database-rds-supabase to complete this database/rds task on Alibaba Cloud."


path: references/api_overview.md
content: API 概览（RDS AI 服务 2025-05-07）
=================================

来源：阿里云文档「API概览」。用于快速定位接口分组与操作名，参数以原文档为准。文档链接见 `sources.md`。

目录
----
- RDS AI 助手
- 实例（RDS Supabase）
- RAG Agent
- 安全

RDS AI 助手
----------
- ChatMessages: 发送对话消息
- ModifyMessagesFeedbacks: 修改消息反馈
- ChatMessagesTaskStop: 停止对话
- GetConversations: 查看历史对话
- GetMessages: 查看对话消息
- DescribeEventsList: 查询事件列表
- ListCustomAgentTools: 查询用户 Agent 工具列表
- UpdateCustomAgent: 更新用户 Agent
- GetCustomAgent: 查询专属 Agent
- ListCustomAgent: 查询专属 Agent 列表
- DeleteCustomAgent: 删除用户 Agent
- CreateCustomAgent: 创建用户专属 Agent

实例（RDS Supabase）
-------------------
- CreateAppInstance: 创建 RDS AI 应用实例
- DeleteAppInstance: 删除 RDS AI 应用实例
- RestartInstance: 重启实例
- StopInstance: 暂停实例
- StartInstance: 启动实例
- ResetInstancePassword: 重置实例登录/数据库密码
- DescribeAppInstanceAttribute: 查询实例详情
- DescribeAppInstances: 查询实例列表
- DescribeInstanceEndpoints: 查询连接地址
- DescribeInstanceAuthInfo: 查询认证信息
- ModifyInstanceAuthConfig: 修改认证配置
- DescribeInstanceStorageConfig: 查看存储配置
- ModifyInstanceStorageConfig: 修改存储配置
- ModifyInstanceConfig: 修改实例通用配置（EIP/NAT 等）

RAG Agent
---------
- ModifyInstanceRAGConfig: 修改 RAG Agent 配置
- DescribeInstanceRAGConfig: 查看 RAG Agent 配置

安全
----
- ModifyInstanceIpWhitelist: 修改 IP 白名单
- DescribeInstanceIpWhitelist: 查看 IP 白名单
- ModifyInstanceSSL: 修改 SSL 配置
- ModifyInstancesSSL: 批量修改 SSL 配置
- DescribeInstanceSSL: 查看 SSL 配置


path: references/api_reference.md
content: 核心接口参数速查
================

说明：以下为常用接口的高频参数摘要，完整参数与约束以官方文档为准（见 `sources.md`）。

CreateAppInstance（创建实例）
---------------------------
常见参数：
- RegionId
- AppType（目前为 `supabase`）
- VSwitchId
- InstanceClass（当前仅 `rdsai.supabase.basic`）
- DBInstanceName（RDS PostgreSQL 实例 ID）
- AppName
- ClientToken（幂等）
- DatabasePassword / DashboardUsername / DashboardPassword
- PublicNetworkAccessEnabled
- PublicEndpointEnabled
- InitializeWithExistingData
- DBInstanceConfig（含 DBInstanceClass / DBInstanceStorage / PayType）

StartInstance / StopInstance / RestartInstance（生命周期）
-------------------------------------------------------
常见参数：
- RegionId
- InstanceName（实例 ID）

ModifyInstanceAuthConfig（认证配置）
-----------------------------------
常见参数：
- RegionId
- InstanceName
- ConfigList（认证配置列表）
  - Name（如 GOTRUE_* 配置项）
  - Value

ModifyInstanceStorageConfig（存储配置）
--------------------------------------
常见参数：
- RegionId
- InstanceName
- ConfigList（存储配置列表）
  - Name（如 AWS_ACCESS_KEY_ID / AWS_SECRET_ACCESS_KEY / GLOBAL_S3_BUCKET / GLOBAL_S3_ENDPOINT / REGION / TENANT_ID 等）
  - Value
- ClientToken

ModifyInstanceIpWhitelist（白名单）
----------------------------------
常见参数：
- RegionId
- InstanceName
- IpWhitelist（逗号分隔，支持 IP 或 CIDR）
- ModifyMode（Cover / Append / Delete）
- GroupName
- ClientToken

ModifyInstanceSSL（SSL）
-----------------------
常见参数：
- RegionId
- InstanceName
- SSLEnabled（1 开 / 0 关）
- CAType（目前为 custom）
- ServerCert / ServerKey（自定义证书内容）

DescribeAppInstances（实例列表）
-------------------------------
常见参数：
- RegionId
- DBInstanceName（按 PG 实例过滤）
- AppType（supabase）
- PageSize / PageNumber

DescribeAppInstanceAttribute（实例详情）
---------------------------------------
常见参数：
- RegionId
- InstanceName

DescribeInstanceEndpoints（连接地址）
------------------------------------
常见参数：
- RegionId
- InstanceName

ResetInstancePassword（重置密码）
--------------------------------
常见参数：
- RegionId
- InstanceName
- DashboardPassword
- DatabasePassword

DescribeInstanceAuthInfo（认证信息）
-----------------------------------
常见参数：
- RegionId
- InstanceName

DescribeInstanceStorageConfig（存储配置查询）
--------------------------------------------
常见参数：
- RegionId
- InstanceName

DescribeInstanceIpWhitelist（白名单查询）
----------------------------------------
常见参数：
- RegionId
- InstanceName
- GroupName

DescribeInstanceSSL（SSL 查询）
------------------------------
常见参数：
- RegionId
- InstanceName

ModifyInstanceRAGConfig / DescribeInstanceRAGConfig（RAG）
---------------------------------------------------------
常见参数：
- RegionId
- InstanceName
- Status（开启/关闭）
- ConfigList（Name/Value）

RDS AI 助手（对话/事件/Agent）
------------------------------
ChatMessages（发送对话）
- Query
- ConversationId / ParentMessageId
- RegionId / Language / Timezone
- CustomAgentId
- EventMode

ChatMessagesTaskStop（停止对话）
- TaskId

GetConversations（历史对话）
- LastId
- Limit
- Pinned
- SortBy

GetMessages（对话消息）
- ConversationId
- FirstId
- Limit

ModifyMessagesFeedbacks（消息反馈）
- MessageId
- Rating（like/dislike）
- Content

DescribeEventsList（事件列表）
- RegionId
- InstanceIdList
- StartTime / EndTime
- PageSize / PageNumber

ListCustomAgentTools（Agent 工具列表）
- 无入参

CreateCustomAgent（创建 Agent）
- Name
- SystemPrompt
- EnableTools
- Tools

UpdateCustomAgent（更新 Agent）
- CustomAgentId
- Name / SystemPrompt
- EnableTools
- Tools

GetCustomAgent（查询 Agent）
- CustomAgentId

ListCustomAgent（Agent 列表）
- PageNumber / PageSize

DeleteCustomAgent（删除 Agent）
- CustomAgentId


path: references/query-examples.md
content: 全地域查询示例（实例列表）
==========================

目标：在未指定 Region 的情况下，选择最合理的 Region；若无法判断，可询问用户或执行全地域查询。

前置假设
--------
- 优先使用环境变量获取 AK/SK（`ALICLOUD_ACCESS_KEY_ID` / `ALICLOUD_ACCESS_KEY_SECRET`）。
- 如果 `ALICLOUD_REGION_ID` 未设置，优先选择最合理 Region；无法判断时可询问用户，或在合适场景下执行全地域查询。

策略建议
--------
1) 优先尝试在 RdsAi API 中查找地域列表接口（若后续文档补充）。  
2) 若无地域列表接口，则使用阿里云公开地域列表或由用户提供地域清单。  
3) 对每个地域调用 `DescribeAppInstances`，合并结果。  

伪代码
------

```
regions = resolve_regions()
all_instances = []
for region in regions:
  resp = DescribeAppInstances(RegionId=region, AppType="supabase")
  all_instances.extend(resp.Instances)
return all_instances
```

常见输出字段
-----------
- InstanceName
- Status
- AppName
- PublicConnectionString / VpcConnectionString


path: references/sources.md
content: 官方文档来源（用于后续更新）
============================

- https://api.aliyun.com/document/RdsAi/2025-05-07/overview
- https://www.alibabacloud.com/help/zh/rds/apsaradb-rds-for-postgresql/api-rdsai-2025-05-07-overview-postgresql
- https://www.alibabacloud.com/help/zh/rds/apsaradb-rds-for-postgresql/api-rdsai-2025-05-07-dir-postgresql/
- https://www.alibabacloud.com/help/zh/rds/apsaradb-rds-for-postgresql/supabase/
- https://www.alibabacloud.com/help/zh/rds/apsaradb-rds-for-postgresql/api-rdsai-2025-05-07-createappinstance-postgresql
- https://www.alibabacloud.com/help/zh/rds/apsaradb-rds-for-postgresql/api-rdsai-2025-05-07-startinstance-postgresql
- https://www.alibabacloud.com/help/zh/rds/apsaradb-rds-for-postgresql/api-rdsai-2025-05-07-stopinstance-postgresql
- https://www.alibabacloud.com/help/zh/rds/apsaradb-rds-for-postgresql/api-rdsai-2025-05-07-restartinstance-postgresql
- https://www.alibabacloud.com/help/zh/rds/apsaradb-rds-for-postgresql/api-rdsai-2025-05-07-modifyinstanceauthconfig-postgresql
- https://www.alibabacloud.com/help/zh/rds/apsaradb-rds-for-postgresql/api-rdsai-2025-05-07-modifyinstancestorageconfig-postgresql
- https://www.alibabacloud.com/help/zh/rds/apsaradb-rds-for-postgresql/api-rdsai-2025-05-07-modifyinstanceipwhitelist-postgresql
- https://www.alibabacloud.com/help/zh/rds/apsaradb-rds-for-postgresql/api-rdsai-2025-05-07-modifyinstancessl-postgresql
- https://www.alibabacloud.com/help/zh/rds/apsaradb-rds-for-postgresql/api-rdsai-2025-05-07-describeappinstances-postgresql
- https://www.alibabacloud.com/help/zh/rds/apsaradb-rds-for-postgresql/api-rdsai-2025-05-07-describeappinstanceattribute-postgresql
- https://www.alibabacloud.com/help/zh/rds/apsaradb-rds-for-postgresql/api-rdsai-2025-05-07-describeinstanceendpoints-postgresql
- https://www.alibabacloud.com/help/zh/rds/apsaradb-rds-for-postgresql/api-rdsai-2025-05-07-resetinstancepassword-postgresql
- https://www.alibabacloud.com/help/zh/rds/apsaradb-rds-for-postgresql/api-rdsai-2025-05-07-describeinstanceauthinfo-postgresql
- https://www.alibabacloud.com/help/zh/rds/apsaradb-rds-for-postgresql/api-rdsai-2025-05-07-describeinstancestorageconfig-postgresql
- https://www.alibabacloud.com/help/zh/rds/apsaradb-rds-for-postgresql/api-rdsai-2025-05-07-describeinstanceipwhitelist-postgresql
- https://www.alibabacloud.com/help/zh/rds/apsaradb-rds-for-postgresql/api-rdsai-2025-05-07-describeinstancessl-postgresql
- https://www.alibabacloud.com/help/zh/rds/apsaradb-rds-for-postgresql/api-rdsai-2025-05-07-modifyinstanceragconfig-postgresql
- https://www.alibabacloud.com/help/zh/rds/apsaradb-rds-for-postgresql/api-rdsai-2025-05-07-describeinstanceragconfig-postgresql
- https://www.alibabacloud.com/help/zh/rds/apsaradb-rds-for-postgresql/api-rdsai-2025-05-07-chatmessages-postgresql
- https://www.alibabacloud.com/help/zh/rds/apsaradb-rds-for-postgresql/api-rdsai-2025-05-07-chatmessagestaskstop-postgresql
- https://www.alibabacloud.com/help/zh/rds/apsaradb-rds-for-postgresql/api-rdsai-2025-05-07-getconversations-postgresql
- https://www.alibabacloud.com/help/zh/rds/apsaradb-rds-for-postgresql/api-rdsai-2025-05-07-getmessages-postgresql
- https://www.alibabacloud.com/help/zh/rds/apsaradb-rds-for-postgresql/api-rdsai-2025-05-07-modifymessagesfeedbacks-postgresql
- https://www.alibabacloud.com/help/zh/rds/apsaradb-rds-for-postgresql/api-rdsai-2025-05-07-describeeventslist-postgresql
- https://www.alibabacloud.com/help/zh/rds/apsaradb-rds-for-postgresql/api-rdsai-2025-05-07-listcustomagenttools-postgresql
- https://www.alibabacloud.com/help/zh/rds/apsaradb-rds-for-postgresql/api-rdsai-2025-05-07-createcustomagent-postgresql
- https://www.alibabacloud.com/help/zh/rds/apsaradb-rds-for-postgresql/api-rdsai-2025-05-07-updatecustomagent-postgresql
- https://www.alibabacloud.com/help/zh/rds/apsaradb-rds-for-postgresql/api-rdsai-2025-05-07-getcustomagent-postgresql
- https://www.alibabacloud.com/help/zh/rds/apsaradb-rds-for-postgresql/api-rdsai-2025-05-07-listcustomagent-postgresql
- https://www.alibabacloud.com/help/zh/rds/apsaradb-rds-for-postgresql/api-rdsai-2025-05-07-deletecustomagent-postgresql


Security scan verdicts — ClawScan: clean | static analysis: clean | VirusTotal: clean | SkillSpector: suspicious (MEDIUM)