@laplace.live/internal 1.3.2 → 1.3.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -1,9 +1,9 @@
1
1
  # @laplace.live/internal
2
2
 
3
- LAPLACE Live! general types
3
+ LAPLACE Live! internal types and shared utilities
4
4
 
5
5
  To install:
6
6
 
7
7
  ```bash
8
- bun add @laplace.live/internal -D
8
+ bun add @laplace.live/internal
9
9
  ```
package/package.json CHANGED
@@ -1,10 +1,9 @@
1
1
  {
2
2
  "name": "@laplace.live/internal",
3
- "version": "1.3.2",
3
+ "version": "1.3.5",
4
4
  "module": "src/index.d.ts",
5
5
  "exports": {
6
6
  ".": "./src/index.d.ts",
7
- "./steam": "./src/const/steam.d.ts",
8
7
  "./*": "./src/const/*.ts"
9
8
  },
10
9
  "devDependencies": {
@@ -4243,6 +4243,147 @@ export declare namespace BilibiliInternal {
4243
4243
  data: null
4244
4244
  }
4245
4245
 
4246
+ /**
4247
+ * 发送红包
4248
+ *
4249
+ * @link https://api.live.bilibili.com/xlive/lottery-interface/v1/popularityRedPocket/SendRedPocket
4250
+ * @example POST /bilibili/live-send-red-pocket
4251
+ */
4252
+ export type SendRedPocket = SendRedPocketSuccess | SendRedPocketError
4253
+
4254
+ /** Data of `SendRedPocket` when success */
4255
+ export interface SendRedPocketSuccess {
4256
+ code: 0
4257
+ /** @example "0" */
4258
+ message: string
4259
+ ttl: number
4260
+ data: {
4261
+ lot_info: {
4262
+ /** 红包抽奖 ID */
4263
+ lot_id: number
4264
+ /** 发送者 UID */
4265
+ sender_uid: number
4266
+ /** 发送者昵称 */
4267
+ sender_name: string
4268
+ /** 发送者头像 */
4269
+ sender_face: string
4270
+ /** 参与条件,1 为关注 */
4271
+ join_requirement: number
4272
+ /**
4273
+ * 红包弹幕内容
4274
+ *
4275
+ * @example "老板大气!点点红包抽礼物"
4276
+ */
4277
+ danmu: string
4278
+ /** 红包奖品列表 */
4279
+ awards: SendRedPocketAward[]
4280
+ /** 红包开始时间(秒级时间戳) */
4281
+ start_time: number
4282
+ /** 红包结束时间(秒级时间戳) */
4283
+ end_time: number
4284
+ /** 红包持续时间(秒) */
4285
+ last_time: number
4286
+ /** 红包移除时间(秒级时间戳) */
4287
+ remove_time: number
4288
+ /** 红包替换时间(秒级时间戳) */
4289
+ replace_time: number
4290
+ /** 当前服务器时间(秒级时间戳) */
4291
+ current_time: number
4292
+ /** 红包状态,1 为进行中 */
4293
+ lot_status: number
4294
+ /** H5 红包页面 URL */
4295
+ h5_url: string
4296
+ /** 用户参与状态,2 为已发送 */
4297
+ user_status: number
4298
+ /** 红包配置 ID */
4299
+ lot_config_id: number
4300
+ /** 红包总价(金瓜子) */
4301
+ total_price: number
4302
+ wait_num: number
4303
+ is_mystery: boolean
4304
+ sender_info: {
4305
+ uid: number
4306
+ base: {
4307
+ name: string
4308
+ face: string
4309
+ name_color: number
4310
+ is_mystery: boolean
4311
+ risk_ctrl_info: null
4312
+ origin_info: {
4313
+ name: string
4314
+ face: string
4315
+ }
4316
+ official_info: {
4317
+ role: number
4318
+ title: string
4319
+ desc: string
4320
+ type: number
4321
+ }
4322
+ /** @example "#FF7C28" */
4323
+ name_color_str: string
4324
+ }
4325
+ medal: MedalInfo
4326
+ wealth: {
4327
+ level: number
4328
+ /** @example "ChronosWealth_5.png" */
4329
+ dm_icon_key: string
4330
+ }
4331
+ title: null
4332
+ guard: {
4333
+ /**
4334
+ * - `1`: 总督
4335
+ * - `2`: 提督
4336
+ * - `3`: 舰长
4337
+ */
4338
+ level: number
4339
+ /** @example "2026-03-30 23:59:59" */
4340
+ expired_str: string
4341
+ } | null
4342
+ uhead_frame: null
4343
+ guard_leader: null
4344
+ }
4345
+ rp_type: number
4346
+ /** 当前参与人数 */
4347
+ join_cnt: number
4348
+ icon_url: string
4349
+ animation_icon_url: string
4350
+ wait_num_v2: number
4351
+ rp_guard_info: null
4352
+ }
4353
+ tips: string
4354
+ need_gold: number
4355
+ /** 订单号 @example "2603212309547063127631308" */
4356
+ order_id: string
4357
+ tips_v2: string
4358
+ }
4359
+ }
4360
+
4361
+ /** 红包奖品信息 */
4362
+ export interface SendRedPocketAward {
4363
+ /** 礼物 ID */
4364
+ gift_id: number
4365
+ /** 礼物数量 */
4366
+ num: number
4367
+ /** 礼物名称 */
4368
+ gift_name: string
4369
+ /** 礼物图片 URL */
4370
+ gift_pic: string
4371
+ guard_sub_pic: string
4372
+ }
4373
+
4374
+ /** Data of `SendRedPocket` when error */
4375
+ export interface SendRedPocketError {
4376
+ /**
4377
+ * - `1300012`: 余额不足
4378
+ * - `1009115`: 等主播开播时再赠送吧
4379
+ * - `1009700`: 送出红包数量上限
4380
+ */
4381
+ code: number
4382
+ message: string
4383
+ ttl: number
4384
+ data: null
4385
+ }
4386
+
4246
4387
  /**
4247
4388
  * 视频元信息
4248
4389
  * @link https://api.bilibili.com/x/web-interface/view?bvid={bvid}
@@ -885,6 +885,17 @@ export declare namespace LaplaceInternal {
885
885
  lastPeriodStart: string
886
886
  }
887
887
 
888
+ /**
889
+ * Response for DELETE /laplace/fertility-delete/:uid
890
+ * Deletes the entire fertility cycle record and any pending contributions
891
+ */
892
+ export interface FertilityDeleteResponse {
893
+ success: true
894
+ uid: number
895
+ /** Number of pending contributions that were also deleted */
896
+ deletedContributions: number
897
+ }
898
+
888
899
  // ============================================
889
900
  // Fertility Contribution Types (Anonymous Submissions)
890
901
  // ============================================