@bubblelab/bubble-core 0.1.51 → 0.1.52
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/bubble-bundle.d.ts +50 -50
- package/dist/bubbles/service-bubble/agi-inc.d.ts +8 -8
- package/dist/bubbles/service-bubble/ai-agent.d.ts +8 -8
- package/dist/bubbles/service-bubble/airtable.d.ts +72 -72
- package/dist/bubbles/service-bubble/ashby/ashby.d.ts +124 -124
- package/dist/bubbles/service-bubble/browserbase/browserbase.d.ts +16 -16
- package/dist/bubbles/service-bubble/crustdata/crustdata.d.ts +4 -4
- package/dist/bubbles/service-bubble/firecrawl.d.ts +48 -48
- package/dist/bubbles/service-bubble/followupboss.d.ts +4 -4
- package/dist/bubbles/service-bubble/fullenrich/fullenrich.d.ts +36 -36
- package/dist/bubbles/service-bubble/github.d.ts +56 -56
- package/dist/bubbles/service-bubble/gmail.d.ts +124 -124
- package/dist/bubbles/service-bubble/google-drive.d.ts +8 -8
- package/dist/bubbles/service-bubble/hello-world.d.ts +2 -2
- package/dist/bubbles/service-bubble/jira/jira.d.ts +24 -24
- package/dist/bubbles/service-bubble/notion/notion.d.ts +392 -392
- package/dist/bubbles/service-bubble/resend.d.ts +8 -8
- package/dist/bubbles/service-bubble/slack/slack.d.ts +28 -28
- package/dist/bubbles/service-bubble/stripe/stripe.d.ts +201 -32
- package/dist/bubbles/service-bubble/stripe/stripe.d.ts.map +1 -1
- package/dist/bubbles/service-bubble/stripe/stripe.js +51 -0
- package/dist/bubbles/service-bubble/stripe/stripe.js.map +1 -1
- package/dist/bubbles/service-bubble/stripe/stripe.schema.d.ts +210 -40
- package/dist/bubbles/service-bubble/stripe/stripe.schema.d.ts.map +1 -1
- package/dist/bubbles/service-bubble/stripe/stripe.schema.js +45 -0
- package/dist/bubbles/service-bubble/stripe/stripe.schema.js.map +1 -1
- package/dist/bubbles/service-bubble/telegram.d.ts +140 -140
- package/dist/bubbles/tool-bubble/bubbleflow-validation-tool.d.ts +8 -8
- package/dist/bubbles/tool-bubble/company-enrichment-tool.d.ts +18 -18
- package/dist/bubbles/tool-bubble/linkedin-tool.d.ts +10 -10
- package/dist/bubbles/tool-bubble/list-bubbles-tool.d.ts +8 -8
- package/dist/bubbles/tool-bubble/people-search-tool.d.ts +10 -10
- package/dist/bubbles/tool-bubble/twitter-tool.d.ts +18 -18
- package/dist/bubbles/tool-bubble/youtube-tool.d.ts +10 -10
- package/dist/bubbles/workflow-bubble/generate-document.workflow.d.ts +8 -8
- package/dist/bubbles/workflow-bubble/pdf-form-operations.workflow.d.ts +48 -48
- package/dist/bubbles/workflow-bubble/pdf-ocr.workflow.d.ts +16 -16
- package/dist/bubbles/workflow-bubble/slack-formatter-agent.d.ts +8 -8
- package/dist/bubbles.json +252 -2
- package/package.json +2 -2
|
@@ -223,6 +223,33 @@ export declare class StripeBubble<T extends StripeParamsInput = StripeParamsInpu
|
|
|
223
223
|
customer?: string | undefined;
|
|
224
224
|
credentials?: Partial<Record<CredentialType, string>> | undefined;
|
|
225
225
|
limit?: number | undefined;
|
|
226
|
+
}>, import("zod").ZodObject<{
|
|
227
|
+
operation: import("zod").ZodLiteral<"retrieve_invoice">;
|
|
228
|
+
invoice_id: import("zod").ZodString;
|
|
229
|
+
credentials: import("zod").ZodOptional<import("zod").ZodRecord<import("zod").ZodNativeEnum<typeof CredentialType>, import("zod").ZodString>>;
|
|
230
|
+
}, "strip", import("zod").ZodTypeAny, {
|
|
231
|
+
operation: "retrieve_invoice";
|
|
232
|
+
invoice_id: string;
|
|
233
|
+
credentials?: Partial<Record<CredentialType, string>> | undefined;
|
|
234
|
+
}, {
|
|
235
|
+
operation: "retrieve_invoice";
|
|
236
|
+
invoice_id: string;
|
|
237
|
+
credentials?: Partial<Record<CredentialType, string>> | undefined;
|
|
238
|
+
}>, import("zod").ZodObject<{
|
|
239
|
+
operation: import("zod").ZodLiteral<"finalize_invoice">;
|
|
240
|
+
invoice_id: import("zod").ZodString;
|
|
241
|
+
auto_advance: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
242
|
+
credentials: import("zod").ZodOptional<import("zod").ZodRecord<import("zod").ZodNativeEnum<typeof CredentialType>, import("zod").ZodString>>;
|
|
243
|
+
}, "strip", import("zod").ZodTypeAny, {
|
|
244
|
+
operation: "finalize_invoice";
|
|
245
|
+
invoice_id: string;
|
|
246
|
+
credentials?: Partial<Record<CredentialType, string>> | undefined;
|
|
247
|
+
auto_advance?: boolean | undefined;
|
|
248
|
+
}, {
|
|
249
|
+
operation: "finalize_invoice";
|
|
250
|
+
invoice_id: string;
|
|
251
|
+
credentials?: Partial<Record<CredentialType, string>> | undefined;
|
|
252
|
+
auto_advance?: boolean | undefined;
|
|
226
253
|
}>, import("zod").ZodObject<{
|
|
227
254
|
operation: import("zod").ZodLiteral<"get_balance">;
|
|
228
255
|
credentials: import("zod").ZodOptional<import("zod").ZodRecord<import("zod").ZodNativeEnum<typeof CredentialType>, import("zod").ZodString>>;
|
|
@@ -523,18 +550,18 @@ export declare class StripeBubble<T extends StripeParamsInput = StripeParamsInpu
|
|
|
523
550
|
created: import("zod").ZodNumber;
|
|
524
551
|
metadata: import("zod").ZodOptional<import("zod").ZodRecord<import("zod").ZodString, import("zod").ZodString>>;
|
|
525
552
|
}, "strip", import("zod").ZodTypeAny, {
|
|
526
|
-
type: "one_time" | "recurring";
|
|
527
553
|
id: string;
|
|
528
554
|
created: number;
|
|
555
|
+
type: "one_time" | "recurring";
|
|
529
556
|
active: boolean;
|
|
530
557
|
product: string;
|
|
531
558
|
unit_amount: number | null;
|
|
532
559
|
currency: string;
|
|
533
560
|
metadata?: Record<string, string> | undefined;
|
|
534
561
|
}, {
|
|
535
|
-
type: "one_time" | "recurring";
|
|
536
562
|
id: string;
|
|
537
563
|
created: number;
|
|
564
|
+
type: "one_time" | "recurring";
|
|
538
565
|
active: boolean;
|
|
539
566
|
product: string;
|
|
540
567
|
unit_amount: number | null;
|
|
@@ -547,9 +574,9 @@ export declare class StripeBubble<T extends StripeParamsInput = StripeParamsInpu
|
|
|
547
574
|
success: boolean;
|
|
548
575
|
error: string;
|
|
549
576
|
price?: {
|
|
550
|
-
type: "one_time" | "recurring";
|
|
551
577
|
id: string;
|
|
552
578
|
created: number;
|
|
579
|
+
type: "one_time" | "recurring";
|
|
553
580
|
active: boolean;
|
|
554
581
|
product: string;
|
|
555
582
|
unit_amount: number | null;
|
|
@@ -561,9 +588,9 @@ export declare class StripeBubble<T extends StripeParamsInput = StripeParamsInpu
|
|
|
561
588
|
success: boolean;
|
|
562
589
|
error: string;
|
|
563
590
|
price?: {
|
|
564
|
-
type: "one_time" | "recurring";
|
|
565
591
|
id: string;
|
|
566
592
|
created: number;
|
|
593
|
+
type: "one_time" | "recurring";
|
|
567
594
|
active: boolean;
|
|
568
595
|
product: string;
|
|
569
596
|
unit_amount: number | null;
|
|
@@ -583,18 +610,18 @@ export declare class StripeBubble<T extends StripeParamsInput = StripeParamsInpu
|
|
|
583
610
|
created: import("zod").ZodNumber;
|
|
584
611
|
metadata: import("zod").ZodOptional<import("zod").ZodRecord<import("zod").ZodString, import("zod").ZodString>>;
|
|
585
612
|
}, "strip", import("zod").ZodTypeAny, {
|
|
586
|
-
type: "one_time" | "recurring";
|
|
587
613
|
id: string;
|
|
588
614
|
created: number;
|
|
615
|
+
type: "one_time" | "recurring";
|
|
589
616
|
active: boolean;
|
|
590
617
|
product: string;
|
|
591
618
|
unit_amount: number | null;
|
|
592
619
|
currency: string;
|
|
593
620
|
metadata?: Record<string, string> | undefined;
|
|
594
621
|
}, {
|
|
595
|
-
type: "one_time" | "recurring";
|
|
596
622
|
id: string;
|
|
597
623
|
created: number;
|
|
624
|
+
type: "one_time" | "recurring";
|
|
598
625
|
active: boolean;
|
|
599
626
|
product: string;
|
|
600
627
|
unit_amount: number | null;
|
|
@@ -607,9 +634,9 @@ export declare class StripeBubble<T extends StripeParamsInput = StripeParamsInpu
|
|
|
607
634
|
success: boolean;
|
|
608
635
|
error: string;
|
|
609
636
|
prices?: {
|
|
610
|
-
type: "one_time" | "recurring";
|
|
611
637
|
id: string;
|
|
612
638
|
created: number;
|
|
639
|
+
type: "one_time" | "recurring";
|
|
613
640
|
active: boolean;
|
|
614
641
|
product: string;
|
|
615
642
|
unit_amount: number | null;
|
|
@@ -621,9 +648,9 @@ export declare class StripeBubble<T extends StripeParamsInput = StripeParamsInpu
|
|
|
621
648
|
success: boolean;
|
|
622
649
|
error: string;
|
|
623
650
|
prices?: {
|
|
624
|
-
type: "one_time" | "recurring";
|
|
625
651
|
id: string;
|
|
626
652
|
created: number;
|
|
653
|
+
type: "one_time" | "recurring";
|
|
627
654
|
active: boolean;
|
|
628
655
|
product: string;
|
|
629
656
|
unit_amount: number | null;
|
|
@@ -686,25 +713,28 @@ export declare class StripeBubble<T extends StripeParamsInput = StripeParamsInpu
|
|
|
686
713
|
currency: import("zod").ZodString;
|
|
687
714
|
created: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
688
715
|
hosted_invoice_url: import("zod").ZodOptional<import("zod").ZodNullable<import("zod").ZodString>>;
|
|
716
|
+
invoice_pdf: import("zod").ZodOptional<import("zod").ZodNullable<import("zod").ZodString>>;
|
|
689
717
|
metadata: import("zod").ZodOptional<import("zod").ZodRecord<import("zod").ZodString, import("zod").ZodString>>;
|
|
690
718
|
}, "strip", import("zod").ZodTypeAny, {
|
|
691
|
-
status: "draft" | "open" | "paid" | "uncollectible" | "void" | null;
|
|
692
719
|
id: string;
|
|
720
|
+
status: "draft" | "open" | "paid" | "uncollectible" | "void" | null;
|
|
693
721
|
currency: string;
|
|
694
722
|
customer: string | null;
|
|
695
723
|
total: number;
|
|
696
724
|
created?: number | undefined;
|
|
697
725
|
metadata?: Record<string, string> | undefined;
|
|
698
726
|
hosted_invoice_url?: string | null | undefined;
|
|
727
|
+
invoice_pdf?: string | null | undefined;
|
|
699
728
|
}, {
|
|
700
|
-
status: "draft" | "open" | "paid" | "uncollectible" | "void" | null;
|
|
701
729
|
id: string;
|
|
730
|
+
status: "draft" | "open" | "paid" | "uncollectible" | "void" | null;
|
|
702
731
|
currency: string;
|
|
703
732
|
customer: string | null;
|
|
704
733
|
total: number;
|
|
705
734
|
created?: number | undefined;
|
|
706
735
|
metadata?: Record<string, string> | undefined;
|
|
707
736
|
hosted_invoice_url?: string | null | undefined;
|
|
737
|
+
invoice_pdf?: string | null | undefined;
|
|
708
738
|
}>>;
|
|
709
739
|
error: import("zod").ZodString;
|
|
710
740
|
}, "strip", import("zod").ZodTypeAny, {
|
|
@@ -712,28 +742,30 @@ export declare class StripeBubble<T extends StripeParamsInput = StripeParamsInpu
|
|
|
712
742
|
success: boolean;
|
|
713
743
|
error: string;
|
|
714
744
|
invoice?: {
|
|
715
|
-
status: "draft" | "open" | "paid" | "uncollectible" | "void" | null;
|
|
716
745
|
id: string;
|
|
746
|
+
status: "draft" | "open" | "paid" | "uncollectible" | "void" | null;
|
|
717
747
|
currency: string;
|
|
718
748
|
customer: string | null;
|
|
719
749
|
total: number;
|
|
720
750
|
created?: number | undefined;
|
|
721
751
|
metadata?: Record<string, string> | undefined;
|
|
722
752
|
hosted_invoice_url?: string | null | undefined;
|
|
753
|
+
invoice_pdf?: string | null | undefined;
|
|
723
754
|
} | undefined;
|
|
724
755
|
}, {
|
|
725
756
|
operation: "create_invoice";
|
|
726
757
|
success: boolean;
|
|
727
758
|
error: string;
|
|
728
759
|
invoice?: {
|
|
729
|
-
status: "draft" | "open" | "paid" | "uncollectible" | "void" | null;
|
|
730
760
|
id: string;
|
|
761
|
+
status: "draft" | "open" | "paid" | "uncollectible" | "void" | null;
|
|
731
762
|
currency: string;
|
|
732
763
|
customer: string | null;
|
|
733
764
|
total: number;
|
|
734
765
|
created?: number | undefined;
|
|
735
766
|
metadata?: Record<string, string> | undefined;
|
|
736
767
|
hosted_invoice_url?: string | null | undefined;
|
|
768
|
+
invoice_pdf?: string | null | undefined;
|
|
737
769
|
} | undefined;
|
|
738
770
|
}>, import("zod").ZodObject<{
|
|
739
771
|
operation: import("zod").ZodLiteral<"list_invoices">;
|
|
@@ -746,25 +778,28 @@ export declare class StripeBubble<T extends StripeParamsInput = StripeParamsInpu
|
|
|
746
778
|
currency: import("zod").ZodString;
|
|
747
779
|
created: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
748
780
|
hosted_invoice_url: import("zod").ZodOptional<import("zod").ZodNullable<import("zod").ZodString>>;
|
|
781
|
+
invoice_pdf: import("zod").ZodOptional<import("zod").ZodNullable<import("zod").ZodString>>;
|
|
749
782
|
metadata: import("zod").ZodOptional<import("zod").ZodRecord<import("zod").ZodString, import("zod").ZodString>>;
|
|
750
783
|
}, "strip", import("zod").ZodTypeAny, {
|
|
751
|
-
status: "draft" | "open" | "paid" | "uncollectible" | "void" | null;
|
|
752
784
|
id: string;
|
|
785
|
+
status: "draft" | "open" | "paid" | "uncollectible" | "void" | null;
|
|
753
786
|
currency: string;
|
|
754
787
|
customer: string | null;
|
|
755
788
|
total: number;
|
|
756
789
|
created?: number | undefined;
|
|
757
790
|
metadata?: Record<string, string> | undefined;
|
|
758
791
|
hosted_invoice_url?: string | null | undefined;
|
|
792
|
+
invoice_pdf?: string | null | undefined;
|
|
759
793
|
}, {
|
|
760
|
-
status: "draft" | "open" | "paid" | "uncollectible" | "void" | null;
|
|
761
794
|
id: string;
|
|
795
|
+
status: "draft" | "open" | "paid" | "uncollectible" | "void" | null;
|
|
762
796
|
currency: string;
|
|
763
797
|
customer: string | null;
|
|
764
798
|
total: number;
|
|
765
799
|
created?: number | undefined;
|
|
766
800
|
metadata?: Record<string, string> | undefined;
|
|
767
801
|
hosted_invoice_url?: string | null | undefined;
|
|
802
|
+
invoice_pdf?: string | null | undefined;
|
|
768
803
|
}>, "many">>;
|
|
769
804
|
error: import("zod").ZodString;
|
|
770
805
|
}, "strip", import("zod").ZodTypeAny, {
|
|
@@ -772,29 +807,161 @@ export declare class StripeBubble<T extends StripeParamsInput = StripeParamsInpu
|
|
|
772
807
|
success: boolean;
|
|
773
808
|
error: string;
|
|
774
809
|
invoices?: {
|
|
775
|
-
status: "draft" | "open" | "paid" | "uncollectible" | "void" | null;
|
|
776
810
|
id: string;
|
|
811
|
+
status: "draft" | "open" | "paid" | "uncollectible" | "void" | null;
|
|
777
812
|
currency: string;
|
|
778
813
|
customer: string | null;
|
|
779
814
|
total: number;
|
|
780
815
|
created?: number | undefined;
|
|
781
816
|
metadata?: Record<string, string> | undefined;
|
|
782
817
|
hosted_invoice_url?: string | null | undefined;
|
|
818
|
+
invoice_pdf?: string | null | undefined;
|
|
783
819
|
}[] | undefined;
|
|
784
820
|
}, {
|
|
785
821
|
operation: "list_invoices";
|
|
786
822
|
success: boolean;
|
|
787
823
|
error: string;
|
|
788
824
|
invoices?: {
|
|
789
|
-
status: "draft" | "open" | "paid" | "uncollectible" | "void" | null;
|
|
790
825
|
id: string;
|
|
826
|
+
status: "draft" | "open" | "paid" | "uncollectible" | "void" | null;
|
|
791
827
|
currency: string;
|
|
792
828
|
customer: string | null;
|
|
793
829
|
total: number;
|
|
794
830
|
created?: number | undefined;
|
|
795
831
|
metadata?: Record<string, string> | undefined;
|
|
796
832
|
hosted_invoice_url?: string | null | undefined;
|
|
833
|
+
invoice_pdf?: string | null | undefined;
|
|
797
834
|
}[] | undefined;
|
|
835
|
+
}>, import("zod").ZodObject<{
|
|
836
|
+
operation: import("zod").ZodLiteral<"retrieve_invoice">;
|
|
837
|
+
success: import("zod").ZodBoolean;
|
|
838
|
+
invoice: import("zod").ZodOptional<import("zod").ZodObject<{
|
|
839
|
+
id: import("zod").ZodString;
|
|
840
|
+
customer: import("zod").ZodNullable<import("zod").ZodString>;
|
|
841
|
+
status: import("zod").ZodNullable<import("zod").ZodEnum<["draft", "open", "paid", "uncollectible", "void"]>>;
|
|
842
|
+
total: import("zod").ZodNumber;
|
|
843
|
+
currency: import("zod").ZodString;
|
|
844
|
+
created: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
845
|
+
hosted_invoice_url: import("zod").ZodOptional<import("zod").ZodNullable<import("zod").ZodString>>;
|
|
846
|
+
invoice_pdf: import("zod").ZodOptional<import("zod").ZodNullable<import("zod").ZodString>>;
|
|
847
|
+
metadata: import("zod").ZodOptional<import("zod").ZodRecord<import("zod").ZodString, import("zod").ZodString>>;
|
|
848
|
+
}, "strip", import("zod").ZodTypeAny, {
|
|
849
|
+
id: string;
|
|
850
|
+
status: "draft" | "open" | "paid" | "uncollectible" | "void" | null;
|
|
851
|
+
currency: string;
|
|
852
|
+
customer: string | null;
|
|
853
|
+
total: number;
|
|
854
|
+
created?: number | undefined;
|
|
855
|
+
metadata?: Record<string, string> | undefined;
|
|
856
|
+
hosted_invoice_url?: string | null | undefined;
|
|
857
|
+
invoice_pdf?: string | null | undefined;
|
|
858
|
+
}, {
|
|
859
|
+
id: string;
|
|
860
|
+
status: "draft" | "open" | "paid" | "uncollectible" | "void" | null;
|
|
861
|
+
currency: string;
|
|
862
|
+
customer: string | null;
|
|
863
|
+
total: number;
|
|
864
|
+
created?: number | undefined;
|
|
865
|
+
metadata?: Record<string, string> | undefined;
|
|
866
|
+
hosted_invoice_url?: string | null | undefined;
|
|
867
|
+
invoice_pdf?: string | null | undefined;
|
|
868
|
+
}>>;
|
|
869
|
+
error: import("zod").ZodString;
|
|
870
|
+
}, "strip", import("zod").ZodTypeAny, {
|
|
871
|
+
operation: "retrieve_invoice";
|
|
872
|
+
success: boolean;
|
|
873
|
+
error: string;
|
|
874
|
+
invoice?: {
|
|
875
|
+
id: string;
|
|
876
|
+
status: "draft" | "open" | "paid" | "uncollectible" | "void" | null;
|
|
877
|
+
currency: string;
|
|
878
|
+
customer: string | null;
|
|
879
|
+
total: number;
|
|
880
|
+
created?: number | undefined;
|
|
881
|
+
metadata?: Record<string, string> | undefined;
|
|
882
|
+
hosted_invoice_url?: string | null | undefined;
|
|
883
|
+
invoice_pdf?: string | null | undefined;
|
|
884
|
+
} | undefined;
|
|
885
|
+
}, {
|
|
886
|
+
operation: "retrieve_invoice";
|
|
887
|
+
success: boolean;
|
|
888
|
+
error: string;
|
|
889
|
+
invoice?: {
|
|
890
|
+
id: string;
|
|
891
|
+
status: "draft" | "open" | "paid" | "uncollectible" | "void" | null;
|
|
892
|
+
currency: string;
|
|
893
|
+
customer: string | null;
|
|
894
|
+
total: number;
|
|
895
|
+
created?: number | undefined;
|
|
896
|
+
metadata?: Record<string, string> | undefined;
|
|
897
|
+
hosted_invoice_url?: string | null | undefined;
|
|
898
|
+
invoice_pdf?: string | null | undefined;
|
|
899
|
+
} | undefined;
|
|
900
|
+
}>, import("zod").ZodObject<{
|
|
901
|
+
operation: import("zod").ZodLiteral<"finalize_invoice">;
|
|
902
|
+
success: import("zod").ZodBoolean;
|
|
903
|
+
invoice: import("zod").ZodOptional<import("zod").ZodObject<{
|
|
904
|
+
id: import("zod").ZodString;
|
|
905
|
+
customer: import("zod").ZodNullable<import("zod").ZodString>;
|
|
906
|
+
status: import("zod").ZodNullable<import("zod").ZodEnum<["draft", "open", "paid", "uncollectible", "void"]>>;
|
|
907
|
+
total: import("zod").ZodNumber;
|
|
908
|
+
currency: import("zod").ZodString;
|
|
909
|
+
created: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
910
|
+
hosted_invoice_url: import("zod").ZodOptional<import("zod").ZodNullable<import("zod").ZodString>>;
|
|
911
|
+
invoice_pdf: import("zod").ZodOptional<import("zod").ZodNullable<import("zod").ZodString>>;
|
|
912
|
+
metadata: import("zod").ZodOptional<import("zod").ZodRecord<import("zod").ZodString, import("zod").ZodString>>;
|
|
913
|
+
}, "strip", import("zod").ZodTypeAny, {
|
|
914
|
+
id: string;
|
|
915
|
+
status: "draft" | "open" | "paid" | "uncollectible" | "void" | null;
|
|
916
|
+
currency: string;
|
|
917
|
+
customer: string | null;
|
|
918
|
+
total: number;
|
|
919
|
+
created?: number | undefined;
|
|
920
|
+
metadata?: Record<string, string> | undefined;
|
|
921
|
+
hosted_invoice_url?: string | null | undefined;
|
|
922
|
+
invoice_pdf?: string | null | undefined;
|
|
923
|
+
}, {
|
|
924
|
+
id: string;
|
|
925
|
+
status: "draft" | "open" | "paid" | "uncollectible" | "void" | null;
|
|
926
|
+
currency: string;
|
|
927
|
+
customer: string | null;
|
|
928
|
+
total: number;
|
|
929
|
+
created?: number | undefined;
|
|
930
|
+
metadata?: Record<string, string> | undefined;
|
|
931
|
+
hosted_invoice_url?: string | null | undefined;
|
|
932
|
+
invoice_pdf?: string | null | undefined;
|
|
933
|
+
}>>;
|
|
934
|
+
error: import("zod").ZodString;
|
|
935
|
+
}, "strip", import("zod").ZodTypeAny, {
|
|
936
|
+
operation: "finalize_invoice";
|
|
937
|
+
success: boolean;
|
|
938
|
+
error: string;
|
|
939
|
+
invoice?: {
|
|
940
|
+
id: string;
|
|
941
|
+
status: "draft" | "open" | "paid" | "uncollectible" | "void" | null;
|
|
942
|
+
currency: string;
|
|
943
|
+
customer: string | null;
|
|
944
|
+
total: number;
|
|
945
|
+
created?: number | undefined;
|
|
946
|
+
metadata?: Record<string, string> | undefined;
|
|
947
|
+
hosted_invoice_url?: string | null | undefined;
|
|
948
|
+
invoice_pdf?: string | null | undefined;
|
|
949
|
+
} | undefined;
|
|
950
|
+
}, {
|
|
951
|
+
operation: "finalize_invoice";
|
|
952
|
+
success: boolean;
|
|
953
|
+
error: string;
|
|
954
|
+
invoice?: {
|
|
955
|
+
id: string;
|
|
956
|
+
status: "draft" | "open" | "paid" | "uncollectible" | "void" | null;
|
|
957
|
+
currency: string;
|
|
958
|
+
customer: string | null;
|
|
959
|
+
total: number;
|
|
960
|
+
created?: number | undefined;
|
|
961
|
+
metadata?: Record<string, string> | undefined;
|
|
962
|
+
hosted_invoice_url?: string | null | undefined;
|
|
963
|
+
invoice_pdf?: string | null | undefined;
|
|
964
|
+
} | undefined;
|
|
798
965
|
}>, import("zod").ZodObject<{
|
|
799
966
|
operation: import("zod").ZodLiteral<"get_balance">;
|
|
800
967
|
success: import("zod").ZodBoolean;
|
|
@@ -879,17 +1046,17 @@ export declare class StripeBubble<T extends StripeParamsInput = StripeParamsInpu
|
|
|
879
1046
|
created: import("zod").ZodNumber;
|
|
880
1047
|
metadata: import("zod").ZodOptional<import("zod").ZodRecord<import("zod").ZodString, import("zod").ZodString>>;
|
|
881
1048
|
}, "strip", import("zod").ZodTypeAny, {
|
|
882
|
-
status: "requires_payment_method" | "requires_confirmation" | "requires_action" | "processing" | "requires_capture" | "canceled" | "succeeded";
|
|
883
1049
|
id: string;
|
|
884
1050
|
created: number;
|
|
1051
|
+
status: "requires_payment_method" | "requires_confirmation" | "requires_action" | "processing" | "requires_capture" | "canceled" | "succeeded";
|
|
885
1052
|
currency: string;
|
|
886
1053
|
amount: number;
|
|
887
1054
|
metadata?: Record<string, string> | undefined;
|
|
888
1055
|
customer?: string | null | undefined;
|
|
889
1056
|
}, {
|
|
890
|
-
status: "requires_payment_method" | "requires_confirmation" | "requires_action" | "processing" | "requires_capture" | "canceled" | "succeeded";
|
|
891
1057
|
id: string;
|
|
892
1058
|
created: number;
|
|
1059
|
+
status: "requires_payment_method" | "requires_confirmation" | "requires_action" | "processing" | "requires_capture" | "canceled" | "succeeded";
|
|
893
1060
|
currency: string;
|
|
894
1061
|
amount: number;
|
|
895
1062
|
metadata?: Record<string, string> | undefined;
|
|
@@ -901,9 +1068,9 @@ export declare class StripeBubble<T extends StripeParamsInput = StripeParamsInpu
|
|
|
901
1068
|
success: boolean;
|
|
902
1069
|
error: string;
|
|
903
1070
|
payment_intents?: {
|
|
904
|
-
status: "requires_payment_method" | "requires_confirmation" | "requires_action" | "processing" | "requires_capture" | "canceled" | "succeeded";
|
|
905
1071
|
id: string;
|
|
906
1072
|
created: number;
|
|
1073
|
+
status: "requires_payment_method" | "requires_confirmation" | "requires_action" | "processing" | "requires_capture" | "canceled" | "succeeded";
|
|
907
1074
|
currency: string;
|
|
908
1075
|
amount: number;
|
|
909
1076
|
metadata?: Record<string, string> | undefined;
|
|
@@ -914,9 +1081,9 @@ export declare class StripeBubble<T extends StripeParamsInput = StripeParamsInpu
|
|
|
914
1081
|
success: boolean;
|
|
915
1082
|
error: string;
|
|
916
1083
|
payment_intents?: {
|
|
917
|
-
status: "requires_payment_method" | "requires_confirmation" | "requires_action" | "processing" | "requires_capture" | "canceled" | "succeeded";
|
|
918
1084
|
id: string;
|
|
919
1085
|
created: number;
|
|
1086
|
+
status: "requires_payment_method" | "requires_confirmation" | "requires_action" | "processing" | "requires_capture" | "canceled" | "succeeded";
|
|
920
1087
|
currency: string;
|
|
921
1088
|
amount: number;
|
|
922
1089
|
metadata?: Record<string, string> | undefined;
|
|
@@ -935,18 +1102,18 @@ export declare class StripeBubble<T extends StripeParamsInput = StripeParamsInpu
|
|
|
935
1102
|
created: import("zod").ZodNumber;
|
|
936
1103
|
metadata: import("zod").ZodOptional<import("zod").ZodRecord<import("zod").ZodString, import("zod").ZodString>>;
|
|
937
1104
|
}, "strip", import("zod").ZodTypeAny, {
|
|
938
|
-
status: "active" | "canceled" | "incomplete" | "incomplete_expired" | "trialing" | "past_due" | "unpaid" | "paused";
|
|
939
1105
|
id: string;
|
|
940
1106
|
created: number;
|
|
1107
|
+
status: "active" | "canceled" | "incomplete" | "incomplete_expired" | "trialing" | "past_due" | "unpaid" | "paused";
|
|
941
1108
|
customer: string;
|
|
942
1109
|
cancel_at_period_end: boolean;
|
|
943
1110
|
metadata?: Record<string, string> | undefined;
|
|
944
1111
|
current_period_start?: number | undefined;
|
|
945
1112
|
current_period_end?: number | undefined;
|
|
946
1113
|
}, {
|
|
947
|
-
status: "active" | "canceled" | "incomplete" | "incomplete_expired" | "trialing" | "past_due" | "unpaid" | "paused";
|
|
948
1114
|
id: string;
|
|
949
1115
|
created: number;
|
|
1116
|
+
status: "active" | "canceled" | "incomplete" | "incomplete_expired" | "trialing" | "past_due" | "unpaid" | "paused";
|
|
950
1117
|
customer: string;
|
|
951
1118
|
cancel_at_period_end: boolean;
|
|
952
1119
|
metadata?: Record<string, string> | undefined;
|
|
@@ -959,9 +1126,9 @@ export declare class StripeBubble<T extends StripeParamsInput = StripeParamsInpu
|
|
|
959
1126
|
success: boolean;
|
|
960
1127
|
error: string;
|
|
961
1128
|
subscriptions?: {
|
|
962
|
-
status: "active" | "canceled" | "incomplete" | "incomplete_expired" | "trialing" | "past_due" | "unpaid" | "paused";
|
|
963
1129
|
id: string;
|
|
964
1130
|
created: number;
|
|
1131
|
+
status: "active" | "canceled" | "incomplete" | "incomplete_expired" | "trialing" | "past_due" | "unpaid" | "paused";
|
|
965
1132
|
customer: string;
|
|
966
1133
|
cancel_at_period_end: boolean;
|
|
967
1134
|
metadata?: Record<string, string> | undefined;
|
|
@@ -973,9 +1140,9 @@ export declare class StripeBubble<T extends StripeParamsInput = StripeParamsInpu
|
|
|
973
1140
|
success: boolean;
|
|
974
1141
|
error: string;
|
|
975
1142
|
subscriptions?: {
|
|
976
|
-
status: "active" | "canceled" | "incomplete" | "incomplete_expired" | "trialing" | "past_due" | "unpaid" | "paused";
|
|
977
1143
|
id: string;
|
|
978
1144
|
created: number;
|
|
1145
|
+
status: "active" | "canceled" | "incomplete" | "incomplete_expired" | "trialing" | "past_due" | "unpaid" | "paused";
|
|
979
1146
|
customer: string;
|
|
980
1147
|
cancel_at_period_end: boolean;
|
|
981
1148
|
metadata?: Record<string, string> | undefined;
|
|
@@ -995,18 +1162,18 @@ export declare class StripeBubble<T extends StripeParamsInput = StripeParamsInpu
|
|
|
995
1162
|
created: import("zod").ZodNumber;
|
|
996
1163
|
metadata: import("zod").ZodOptional<import("zod").ZodRecord<import("zod").ZodString, import("zod").ZodString>>;
|
|
997
1164
|
}, "strip", import("zod").ZodTypeAny, {
|
|
998
|
-
status: "active" | "canceled" | "incomplete" | "incomplete_expired" | "trialing" | "past_due" | "unpaid" | "paused";
|
|
999
1165
|
id: string;
|
|
1000
1166
|
created: number;
|
|
1167
|
+
status: "active" | "canceled" | "incomplete" | "incomplete_expired" | "trialing" | "past_due" | "unpaid" | "paused";
|
|
1001
1168
|
customer: string;
|
|
1002
1169
|
cancel_at_period_end: boolean;
|
|
1003
1170
|
metadata?: Record<string, string> | undefined;
|
|
1004
1171
|
current_period_start?: number | undefined;
|
|
1005
1172
|
current_period_end?: number | undefined;
|
|
1006
1173
|
}, {
|
|
1007
|
-
status: "active" | "canceled" | "incomplete" | "incomplete_expired" | "trialing" | "past_due" | "unpaid" | "paused";
|
|
1008
1174
|
id: string;
|
|
1009
1175
|
created: number;
|
|
1176
|
+
status: "active" | "canceled" | "incomplete" | "incomplete_expired" | "trialing" | "past_due" | "unpaid" | "paused";
|
|
1010
1177
|
customer: string;
|
|
1011
1178
|
cancel_at_period_end: boolean;
|
|
1012
1179
|
metadata?: Record<string, string> | undefined;
|
|
@@ -1019,9 +1186,9 @@ export declare class StripeBubble<T extends StripeParamsInput = StripeParamsInpu
|
|
|
1019
1186
|
success: boolean;
|
|
1020
1187
|
error: string;
|
|
1021
1188
|
subscription?: {
|
|
1022
|
-
status: "active" | "canceled" | "incomplete" | "incomplete_expired" | "trialing" | "past_due" | "unpaid" | "paused";
|
|
1023
1189
|
id: string;
|
|
1024
1190
|
created: number;
|
|
1191
|
+
status: "active" | "canceled" | "incomplete" | "incomplete_expired" | "trialing" | "past_due" | "unpaid" | "paused";
|
|
1025
1192
|
customer: string;
|
|
1026
1193
|
cancel_at_period_end: boolean;
|
|
1027
1194
|
metadata?: Record<string, string> | undefined;
|
|
@@ -1033,9 +1200,9 @@ export declare class StripeBubble<T extends StripeParamsInput = StripeParamsInpu
|
|
|
1033
1200
|
success: boolean;
|
|
1034
1201
|
error: string;
|
|
1035
1202
|
subscription?: {
|
|
1036
|
-
status: "active" | "canceled" | "incomplete" | "incomplete_expired" | "trialing" | "past_due" | "unpaid" | "paused";
|
|
1037
1203
|
id: string;
|
|
1038
1204
|
created: number;
|
|
1205
|
+
status: "active" | "canceled" | "incomplete" | "incomplete_expired" | "trialing" | "past_due" | "unpaid" | "paused";
|
|
1039
1206
|
customer: string;
|
|
1040
1207
|
cancel_at_period_end: boolean;
|
|
1041
1208
|
metadata?: Record<string, string> | undefined;
|
|
@@ -1100,18 +1267,18 @@ export declare class StripeBubble<T extends StripeParamsInput = StripeParamsInpu
|
|
|
1100
1267
|
created: import("zod").ZodNumber;
|
|
1101
1268
|
metadata: import("zod").ZodOptional<import("zod").ZodRecord<import("zod").ZodString, import("zod").ZodString>>;
|
|
1102
1269
|
}, "strip", import("zod").ZodTypeAny, {
|
|
1103
|
-
status: "active" | "canceled" | "incomplete" | "incomplete_expired" | "trialing" | "past_due" | "unpaid" | "paused";
|
|
1104
1270
|
id: string;
|
|
1105
1271
|
created: number;
|
|
1272
|
+
status: "active" | "canceled" | "incomplete" | "incomplete_expired" | "trialing" | "past_due" | "unpaid" | "paused";
|
|
1106
1273
|
customer: string;
|
|
1107
1274
|
cancel_at_period_end: boolean;
|
|
1108
1275
|
metadata?: Record<string, string> | undefined;
|
|
1109
1276
|
current_period_start?: number | undefined;
|
|
1110
1277
|
current_period_end?: number | undefined;
|
|
1111
1278
|
}, {
|
|
1112
|
-
status: "active" | "canceled" | "incomplete" | "incomplete_expired" | "trialing" | "past_due" | "unpaid" | "paused";
|
|
1113
1279
|
id: string;
|
|
1114
1280
|
created: number;
|
|
1281
|
+
status: "active" | "canceled" | "incomplete" | "incomplete_expired" | "trialing" | "past_due" | "unpaid" | "paused";
|
|
1115
1282
|
customer: string;
|
|
1116
1283
|
cancel_at_period_end: boolean;
|
|
1117
1284
|
metadata?: Record<string, string> | undefined;
|
|
@@ -1124,9 +1291,9 @@ export declare class StripeBubble<T extends StripeParamsInput = StripeParamsInpu
|
|
|
1124
1291
|
success: boolean;
|
|
1125
1292
|
error: string;
|
|
1126
1293
|
subscription?: {
|
|
1127
|
-
status: "active" | "canceled" | "incomplete" | "incomplete_expired" | "trialing" | "past_due" | "unpaid" | "paused";
|
|
1128
1294
|
id: string;
|
|
1129
1295
|
created: number;
|
|
1296
|
+
status: "active" | "canceled" | "incomplete" | "incomplete_expired" | "trialing" | "past_due" | "unpaid" | "paused";
|
|
1130
1297
|
customer: string;
|
|
1131
1298
|
cancel_at_period_end: boolean;
|
|
1132
1299
|
metadata?: Record<string, string> | undefined;
|
|
@@ -1138,9 +1305,9 @@ export declare class StripeBubble<T extends StripeParamsInput = StripeParamsInpu
|
|
|
1138
1305
|
success: boolean;
|
|
1139
1306
|
error: string;
|
|
1140
1307
|
subscription?: {
|
|
1141
|
-
status: "active" | "canceled" | "incomplete" | "incomplete_expired" | "trialing" | "past_due" | "unpaid" | "paused";
|
|
1142
1308
|
id: string;
|
|
1143
1309
|
created: number;
|
|
1310
|
+
status: "active" | "canceled" | "incomplete" | "incomplete_expired" | "trialing" | "past_due" | "unpaid" | "paused";
|
|
1144
1311
|
customer: string;
|
|
1145
1312
|
cancel_at_period_end: boolean;
|
|
1146
1313
|
metadata?: Record<string, string> | undefined;
|
|
@@ -1167,6 +1334,8 @@ export declare class StripeBubble<T extends StripeParamsInput = StripeParamsInpu
|
|
|
1167
1334
|
private createPaymentLink;
|
|
1168
1335
|
private createInvoice;
|
|
1169
1336
|
private listInvoices;
|
|
1337
|
+
private retrieveInvoice;
|
|
1338
|
+
private finalizeInvoice;
|
|
1170
1339
|
private getBalance;
|
|
1171
1340
|
private listPaymentIntents;
|
|
1172
1341
|
private listSubscriptions;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"stripe.d.ts","sourceRoot":"","sources":["../../../../src/bubbles/service-bubble/stripe/stripe.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,wCAAwC,CAAC;AACvE,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,0BAA0B,CAAC;AAC9D,OAAO,EAAE,cAAc,EAAE,MAAM,2BAA2B,CAAC;AAC3D,OAAO,EAIL,KAAK,iBAAiB,EACtB,KAAK,YAAY,EAClB,MAAM,oBAAoB,CAAC;AAE5B;;;;;;;;;;;;;;;;;;;;;;;;;;;GA2BG;AACH,qBAAa,YAAY,CACvB,CAAC,SAAS,iBAAiB,GAAG,iBAAiB,CAC/C,SAAQ,aAAa,CACrB,CAAC,EACD,OAAO,CAAC,YAAY,EAAE;IAAE,SAAS,EAAE,CAAC,CAAC,WAAW,CAAC,CAAA;CAAE,CAAC,CACrD;IACC,MAAM,CAAC,QAAQ,CAAC,IAAI,EAAG,SAAS,CAAU;IAC1C,MAAM,CAAC,QAAQ,CAAC,OAAO,YAAY;IACnC,MAAM,CAAC,QAAQ,CAAC,QAAQ,EAAG,QAAQ,CAAU;IAC7C,MAAM,CAAC,QAAQ,CAAC,UAAU,YAAY;IACtC,MAAM,CAAC,QAAQ,CAAC,MAAM
|
|
1
|
+
{"version":3,"file":"stripe.d.ts","sourceRoot":"","sources":["../../../../src/bubbles/service-bubble/stripe/stripe.ts"],"names":[],"mappings":"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"}
|
|
@@ -161,6 +161,10 @@ export class StripeBubble extends ServiceBubble {
|
|
|
161
161
|
return await this.createInvoice(parsedParams);
|
|
162
162
|
case 'list_invoices':
|
|
163
163
|
return await this.listInvoices(parsedParams);
|
|
164
|
+
case 'retrieve_invoice':
|
|
165
|
+
return await this.retrieveInvoice(parsedParams);
|
|
166
|
+
case 'finalize_invoice':
|
|
167
|
+
return await this.finalizeInvoice(parsedParams);
|
|
164
168
|
case 'get_balance':
|
|
165
169
|
return await this.getBalance();
|
|
166
170
|
case 'list_payment_intents':
|
|
@@ -431,11 +435,58 @@ export class StripeBubble extends ServiceBubble {
|
|
|
431
435
|
currency: i.currency,
|
|
432
436
|
created: i.created,
|
|
433
437
|
hosted_invoice_url: i.hosted_invoice_url,
|
|
438
|
+
invoice_pdf: i.invoice_pdf,
|
|
434
439
|
metadata: i.metadata,
|
|
435
440
|
})),
|
|
436
441
|
error: '',
|
|
437
442
|
};
|
|
438
443
|
}
|
|
444
|
+
async retrieveInvoice(params) {
|
|
445
|
+
const { invoice_id } = params;
|
|
446
|
+
const response = await this.makeStripeRequest(`/v1/invoices/${invoice_id}`, 'GET');
|
|
447
|
+
const invoice = response;
|
|
448
|
+
return {
|
|
449
|
+
operation: 'retrieve_invoice',
|
|
450
|
+
success: true,
|
|
451
|
+
invoice: {
|
|
452
|
+
id: invoice.id,
|
|
453
|
+
customer: invoice.customer,
|
|
454
|
+
status: invoice.status,
|
|
455
|
+
total: invoice.total,
|
|
456
|
+
currency: invoice.currency,
|
|
457
|
+
created: invoice.created,
|
|
458
|
+
hosted_invoice_url: invoice.hosted_invoice_url,
|
|
459
|
+
invoice_pdf: invoice.invoice_pdf,
|
|
460
|
+
metadata: invoice.metadata,
|
|
461
|
+
},
|
|
462
|
+
error: '',
|
|
463
|
+
};
|
|
464
|
+
}
|
|
465
|
+
async finalizeInvoice(params) {
|
|
466
|
+
const { invoice_id, auto_advance } = params;
|
|
467
|
+
const body = {};
|
|
468
|
+
if (auto_advance !== undefined) {
|
|
469
|
+
body.auto_advance = String(auto_advance);
|
|
470
|
+
}
|
|
471
|
+
const response = await this.makeStripeRequest(`/v1/invoices/${invoice_id}/finalize`, 'POST', Object.keys(body).length > 0 ? body : undefined);
|
|
472
|
+
const invoice = response;
|
|
473
|
+
return {
|
|
474
|
+
operation: 'finalize_invoice',
|
|
475
|
+
success: true,
|
|
476
|
+
invoice: {
|
|
477
|
+
id: invoice.id,
|
|
478
|
+
customer: invoice.customer,
|
|
479
|
+
status: invoice.status,
|
|
480
|
+
total: invoice.total,
|
|
481
|
+
currency: invoice.currency,
|
|
482
|
+
created: invoice.created,
|
|
483
|
+
hosted_invoice_url: invoice.hosted_invoice_url,
|
|
484
|
+
invoice_pdf: invoice.invoice_pdf,
|
|
485
|
+
metadata: invoice.metadata,
|
|
486
|
+
},
|
|
487
|
+
error: '',
|
|
488
|
+
};
|
|
489
|
+
}
|
|
439
490
|
// ============================================================================
|
|
440
491
|
// BALANCE OPERATIONS
|
|
441
492
|
// ============================================================================
|