Skip to content

Commit 7d44c6a

Browse files
committed
feat: update baselib defs to 3.6.1
1 parent c8ade82 commit 7d44c6a

File tree

2 files changed

+26
-4
lines changed

2 files changed

+26
-4
lines changed

CHANGELOG.md

+3
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
1+
## 2024-09-24 v3.8.7
2+
- 更新 API 定义到 3.6.1
3+
14
## 2024-09-24 v3.8.6
25
- 更新 API 定义到 3.5.7
36
- 补齐 `wx.getPhoneNumber` 定义

types/wx/lib.wx.api.d.ts

+23-4
Original file line numberDiff line numberDiff line change
@@ -3056,10 +3056,16 @@ GameRecorderShareButton.offTap(listener) // 需传入与监听时同一个的函
30563056
errMsg: string
30573057
}
30583058
interface GetPhoneNumberOption {
3059+
/** 接口调用结束的回调函数(调用成功、失败都会执行) */
3060+
complete?: GetPhoneNumberCompleteCallback
3061+
/** 接口调用失败的回调函数 */
3062+
fail?: GetPhoneNumberFailCallback
30593063
/** 手机号实时验证,向用户申请,并在用户同意后,快速填写和实时验证手机号 [具体说明](https://developers.weixin.qq.com/minigame/dev/guide/open-ability/getRealtimePhoneNumber.html)。 */
30603064
isRealtime?: boolean
30613065
/** 当手机号快速验证或手机号实时验证额度用尽时,是否对用户展示“申请获取你的手机号,但该功能使用次数已达当前小程序上限,暂时无法使用”的提示,默认展示。 */
30623066
phoneNumberNoQuotaToast?: boolean
3067+
/** 接口调用成功的回调函数 */
3068+
success?: GetPhoneNumberSuccessCallback
30633069
}
30643070
interface GetPotentialFriendListOption {
30653071
/** 接口调用结束的回调函数(调用成功、失败都会执行) */
@@ -15034,7 +15040,14 @@ wx.getBluetoothDevices({
1503415040
*
1503515041
* 需要基础库: `2.15.0`
1503615042
*
15037-
* 获取视频号直播信息 */
15043+
* 获取视频号直播信息
15044+
*
15045+
* **常见错误码说明**
15046+
*
15047+
* 100008 视频号需要认证
15048+
* 40097 入参异常
15049+
* 1416104 视频号获取到的数据为空
15050+
* 1416100 非法的视频号id */
1503815051
getChannelsLiveInfo(option: GetChannelsLiveInfoOption): void
1503915052
/** [wx.getChannelsLiveNoticeInfo(Object object)](https://developers.weixin.qq.com/minigame/dev/api/open-api/channels/wx.getChannelsLiveNoticeInfo.html)
1504015053
*
@@ -17382,7 +17395,7 @@ wx.offNetworkWeakChange()
1738217395
* ****
1738317396
*
1738417397
* ## 注意事项
17385-
* - 转发图片说明:仅当自定义分享图片权限被封禁时用 imageUrlId,其他情况都会用 imageUrl。 imageUrl 不填时使用游戏画面截图。 */
17398+
* - 转发图片说明:imageUrl,imageUrlId 都存在时,优先使用 imageUrl。 imageUrl,imageUrlId 都不填时使用游戏画面截图。 */
1738617399
onShareAppMessage(
1738717400
/** 用户点击右上角菜单的「转发」按钮时触发的事件的监听函数 */
1738817401
listener: OnShareAppMessageCallback
@@ -17405,7 +17418,7 @@ wx.offNetworkWeakChange()
1740517418
* ****
1740617419
*
1740717420
* ## 注意事项
17408-
* - 转发图片说明:仅当自定义分享图片权限被封禁时用 imageUrlId,其他情况都会用 imageUrl。 imageUrl 不填时使用当前游戏的icon。 */
17421+
* - 转发图片说明:imageUrl,imageUrlId 都存在时,优先使用 imageUrl。 imageUrl,imageUrlId 都不填时使用当前游戏的icon。 */
1740917422
onShareTimeline(
1741017423
/** 用户点击右上角菜单的「分享到朋友圈」按钮时触发的事件的监听函数 */
1741117424
listener: OnShareTimelineCallback
@@ -18701,7 +18714,7 @@ try {
1870118714
* ****
1870218715
*
1870318716
* ## 注意事项
18704-
* - 转发图片说明:仅当自定义分享图片权限被封禁时用 imageUrlId,其他情况都会用 imageUrl。 imageUrl 不填时使用游戏画面截图。 */
18717+
* - 转发图片说明:imageUrl,imageUrlId 都存在时,优先使用 imageUrl。 imageUrl,imageUrlId 都不填时使用游戏画面截图。 */
1870518718
shareAppMessage(option: ShareAppMessageOption): void
1870618719
/** [wx.shareMessageToFriend(Object object)](https://developers.weixin.qq.com/minigame/dev/api/open-api/data/wx.shareMessageToFriend.html)
1870718720
*
@@ -19759,6 +19772,12 @@ wx.writeBLECharacteristicValue({
1975919772
result: GetNetworkTypeSuccessCallbackResult
1976019773
) => void
1976119774
/** 接口调用结束的回调函数(调用成功、失败都会执行) */
19775+
type GetPhoneNumberCompleteCallback = (res: GeneralCallbackResult) => void
19776+
/** 接口调用失败的回调函数 */
19777+
type GetPhoneNumberFailCallback = (res: GeneralCallbackResult) => void
19778+
/** 接口调用成功的回调函数 */
19779+
type GetPhoneNumberSuccessCallback = (res: GeneralCallbackResult) => void
19780+
/** 接口调用结束的回调函数(调用成功、失败都会执行) */
1976219781
type GetPotentialFriendListCompleteCallback = (
1976319782
res: GeneralCallbackResult
1976419783
) => void

0 commit comments

Comments
 (0)