@outseta/react 0.4.16 → 0.4.17

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.
@@ -1475,6 +1475,8 @@ export type StripeSubscriptionAllOfAccount = Account | null;
1475
1475
  export type StripeSubscriptionAllOfCurrentStripeSubscriptionSchedule = StripeSubscriptionSchedule | null;
1476
1476
 
1477
1477
  export type StripeSubscriptionAllOf = {
1478
+ /** @nullable */
1479
+ ApplicationFeePercent?: number | null;
1478
1480
  /** @nullable */
1479
1481
  CancelAt?: string | null;
1480
1482
  CancelAtPeriodEnd?: boolean;
@@ -1871,6 +1873,13 @@ export type StripeChargeAllOf = {
1871
1873
  Amount?: number;
1872
1874
  AmountCaptured?: number;
1873
1875
  AmountRefunded?: number;
1876
+ /** @nullable */
1877
+ ApplicationFeeAmount?: number | null;
1878
+ /**
1879
+ * @maxLength 255
1880
+ * @nullable
1881
+ */
1882
+ ApplicationFeeId?: string | null;
1874
1883
  Captured?: boolean;
1875
1884
  /**
1876
1885
  * @maxLength 3
@@ -4924,6 +4933,12 @@ export interface ActivityCriteria {
4924
4933
  ActivityTypes?: string[] | null;
4925
4934
  }
4926
4935
 
4936
+ export interface CollectionMetadata {
4937
+ limit?: number;
4938
+ offset?: number;
4939
+ total?: number;
4940
+ }
4941
+
4927
4942
  /**
4928
4943
  * @nullable
4929
4944
  */
@@ -5427,6 +5442,8 @@ export type AccountWebhookEntityStripeSubscriptionsItem = {
5427
5442
  StripeId?: string | null;
5428
5443
  IsLivemode?: boolean;
5429
5444
  /** @nullable */
5445
+ ApplicationFeePercent?: number | null;
5446
+ /** @nullable */
5430
5447
  CancelAt?: string | null;
5431
5448
  CancelAtPeriodEnd?: boolean;
5432
5449
  /**
@@ -7073,6 +7090,8 @@ export type AccountWebhookEntityPrimaryStripeSubscription = {
7073
7090
  StripeId?: string | null;
7074
7091
  IsLivemode?: boolean;
7075
7092
  /** @nullable */
7093
+ ApplicationFeePercent?: number | null;
7094
+ /** @nullable */
7076
7095
  CancelAt?: string | null;
7077
7096
  CancelAtPeriodEnd?: boolean;
7078
7097
  /**
@@ -8971,6 +8990,32 @@ export type DiscordUserRemovedFromServerWebhookPayloadAllOf = {
8971
8990
 
8972
8991
  export type DiscordUserRemovedFromServerWebhookPayload = PersonWebhookEntity & DiscordUserRemovedFromServerWebhookPayloadAllOf;
8973
8992
 
8993
+ /**
8994
+ * Maximum number of records per page.
8995
+ */
8996
+ export type LimitParameter = number;
8997
+
8998
+ /**
8999
+ * Zero-based page index.
9000
+ */
9001
+ export type OffsetParameter = number;
9002
+
9003
+ export type DefinitionGetAllDefinitionsParams = {
9004
+ /**
9005
+ * Maximum number of records per page.
9006
+ */
9007
+ limit?: LimitParameter;
9008
+ /**
9009
+ * Zero-based page index.
9010
+ */
9011
+ offset?: OffsetParameter;
9012
+ };
9013
+
9014
+ export type DefinitionGetAllDefinitions200 = {
9015
+ metadata?: CollectionMetadata;
9016
+ items?: Definition[];
9017
+ };
9018
+
8974
9019
  export type AuthGetTokenParams = {
8975
9020
  /**
8976
9021
  * @nullable
@@ -9040,6 +9085,11 @@ q?: string | null;
9040
9085
  tagUid?: string | null;
9041
9086
  };
9042
9087
 
9088
+ export type CaseGetAllCases200 = {
9089
+ metadata?: CollectionMetadata;
9090
+ items?: Case[];
9091
+ };
9092
+
9043
9093
  export type CaseAddCaseParams = {
9044
9094
  /**
9045
9095
  * Indicates whether an automatic message is sent that the ticket has been created.
@@ -9061,11 +9111,48 @@ export type ArticleGetAllArticlesParams = {
9061
9111
  q?: string | null;
9062
9112
  };
9063
9113
 
9114
+ export type ArticleGetAllArticles200 = {
9115
+ metadata?: CollectionMetadata;
9116
+ items?: Article[];
9117
+ };
9118
+
9064
9119
  /**
9065
9120
  * @nullable
9066
9121
  */
9067
9122
  export type ArticleAddArticleBody = Article | null;
9068
9123
 
9124
+ export type CategoryGetAllCategoriesParams = {
9125
+ /**
9126
+ * Maximum number of records per page.
9127
+ */
9128
+ limit?: LimitParameter;
9129
+ /**
9130
+ * Zero-based page index.
9131
+ */
9132
+ offset?: OffsetParameter;
9133
+ };
9134
+
9135
+ export type CategoryGetAllCategories200 = {
9136
+ metadata?: CollectionMetadata;
9137
+ items?: Category[];
9138
+ };
9139
+
9140
+ export type DripCampaignGetAllDripCampaignsParams = {
9141
+ /**
9142
+ * Maximum number of records per page.
9143
+ */
9144
+ limit?: LimitParameter;
9145
+ /**
9146
+ * Zero-based page index.
9147
+ */
9148
+ offset?: OffsetParameter;
9149
+ };
9150
+
9151
+ export type DripCampaignGetAllDripCampaigns200 = {
9152
+ metadata?: CollectionMetadata;
9153
+ items?: DripCampaign[];
9154
+ };
9155
+
9069
9156
  /**
9070
9157
  * @nullable
9071
9158
  */
@@ -9091,6 +9178,22 @@ export type DripCampaignUpdateDripCampaignMessageBody = DripCampaignMessage | nu
9091
9178
  */
9092
9179
  export type DripCampaignSendTestCampaignEmailBody = SendTestEmailRequest | null;
9093
9180
 
9181
+ export type CampaignGetAllBroadcastEmailsParams = {
9182
+ /**
9183
+ * Maximum number of records per page.
9184
+ */
9185
+ limit?: LimitParameter;
9186
+ /**
9187
+ * Zero-based page index.
9188
+ */
9189
+ offset?: OffsetParameter;
9190
+ };
9191
+
9192
+ export type CampaignGetAllBroadcastEmails200 = {
9193
+ metadata?: CollectionMetadata;
9194
+ items?: BroadcastCampaign[];
9195
+ };
9196
+
9094
9197
  /**
9095
9198
  * @nullable
9096
9199
  */
@@ -9114,6 +9217,11 @@ export type EmailListGetAllSubscriptionsParams = {
9114
9217
  q?: string | null;
9115
9218
  };
9116
9219
 
9220
+ export type EmailListGetAllSubscriptions200 = {
9221
+ metadata?: CollectionMetadata;
9222
+ items?: EmailListPerson[];
9223
+ };
9224
+
9117
9225
  /**
9118
9226
  * @nullable
9119
9227
  */
@@ -9132,6 +9240,11 @@ ownerUid?: string | null;
9132
9240
  q?: string | null;
9133
9241
  };
9134
9242
 
9243
+ export type DealGetAllDeals200 = {
9244
+ metadata?: CollectionMetadata;
9245
+ items?: Deal[];
9246
+ };
9247
+
9135
9248
  /**
9136
9249
  * @nullable
9137
9250
  */
@@ -9155,6 +9268,11 @@ segmentUid?: string | null;
9155
9268
  q?: string | null;
9156
9269
  };
9157
9270
 
9271
+ export type AccountGetAllAccounts200 = {
9272
+ metadata?: CollectionMetadata;
9273
+ items?: Account[];
9274
+ };
9275
+
9158
9276
  export type AccountAddAccountParams = {
9159
9277
  isImported?: boolean;
9160
9278
  };
@@ -9197,6 +9315,11 @@ export type PersonGetAllPeopleParams = {
9197
9315
  q?: string | null;
9198
9316
  };
9199
9317
 
9318
+ export type PersonGetAllPeople200 = {
9319
+ metadata?: CollectionMetadata;
9320
+ items?: Person[];
9321
+ };
9322
+
9200
9323
  /**
9201
9324
  * @nullable
9202
9325
  */
@@ -9242,6 +9365,11 @@ q?: string | null;
9242
9365
  planUid?: string | null;
9243
9366
  };
9244
9367
 
9368
+ export type DiscountCouponGetAllDiscountCoupons200 = {
9369
+ metadata?: CollectionMetadata;
9370
+ items?: DiscountCoupon[];
9371
+ };
9372
+
9245
9373
  /**
9246
9374
  * @nullable
9247
9375
  */
@@ -9265,11 +9393,32 @@ q?: string | null;
9265
9393
  isActive?: boolean | null;
9266
9394
  };
9267
9395
 
9396
+ export type DiscountCouponGetDiscountCouponRedemptions200 = {
9397
+ metadata?: CollectionMetadata;
9398
+ items?: DiscountCouponSubscription[];
9399
+ };
9400
+
9268
9401
  /**
9269
9402
  * @nullable
9270
9403
  */
9271
9404
  export type UsageAddUsageBody = Usage | null;
9272
9405
 
9406
+ export type TransactionsGetAllTransactionsByAccountIdParams = {
9407
+ /**
9408
+ * Maximum number of records per page.
9409
+ */
9410
+ limit?: LimitParameter;
9411
+ /**
9412
+ * Zero-based page index.
9413
+ */
9414
+ offset?: OffsetParameter;
9415
+ };
9416
+
9417
+ export type TransactionsGetAllTransactionsByAccountId200 = {
9418
+ metadata?: CollectionMetadata;
9419
+ items?: Transaction[];
9420
+ };
9421
+
9273
9422
  /**
9274
9423
  * @nullable
9275
9424
  */
@@ -9288,6 +9437,11 @@ export type SubscriptionAddOnGetAllSubscriptionsAddOnsParams = {
9288
9437
  status?: string | null;
9289
9438
  };
9290
9439
 
9440
+ export type SubscriptionAddOnGetAllSubscriptionsAddOns200 = {
9441
+ metadata?: CollectionMetadata;
9442
+ items?: SubscriptionAddOn[];
9443
+ };
9444
+
9291
9445
  /**
9292
9446
  * @nullable
9293
9447
  */
@@ -9303,6 +9457,26 @@ export type SubscriptionAddOnAddSubscriptionAddOnPreviewBody = SubscriptionAddOn
9303
9457
  */
9304
9458
  export type SubscriptionAddOnSetAddOnUpgradeRequiredBody = SubscriptionAddOn | null;
9305
9459
 
9460
+ export type InvoiceGetAllInvoicesParams = {
9461
+ /**
9462
+ * Maximum number of records per page.
9463
+ */
9464
+ limit?: LimitParameter;
9465
+ /**
9466
+ * Zero-based page index.
9467
+ */
9468
+ offset?: OffsetParameter;
9469
+ /**
9470
+ * The invoice Uid to omit from the result set.
9471
+ */
9472
+ excludeInvoiceUid?: string;
9473
+ };
9474
+
9475
+ export type InvoiceGetAllInvoices200 = {
9476
+ metadata?: CollectionMetadata;
9477
+ items?: Invoice[];
9478
+ };
9479
+
9306
9480
  /**
9307
9481
  * @nullable
9308
9482
  */
@@ -9326,6 +9500,11 @@ current?: string | null;
9326
9500
  status?: string | null;
9327
9501
  };
9328
9502
 
9503
+ export type SubscriptionGetAllSubscriptions200 = {
9504
+ metadata?: CollectionMetadata;
9505
+ items?: Subscription[];
9506
+ };
9507
+
9329
9508
  /**
9330
9509
  * @nullable
9331
9510
  */
@@ -9375,6 +9554,22 @@ startImmediately?: string | null;
9375
9554
  */
9376
9555
  export type SubscriptionChangeSubscriptionBody = Subscription | null;
9377
9556
 
9557
+ export type PlanGetAllPlansParams = {
9558
+ /**
9559
+ * Maximum number of records per page.
9560
+ */
9561
+ limit?: LimitParameter;
9562
+ /**
9563
+ * Zero-based page index.
9564
+ */
9565
+ offset?: OffsetParameter;
9566
+ };
9567
+
9568
+ export type PlanGetAllPlans200 = {
9569
+ metadata?: CollectionMetadata;
9570
+ items?: Plan[];
9571
+ };
9572
+
9378
9573
  /**
9379
9574
  * @nullable
9380
9575
  */
@@ -9385,6 +9580,22 @@ export type PlanAddPlanBody = Plan | null;
9385
9580
  */
9386
9581
  export type PlanUpdatePlanBody = Plan | null;
9387
9582
 
9583
+ export type PlanFamilyGetAllPlanFamiliesParams = {
9584
+ /**
9585
+ * Maximum number of records per page.
9586
+ */
9587
+ limit?: LimitParameter;
9588
+ /**
9589
+ * Zero-based page index.
9590
+ */
9591
+ offset?: OffsetParameter;
9592
+ };
9593
+
9594
+ export type PlanFamilyGetAllPlanFamilies200 = {
9595
+ metadata?: CollectionMetadata;
9596
+ items?: PlanFamily[];
9597
+ };
9598
+
9388
9599
  /**
9389
9600
  * @nullable
9390
9601
  */
@@ -9414,6 +9625,11 @@ EntityType?: string | null;
9414
9625
  EntityUid?: string | null;
9415
9626
  };
9416
9627
 
9628
+ export type ActivityGetAll200 = {
9629
+ metadata?: CollectionMetadata;
9630
+ items?: Activity[];
9631
+ };
9632
+
9417
9633
  /**
9418
9634
  * @nullable
9419
9635
  */
@@ -16,13 +16,16 @@ import type {
16
16
  import type {
17
17
  Article,
18
18
  ArticleAddArticleBody,
19
+ ArticleGetAllArticles200,
19
20
  ArticleGetAllArticlesParams,
20
21
  Case,
21
22
  CaseAddCaseBody,
22
23
  CaseAddCaseParams,
24
+ CaseGetAllCases200,
23
25
  CaseGetAllCasesParams,
24
26
  CaseHistory,
25
- Category
27
+ CategoryGetAllCategories200,
28
+ CategoryGetAllCategoriesParams
26
29
  } from '../outsetaAPI.schemas';
27
30
 
28
31
  import { customFetch } from '../../mutator';
@@ -71,7 +74,7 @@ export const caseGetAllCases = (
71
74
  ) => {
72
75
 
73
76
 
74
- return customFetch<Case[]>(
77
+ return customFetch<CaseGetAllCases200>(
75
78
  {url: `/api/v1/support/cases`, method: 'GET',
76
79
  params, signal
77
80
  },
@@ -400,7 +403,7 @@ export const articleGetAllArticles = (
400
403
  ) => {
401
404
 
402
405
 
403
- return customFetch<Article[]>(
406
+ return customFetch<ArticleGetAllArticles200>(
404
407
  {url: `/api/v1/support/articles`, method: 'GET',
405
408
  params, signal
406
409
  },
@@ -596,13 +599,14 @@ export function useArticleGetArticle<TData = Awaited<ReturnType<typeof articleGe
596
599
  * @summary Retrieve all knowledge base categories.
597
600
  */
598
601
  export const categoryGetAllCategories = (
599
-
602
+ params?: CategoryGetAllCategoriesParams,
600
603
  options?: SecondParameter<typeof customFetch>,signal?: AbortSignal
601
604
  ) => {
602
605
 
603
606
 
604
- return customFetch<Category[]>(
605
- {url: `/api/v1/support/categories`, method: 'GET', signal
607
+ return customFetch<CategoryGetAllCategories200>(
608
+ {url: `/api/v1/support/categories`, method: 'GET',
609
+ params, signal
606
610
  },
607
611
  options);
608
612
  }
@@ -610,23 +614,23 @@ export const categoryGetAllCategories = (
610
614
 
611
615
 
612
616
 
613
- export const getCategoryGetAllCategoriesQueryKey = () => {
617
+ export const getCategoryGetAllCategoriesQueryKey = (params?: CategoryGetAllCategoriesParams,) => {
614
618
  return [
615
- `/api/v1/support/categories`
619
+ `/api/v1/support/categories`, ...(params ? [params]: [])
616
620
  ] as const;
617
621
  }
618
622
 
619
623
 
620
- export const getCategoryGetAllCategoriesQueryOptions = <TData = Awaited<ReturnType<typeof categoryGetAllCategories>>, TError = unknown>( options?: { query?:UseQueryOptions<Awaited<ReturnType<typeof categoryGetAllCategories>>, TError, TData>, request?: SecondParameter<typeof customFetch>}
624
+ export const getCategoryGetAllCategoriesQueryOptions = <TData = Awaited<ReturnType<typeof categoryGetAllCategories>>, TError = unknown>(params?: CategoryGetAllCategoriesParams, options?: { query?:UseQueryOptions<Awaited<ReturnType<typeof categoryGetAllCategories>>, TError, TData>, request?: SecondParameter<typeof customFetch>}
621
625
  ) => {
622
626
 
623
627
  const {query: queryOptions, request: requestOptions} = options ?? {};
624
628
 
625
- const queryKey = queryOptions?.queryKey ?? getCategoryGetAllCategoriesQueryKey();
629
+ const queryKey = queryOptions?.queryKey ?? getCategoryGetAllCategoriesQueryKey(params);
626
630
 
627
631
 
628
632
 
629
- const queryFn: QueryFunction<Awaited<ReturnType<typeof categoryGetAllCategories>>> = ({ signal }) => categoryGetAllCategories(requestOptions, signal);
633
+ const queryFn: QueryFunction<Awaited<ReturnType<typeof categoryGetAllCategories>>> = ({ signal }) => categoryGetAllCategories(params, requestOptions, signal);
630
634
 
631
635
 
632
636
 
@@ -644,11 +648,11 @@ export type CategoryGetAllCategoriesQueryError = unknown
644
648
  */
645
649
 
646
650
  export function useCategoryGetAllCategories<TData = Awaited<ReturnType<typeof categoryGetAllCategories>>, TError = unknown>(
647
- options?: { query?:UseQueryOptions<Awaited<ReturnType<typeof categoryGetAllCategories>>, TError, TData>, request?: SecondParameter<typeof customFetch>}
651
+ params?: CategoryGetAllCategoriesParams, options?: { query?:UseQueryOptions<Awaited<ReturnType<typeof categoryGetAllCategories>>, TError, TData>, request?: SecondParameter<typeof customFetch>}
648
652
 
649
653
  ): UseQueryResult<TData, TError> & { queryKey: QueryKey } {
650
654
 
651
- const queryOptions = getCategoryGetAllCategoriesQueryOptions(options)
655
+ const queryOptions = getCategoryGetAllCategoriesQueryOptions(params,options)
652
656
 
653
657
  const query = useQuery(queryOptions) as UseQueryResult<TData, TError> & { queryKey: QueryKey };
654
658