{"relatedInterfaces":[{"path":"/assets/interface-documents","description":"商家资产原始字节上传／私有下载、版本前提与实际容量限制；管理操作从assets模块发现。"},{"path":"/payments/interface-documents","description":"提供方签名支付回调；持久接收不代表付款，不能用API Key代替签名。"},{"path":"/payments/mock/interface-documents","description":"显式模拟提供方动作，以原动作秘密完成或拒绝测试付款，不是真实资金。"},{"interfaceId":"catalog-public","graphqlPath":"/catalog/graphql","acceptedProofs":["anonymous"],"path":"/catalog/interface-documents","description":"匿名浏览店铺已发布商品SKU；不需要账户或Key，不扩大私有资源权限。"},{"interfaceId":"storefront","graphqlPath":"/storefront/graphql","acceptedProofs":["account-api-key","account-session"],"path":"/storefront/interface-documents","description":"顾客本人订单／购物／售后；账户Key或账户Cookie进入此面，先按该入口selfAccess观察storefrontCaller，不使用员工selfAccess。"},{"path":"/auth/interface-documents","description":"密码登录、本人会话与恢复。"},{"path":"/auth/providers/interface-documents","description":"已安装Provider发现；未配置Provider不开放登录。"},{"interfaceId":"account","graphqlPath":"/auth/account/graphql","acceptedProofs":["account-session"],"path":"/auth/account/interface-documents","description":"全局本人账户与集团发现；不需要选择集团。"}],"interfaceId":"commerce","acceptedProofs":["employee-api-key","employee-session"],"graphqlPath":"/graphql","interfaceDocumentsPath":"/interface-documents","detailsPath":"/interface-documents?detail=full","discoveryQuery":"query { contractInfo { interfaceId fingerprint catalogFingerprint } modules { id name description operationCount resourceTypes } capabilities(first:5) { items { id name module interfaceId coordinate } totalCount nextCursor } }","discoveryRequests":{"overview":{"purpose":"确认实例与模块；然后只加载任务相关能力。","query":"query { contractInfo { interfaceId fingerprint catalogFingerprint } modules { id name description operationCount resourceTypes } capabilities(first:5) { items { id name module interfaceId coordinate } totalCount nextCursor } }","exampleVariables":{},"access":"public-contract"},"operation":{"purpose":"一个操作的执行契约：真实签名、权限与调用坐标、输入条件、副作用、失败恢复和具名变量例。关联操作只提供稳定ID与关系；需要其配方时再用operation读取该ID，或按需请求operationFull。示例版本必须替换为当前观察，历史成功不代表当前状态。","query":"query Operation($id:String!){capability(id:$id){id name module interfaceId coordinate description signature{arguments{name description typeExpression namedType defaultValue} result{typeExpression namedType}} authorization{kind permissionIds scope conditions} invocations{actionKind action actionInput resourceKind resourceInput resourceType resourceIdSource when} inputNotes{kind field source rule} sideEffects recovery failureRecovery{kind code action} examples{id title description query variablesJson} relatedOperations{operationId relation description}}}","exampleVariables":{"id":"api-access.caller.get"},"access":"public-contract"},"selfAccess":{"purpose":"员工证明的首个观察：当前调用者、期限及允许动作／资源集合。null上限不是全部权限，集合不是计次额度；实际资格与当前RBAC取交集。先据此定位任务，再按需使用roleAccess或已有目标授权解释；不先查询可能无权读取的会话／授予。","query":"query{currentCaller{subjectId tenantId source{kind} credentialLimits{expiresAt defaultSessionId activationLimits permissionLimits{permissionId scope{kind companyId departmentId storeId warehouseId}} callLimits{action resource{kind type id}}}}}","exampleVariables":{},"access":"authenticated-business"},"roleAccess":{"purpose":"按需观察员工会话与授予；先用selfAccess读当前凭据上限，只有任务需要且Key允许这些读取时才调用。FORBIDDEN只拒绝对应观察，不证明任务失败，不为自查扩权。activation为同一策略下有效激活授予，按nextCursor/after续读；eligibleRoleAssignments沿nextAfterId及policyVersion续读。各根是独立观察，策略版本变化重读；具体目标沿authorization.access.explain契约用explainAccess判断，不把授予记录当未来许可。角色、授予、会话的version仅对应该资源，不能代替policyVersion；按目标读取结果形成并发前提。 policyVersion观察角色、权限、继承及授予策略；会话生命周期不递增它。不同查询的观察版本不一致须重读，不构成原子快照。 策略收据的policyVersion是原提交时的历史策略观察，不保证当前策略或资源状态；按action与目标核验后重读现状。","query":"query RoleAccess($first:Int=20) {\n    currentRoleSession(first:$first) { ok code policyVersion session { id status version activatedAssignmentIds } activation { assignments { id roleId status version scope { kind companyId departmentId storeId warehouseId } } nextCursor } }\n    eligibleRoleAssignments(first:$first) { ok code policyVersion assignments { id roleId status version scope { kind companyId departmentId storeId warehouseId } } nextAfterId }\n  }","exampleVariables":{"first":20},"access":"authenticated-business"}},"description":"先查看relatedInterfaces和当前入口的acceptedProofs，按身份与任务选择员工管理、顾客本人或匿名目录；账户Key不能用于员工面，拒绝不自动降级。selfAccess先读调用者，上限不等于实际资格；角色观察按需。operation读取单操作契约及关联ID，operationFull／搜索／类型沿detailsPath按需获取。导航不认证、不授权或证明就绪。"}