@bi-nova/services 1.5.2 → 1.6.0-beta.202608131817

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/dist/index.d.mts CHANGED
@@ -463,6 +463,17 @@ declare function handleDyJsapiPayFlow(params: HandleDyJsapiPayFlowParams): Promi
463
463
  */
464
464
  declare function handleDyAuthDebitSignFlow(): Promise<BuildResultReturn<HandleDyAuthDebitSignFlowResult>>;
465
465
 
466
+ /**
467
+ * 处理抖音授权代扣签约原始 payInfo 透传测试流程
468
+ *
469
+ * 流程与 handleDyAuthDebitSignFlow 保持一致,仅跳过 payInfo 字段校验和重组,
470
+ * 将接口返回的全部 payInfo 内容传给 dypay 的 sdk_info。
471
+ *
472
+ * @experimental 测试验证通过后可整体移除
473
+ * @returns 标准化授权跳转或签约调起结果
474
+ */
475
+ declare function handleDyAuthDebitSignFlowWithRawPayInfoForTest(): Promise<BuildResultReturn<HandleDyAuthDebitSignFlowResult>>;
476
+
466
477
  /**
467
478
  * @Description: 业务错误码定义
468
479
  * @Author: wutao
@@ -621,7 +632,7 @@ declare const DyErrorMessage: Record<number, string>;
621
632
  * @Author: wutao
622
633
  * @Date: 2026-04-21
623
634
  * @LastEditors: wutao
624
- * @LastEditTime: 2026-04-27
635
+ * @LastEditTime: 2026-08-13 15:02:40
625
636
  */
626
637
  /**
627
638
  * 展示广告类型
@@ -652,17 +663,31 @@ interface DisplayAdActionConfig {
652
663
  * 自定义广告内容配置
653
664
  */
654
665
  interface DisplayCustomAdConfig {
666
+ /** 后端广告配置 ID */
667
+ configId?: number | string;
668
+ /** 广告位 ID */
669
+ placementId?: string;
670
+ /** 广告配置名称 */
671
+ configName?: string;
672
+ /** 原始广告平台编码 */
673
+ advertPlatform?: AdvertPlatform;
674
+ /** 自研素材类型 */
675
+ mediaType?: 'image' | 'video';
655
676
  /** 图片地址 */
656
677
  image?: string;
657
678
  /** 视频地址 */
658
679
  video?: string;
659
680
  /** 视频封面地址 */
660
681
  poster?: string;
661
- /** 广告标题 */
662
- title?: string;
663
- /** 广告描述 */
682
+ /** 开屏底部整图素材地址 */
683
+ bottomImage?: string;
684
+ /** 兼容字段:广告主名称,开屏组件不再消费 */
685
+ advertiserName?: string;
686
+ /** 兼容字段:广告主 Logo,开屏组件不再消费 */
687
+ advertiserLogo?: string;
688
+ /** 兼容字段:广告描述,开屏组件不再消费 */
664
689
  description?: string;
665
- /** 按钮文案 */
690
+ /** 兼容字段:按钮文案,开屏组件不再消费 */
666
691
  buttonText?: string;
667
692
  /** 角标文案 */
668
693
  badgeText?: string;
@@ -674,6 +699,10 @@ interface DisplayCustomAdConfig {
674
699
  muted?: boolean;
675
700
  /** 广告规格 */
676
701
  adSpec?: number;
702
+ /** 素材填充模式 */
703
+ fitMode?: 'contain' | 'cover';
704
+ /** 跳转类型 */
705
+ jumpType?: 'miniProgram' | 'internal' | 'web' | 'none';
677
706
  /** 点击动作配置 */
678
707
  action?: DisplayAdActionConfig;
679
708
  /** 兼容字段:跳转小程序的 appId */
@@ -701,6 +730,34 @@ interface AdvertPlatformConfig {
701
730
  adId?: string;
702
731
  /** 平台应用 ID */
703
732
  appId?: string;
733
+ /** 自研素材类型 */
734
+ mediaType?: 'image' | 'video';
735
+ /** 自研图片素材地址,Banner 直接使用该字段 */
736
+ image?: string | null;
737
+ /** 自研视频素材地址 */
738
+ video?: string | null;
739
+ /** 视频封面地址 */
740
+ poster?: string | null;
741
+ /** 广告主名称 */
742
+ advertiserName?: string | null;
743
+ /** 广告主 Logo */
744
+ advertiserLogo?: string | null;
745
+ /** 广告描述 */
746
+ description?: string | null;
747
+ /** 按钮文案 */
748
+ buttonText?: string | null;
749
+ /** 广告标识文案 */
750
+ badgeText?: string | null;
751
+ /** 自研广告跳转类型 */
752
+ jumpType?: 'miniprogram' | 'miniProgram' | 'internal' | 'web' | 'none';
753
+ /** Web 跳转地址 */
754
+ jumpUrl?: string | null;
755
+ /** 目标小程序 appId */
756
+ targetAppId?: string | null;
757
+ /** 目标页面路径 */
758
+ targetPath?: string | null;
759
+ /** 开屏底部图片地址 */
760
+ bottomImage?: string | null;
704
761
  /** 扩展字段 */
705
762
  [key: string]: any;
706
763
  }
@@ -709,7 +766,17 @@ interface AdvertPlatformConfig {
709
766
  */
710
767
  interface AdvertConfigItem {
711
768
  /** 配置 ID */
712
- id?: number;
769
+ id?: number | string;
770
+ /** 商户名称 */
771
+ merchantName?: string | null;
772
+ /** 账号 ID */
773
+ accountId?: number | string | null;
774
+ /** 账号名称 */
775
+ accountName?: string | null;
776
+ /** 应用 ID */
777
+ appId?: string | null;
778
+ /** 应用名称 */
779
+ appName?: string | null;
713
780
  /** 广告位 ID */
714
781
  placementId?: string;
715
782
  /** 配置名称 */
@@ -718,6 +785,10 @@ interface AdvertConfigItem {
718
785
  advertPlatform: AdvertPlatform;
719
786
  /** 广告平台描述 */
720
787
  advertPlatformDesc?: string;
788
+ /** 广告位置类型 */
789
+ positionType?: string | number | null;
790
+ /** 广告位置类型描述 */
791
+ positionTypeDesc?: string | null;
721
792
  /** 优先级,值越小优先级越高 */
722
793
  priority?: number;
723
794
  /** 权重,同优先级下值越大优先级越高 */
@@ -725,21 +796,23 @@ interface AdvertConfigItem {
725
796
  /** 平台配置 */
726
797
  platformConfig?: AdvertPlatformConfig | null;
727
798
  /** 生效开始时间 */
728
- startTime?: string;
799
+ startTime?: string | null;
729
800
  /** 生效结束时间 */
730
- endTime?: string;
801
+ endTime?: string | null;
802
+ /** 日期投放配置 */
803
+ dateConfig?: Record<string, any> | null;
731
804
  /** 状态:1 启用,0 禁用 */
732
805
  status?: number;
733
806
  /** 备注 */
734
- remark?: string;
807
+ remark?: string | null;
735
808
  /** 创建时间 */
736
809
  createTime?: string;
737
810
  /** 更新时间 */
738
811
  updateTime?: string;
739
812
  /** 创建人 */
740
- creator?: string;
813
+ creator?: string | null;
741
814
  /** 更新人 */
742
- updater?: string;
815
+ updater?: string | null;
743
816
  /** 扩展字段 */
744
817
  [key: string]: any;
745
818
  }
@@ -816,4 +889,4 @@ declare function normalizeDisplayAdData(advertConfigs: AdvertConfigItem[], fallb
816
889
  */
817
890
  declare function getDisplayAdConfig(options: GetDisplayAdOptions): Promise<BuildResultReturn<DisplayAdResult>>;
818
891
 
819
- export { type DisplayAdResult, DyErrorCode, DyErrorMessage, ENV_TYPE, EXTERNAL_ENV_TYPE, type GetDisplayAdOptions, type HandleDyAuthDebitSignFlowResult, type HandleDyJsapiPayFlowParams, type HandleDyJsapiPayFlowResult, type HandleDyPayCommandFlowParams, type HandleDyPayCommandFlowResult, type HandleDyPayFlowParams, type HandleDyPayFlowResult, JdErrorCode, JdErrorMessage, type JdInsuranceExternalOptions, type JdInsuranceOptions, type JdInsuranceResult, type JdjrCashLoanExternalOptions, type JdjrCashLoanOptions, type ServicesOptions, createServices, getDisplayAdConfig, getDyPayRtaData, handleDyAuthDebitSignFlow, handleDyJsapiPayFlow, handleDyPayCommandFlow, handleDyPayFlow, handleJdInsurance, handleJdInsuranceExt, handleJdjrCashLoanExt, handleJdjrCashLoanFlow, normalizeDisplayAdData };
892
+ export { type DisplayAdResult, DyErrorCode, DyErrorMessage, ENV_TYPE, EXTERNAL_ENV_TYPE, type GetDisplayAdOptions, type HandleDyAuthDebitSignFlowResult, type HandleDyJsapiPayFlowParams, type HandleDyJsapiPayFlowResult, type HandleDyPayCommandFlowParams, type HandleDyPayCommandFlowResult, type HandleDyPayFlowParams, type HandleDyPayFlowResult, JdErrorCode, JdErrorMessage, type JdInsuranceExternalOptions, type JdInsuranceOptions, type JdInsuranceResult, type JdjrCashLoanExternalOptions, type JdjrCashLoanOptions, type ServicesOptions, createServices, getDisplayAdConfig, getDyPayRtaData, handleDyAuthDebitSignFlow, handleDyAuthDebitSignFlowWithRawPayInfoForTest, handleDyJsapiPayFlow, handleDyPayCommandFlow, handleDyPayFlow, handleJdInsurance, handleJdInsuranceExt, handleJdjrCashLoanExt, handleJdjrCashLoanFlow, normalizeDisplayAdData };
package/dist/index.d.ts CHANGED
@@ -463,6 +463,17 @@ declare function handleDyJsapiPayFlow(params: HandleDyJsapiPayFlowParams): Promi
463
463
  */
464
464
  declare function handleDyAuthDebitSignFlow(): Promise<BuildResultReturn<HandleDyAuthDebitSignFlowResult>>;
465
465
 
466
+ /**
467
+ * 处理抖音授权代扣签约原始 payInfo 透传测试流程
468
+ *
469
+ * 流程与 handleDyAuthDebitSignFlow 保持一致,仅跳过 payInfo 字段校验和重组,
470
+ * 将接口返回的全部 payInfo 内容传给 dypay 的 sdk_info。
471
+ *
472
+ * @experimental 测试验证通过后可整体移除
473
+ * @returns 标准化授权跳转或签约调起结果
474
+ */
475
+ declare function handleDyAuthDebitSignFlowWithRawPayInfoForTest(): Promise<BuildResultReturn<HandleDyAuthDebitSignFlowResult>>;
476
+
466
477
  /**
467
478
  * @Description: 业务错误码定义
468
479
  * @Author: wutao
@@ -621,7 +632,7 @@ declare const DyErrorMessage: Record<number, string>;
621
632
  * @Author: wutao
622
633
  * @Date: 2026-04-21
623
634
  * @LastEditors: wutao
624
- * @LastEditTime: 2026-04-27
635
+ * @LastEditTime: 2026-08-13 15:02:40
625
636
  */
626
637
  /**
627
638
  * 展示广告类型
@@ -652,17 +663,31 @@ interface DisplayAdActionConfig {
652
663
  * 自定义广告内容配置
653
664
  */
654
665
  interface DisplayCustomAdConfig {
666
+ /** 后端广告配置 ID */
667
+ configId?: number | string;
668
+ /** 广告位 ID */
669
+ placementId?: string;
670
+ /** 广告配置名称 */
671
+ configName?: string;
672
+ /** 原始广告平台编码 */
673
+ advertPlatform?: AdvertPlatform;
674
+ /** 自研素材类型 */
675
+ mediaType?: 'image' | 'video';
655
676
  /** 图片地址 */
656
677
  image?: string;
657
678
  /** 视频地址 */
658
679
  video?: string;
659
680
  /** 视频封面地址 */
660
681
  poster?: string;
661
- /** 广告标题 */
662
- title?: string;
663
- /** 广告描述 */
682
+ /** 开屏底部整图素材地址 */
683
+ bottomImage?: string;
684
+ /** 兼容字段:广告主名称,开屏组件不再消费 */
685
+ advertiserName?: string;
686
+ /** 兼容字段:广告主 Logo,开屏组件不再消费 */
687
+ advertiserLogo?: string;
688
+ /** 兼容字段:广告描述,开屏组件不再消费 */
664
689
  description?: string;
665
- /** 按钮文案 */
690
+ /** 兼容字段:按钮文案,开屏组件不再消费 */
666
691
  buttonText?: string;
667
692
  /** 角标文案 */
668
693
  badgeText?: string;
@@ -674,6 +699,10 @@ interface DisplayCustomAdConfig {
674
699
  muted?: boolean;
675
700
  /** 广告规格 */
676
701
  adSpec?: number;
702
+ /** 素材填充模式 */
703
+ fitMode?: 'contain' | 'cover';
704
+ /** 跳转类型 */
705
+ jumpType?: 'miniProgram' | 'internal' | 'web' | 'none';
677
706
  /** 点击动作配置 */
678
707
  action?: DisplayAdActionConfig;
679
708
  /** 兼容字段:跳转小程序的 appId */
@@ -701,6 +730,34 @@ interface AdvertPlatformConfig {
701
730
  adId?: string;
702
731
  /** 平台应用 ID */
703
732
  appId?: string;
733
+ /** 自研素材类型 */
734
+ mediaType?: 'image' | 'video';
735
+ /** 自研图片素材地址,Banner 直接使用该字段 */
736
+ image?: string | null;
737
+ /** 自研视频素材地址 */
738
+ video?: string | null;
739
+ /** 视频封面地址 */
740
+ poster?: string | null;
741
+ /** 广告主名称 */
742
+ advertiserName?: string | null;
743
+ /** 广告主 Logo */
744
+ advertiserLogo?: string | null;
745
+ /** 广告描述 */
746
+ description?: string | null;
747
+ /** 按钮文案 */
748
+ buttonText?: string | null;
749
+ /** 广告标识文案 */
750
+ badgeText?: string | null;
751
+ /** 自研广告跳转类型 */
752
+ jumpType?: 'miniprogram' | 'miniProgram' | 'internal' | 'web' | 'none';
753
+ /** Web 跳转地址 */
754
+ jumpUrl?: string | null;
755
+ /** 目标小程序 appId */
756
+ targetAppId?: string | null;
757
+ /** 目标页面路径 */
758
+ targetPath?: string | null;
759
+ /** 开屏底部图片地址 */
760
+ bottomImage?: string | null;
704
761
  /** 扩展字段 */
705
762
  [key: string]: any;
706
763
  }
@@ -709,7 +766,17 @@ interface AdvertPlatformConfig {
709
766
  */
710
767
  interface AdvertConfigItem {
711
768
  /** 配置 ID */
712
- id?: number;
769
+ id?: number | string;
770
+ /** 商户名称 */
771
+ merchantName?: string | null;
772
+ /** 账号 ID */
773
+ accountId?: number | string | null;
774
+ /** 账号名称 */
775
+ accountName?: string | null;
776
+ /** 应用 ID */
777
+ appId?: string | null;
778
+ /** 应用名称 */
779
+ appName?: string | null;
713
780
  /** 广告位 ID */
714
781
  placementId?: string;
715
782
  /** 配置名称 */
@@ -718,6 +785,10 @@ interface AdvertConfigItem {
718
785
  advertPlatform: AdvertPlatform;
719
786
  /** 广告平台描述 */
720
787
  advertPlatformDesc?: string;
788
+ /** 广告位置类型 */
789
+ positionType?: string | number | null;
790
+ /** 广告位置类型描述 */
791
+ positionTypeDesc?: string | null;
721
792
  /** 优先级,值越小优先级越高 */
722
793
  priority?: number;
723
794
  /** 权重,同优先级下值越大优先级越高 */
@@ -725,21 +796,23 @@ interface AdvertConfigItem {
725
796
  /** 平台配置 */
726
797
  platformConfig?: AdvertPlatformConfig | null;
727
798
  /** 生效开始时间 */
728
- startTime?: string;
799
+ startTime?: string | null;
729
800
  /** 生效结束时间 */
730
- endTime?: string;
801
+ endTime?: string | null;
802
+ /** 日期投放配置 */
803
+ dateConfig?: Record<string, any> | null;
731
804
  /** 状态:1 启用,0 禁用 */
732
805
  status?: number;
733
806
  /** 备注 */
734
- remark?: string;
807
+ remark?: string | null;
735
808
  /** 创建时间 */
736
809
  createTime?: string;
737
810
  /** 更新时间 */
738
811
  updateTime?: string;
739
812
  /** 创建人 */
740
- creator?: string;
813
+ creator?: string | null;
741
814
  /** 更新人 */
742
- updater?: string;
815
+ updater?: string | null;
743
816
  /** 扩展字段 */
744
817
  [key: string]: any;
745
818
  }
@@ -816,4 +889,4 @@ declare function normalizeDisplayAdData(advertConfigs: AdvertConfigItem[], fallb
816
889
  */
817
890
  declare function getDisplayAdConfig(options: GetDisplayAdOptions): Promise<BuildResultReturn<DisplayAdResult>>;
818
891
 
819
- export { type DisplayAdResult, DyErrorCode, DyErrorMessage, ENV_TYPE, EXTERNAL_ENV_TYPE, type GetDisplayAdOptions, type HandleDyAuthDebitSignFlowResult, type HandleDyJsapiPayFlowParams, type HandleDyJsapiPayFlowResult, type HandleDyPayCommandFlowParams, type HandleDyPayCommandFlowResult, type HandleDyPayFlowParams, type HandleDyPayFlowResult, JdErrorCode, JdErrorMessage, type JdInsuranceExternalOptions, type JdInsuranceOptions, type JdInsuranceResult, type JdjrCashLoanExternalOptions, type JdjrCashLoanOptions, type ServicesOptions, createServices, getDisplayAdConfig, getDyPayRtaData, handleDyAuthDebitSignFlow, handleDyJsapiPayFlow, handleDyPayCommandFlow, handleDyPayFlow, handleJdInsurance, handleJdInsuranceExt, handleJdjrCashLoanExt, handleJdjrCashLoanFlow, normalizeDisplayAdData };
892
+ export { type DisplayAdResult, DyErrorCode, DyErrorMessage, ENV_TYPE, EXTERNAL_ENV_TYPE, type GetDisplayAdOptions, type HandleDyAuthDebitSignFlowResult, type HandleDyJsapiPayFlowParams, type HandleDyJsapiPayFlowResult, type HandleDyPayCommandFlowParams, type HandleDyPayCommandFlowResult, type HandleDyPayFlowParams, type HandleDyPayFlowResult, JdErrorCode, JdErrorMessage, type JdInsuranceExternalOptions, type JdInsuranceOptions, type JdInsuranceResult, type JdjrCashLoanExternalOptions, type JdjrCashLoanOptions, type ServicesOptions, createServices, getDisplayAdConfig, getDyPayRtaData, handleDyAuthDebitSignFlow, handleDyAuthDebitSignFlowWithRawPayInfoForTest, handleDyJsapiPayFlow, handleDyPayCommandFlow, handleDyPayFlow, handleJdInsurance, handleJdInsuranceExt, handleJdjrCashLoanExt, handleJdjrCashLoanFlow, normalizeDisplayAdData };