@outseta/react 0.5.8 → 0.5.10
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.js +23 -0
- package/package.json +2 -2
- package/src/generated/email/email.ts +65 -1
- package/src/generated/outsetaAPI.schemas.ts +21 -0
package/dist/index.js
CHANGED
|
@@ -4018,6 +4018,26 @@ var useCampaignArchiveBroadcastCampaign = (options) => {
|
|
|
4018
4018
|
const mutationOptions = getCampaignArchiveBroadcastCampaignMutationOptions(options);
|
|
4019
4019
|
return useMutation(mutationOptions);
|
|
4020
4020
|
};
|
|
4021
|
+
var campaignUnarchiveBroadcastCampaign = (broadcastCampaignUid, options, signal) => {
|
|
4022
|
+
return customFetch2({
|
|
4023
|
+
url: `/api/v1/email/campaigns/broadcasts/${broadcastCampaignUid}/unarchive`,
|
|
4024
|
+
method: "POST",
|
|
4025
|
+
signal
|
|
4026
|
+
}, options);
|
|
4027
|
+
};
|
|
4028
|
+
var getCampaignUnarchiveBroadcastCampaignMutationOptions = (options) => {
|
|
4029
|
+
const mutationKey = ["campaignUnarchiveBroadcastCampaign"];
|
|
4030
|
+
const { mutation: mutationOptions, request: requestOptions } = options ? options.mutation && "mutationKey" in options.mutation && options.mutation.mutationKey ? options : { ...options, mutation: { ...options.mutation, mutationKey } } : { mutation: { mutationKey }, request: undefined };
|
|
4031
|
+
const mutationFn = (props) => {
|
|
4032
|
+
const { broadcastCampaignUid } = props ?? {};
|
|
4033
|
+
return campaignUnarchiveBroadcastCampaign(broadcastCampaignUid, requestOptions);
|
|
4034
|
+
};
|
|
4035
|
+
return { mutationFn, ...mutationOptions };
|
|
4036
|
+
};
|
|
4037
|
+
var useCampaignUnarchiveBroadcastCampaign = (options) => {
|
|
4038
|
+
const mutationOptions = getCampaignUnarchiveBroadcastCampaignMutationOptions(options);
|
|
4039
|
+
return useMutation(mutationOptions);
|
|
4040
|
+
};
|
|
4021
4041
|
var campaignSendTestCampaignEmail = (campaignSendTestCampaignEmailBody, options, signal) => {
|
|
4022
4042
|
return customFetch2({
|
|
4023
4043
|
url: `/api/v1/email/campaigns/broadcasts/sendtestemail`,
|
|
@@ -5378,6 +5398,7 @@ export {
|
|
|
5378
5398
|
campaignRemoveTagFromEntity,
|
|
5379
5399
|
campaignSendTestCampaignEmail,
|
|
5380
5400
|
campaignSetTagsForEntity,
|
|
5401
|
+
campaignUnarchiveBroadcastCampaign,
|
|
5381
5402
|
campaignUnscheduleBroadcastEmail,
|
|
5382
5403
|
campaignUpdateBroadcastEmail,
|
|
5383
5404
|
caseAddCase,
|
|
@@ -5461,6 +5482,7 @@ export {
|
|
|
5461
5482
|
getCampaignRemoveTagFromEntityMutationOptions,
|
|
5462
5483
|
getCampaignSendTestCampaignEmailMutationOptions,
|
|
5463
5484
|
getCampaignSetTagsForEntityMutationOptions,
|
|
5485
|
+
getCampaignUnarchiveBroadcastCampaignMutationOptions,
|
|
5464
5486
|
getCampaignUnscheduleBroadcastEmailMutationOptions,
|
|
5465
5487
|
getCampaignUpdateBroadcastEmailMutationOptions,
|
|
5466
5488
|
getCaseAddCaseMutationOptions,
|
|
@@ -5790,6 +5812,7 @@ export {
|
|
|
5790
5812
|
useCampaignRemoveTagFromEntity,
|
|
5791
5813
|
useCampaignSendTestCampaignEmail,
|
|
5792
5814
|
useCampaignSetTagsForEntity,
|
|
5815
|
+
useCampaignUnarchiveBroadcastCampaign,
|
|
5793
5816
|
useCampaignUnscheduleBroadcastEmail,
|
|
5794
5817
|
useCampaignUpdateBroadcastEmail,
|
|
5795
5818
|
useCaseAddCase,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@outseta/react",
|
|
3
|
-
"version": "0.5.
|
|
3
|
+
"version": "0.5.10",
|
|
4
4
|
"description": "React hooks and components for the Outseta API",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"repository": {
|
|
@@ -18,7 +18,7 @@
|
|
|
18
18
|
}
|
|
19
19
|
},
|
|
20
20
|
"dependencies": {
|
|
21
|
-
"@outseta/api-client": "0.4.
|
|
21
|
+
"@outseta/api-client": "0.4.10"
|
|
22
22
|
},
|
|
23
23
|
"peerDependencies": {
|
|
24
24
|
"react": "^18.0.0 || ^19.0.0"
|
|
@@ -754,7 +754,7 @@ export const useDripCampaignSendTestCampaignEmail = <TError = void,
|
|
|
754
754
|
return useMutation(mutationOptions);
|
|
755
755
|
}
|
|
756
756
|
/**
|
|
757
|
-
* Archived broadcasts are excluded.
|
|
757
|
+
* Archived broadcasts are excluded unless the Status filter asks for them (Status=10).
|
|
758
758
|
* @summary Retrieve all broadcasts.
|
|
759
759
|
*/
|
|
760
760
|
export const campaignGetAllBroadcastEmails = (
|
|
@@ -1269,6 +1269,70 @@ export const useCampaignArchiveBroadcastCampaign = <TError = void,
|
|
|
1269
1269
|
return useMutation(mutationOptions);
|
|
1270
1270
|
}
|
|
1271
1271
|
/**
|
|
1272
|
+
* The broadcast's status becomes Sent if it sent any emails, and Draft otherwise.
|
|
1273
|
+
Unarchiving never resumes sending.
|
|
1274
|
+
* @summary Unarchive a broadcast.
|
|
1275
|
+
*/
|
|
1276
|
+
export const campaignUnarchiveBroadcastCampaign = (
|
|
1277
|
+
broadcastCampaignUid: string | null,
|
|
1278
|
+
options?: SecondParameter<typeof customFetch>,signal?: AbortSignal
|
|
1279
|
+
) => {
|
|
1280
|
+
|
|
1281
|
+
|
|
1282
|
+
return customFetch<BroadcastCampaign>(
|
|
1283
|
+
{url: `/api/v1/email/campaigns/broadcasts/${broadcastCampaignUid}/unarchive`, method: 'POST', signal
|
|
1284
|
+
},
|
|
1285
|
+
options);
|
|
1286
|
+
}
|
|
1287
|
+
|
|
1288
|
+
|
|
1289
|
+
|
|
1290
|
+
export const getCampaignUnarchiveBroadcastCampaignMutationOptions = <TError = void,
|
|
1291
|
+
TContext = unknown>(options?: { mutation?:UseMutationOptions<Awaited<ReturnType<typeof campaignUnarchiveBroadcastCampaign>>, TError,{broadcastCampaignUid: string | null}, TContext>, request?: SecondParameter<typeof customFetch>}
|
|
1292
|
+
): UseMutationOptions<Awaited<ReturnType<typeof campaignUnarchiveBroadcastCampaign>>, TError,{broadcastCampaignUid: string | null}, TContext> => {
|
|
1293
|
+
|
|
1294
|
+
const mutationKey = ['campaignUnarchiveBroadcastCampaign'];
|
|
1295
|
+
const {mutation: mutationOptions, request: requestOptions} = options ?
|
|
1296
|
+
options.mutation && 'mutationKey' in options.mutation && options.mutation.mutationKey ?
|
|
1297
|
+
options
|
|
1298
|
+
: {...options, mutation: {...options.mutation, mutationKey}}
|
|
1299
|
+
: {mutation: { mutationKey, }, request: undefined};
|
|
1300
|
+
|
|
1301
|
+
|
|
1302
|
+
|
|
1303
|
+
|
|
1304
|
+
const mutationFn: MutationFunction<Awaited<ReturnType<typeof campaignUnarchiveBroadcastCampaign>>, {broadcastCampaignUid: string | null}> = (props) => {
|
|
1305
|
+
const {broadcastCampaignUid} = props ?? {};
|
|
1306
|
+
|
|
1307
|
+
return campaignUnarchiveBroadcastCampaign(broadcastCampaignUid,requestOptions)
|
|
1308
|
+
}
|
|
1309
|
+
|
|
1310
|
+
|
|
1311
|
+
|
|
1312
|
+
|
|
1313
|
+
return { mutationFn, ...mutationOptions }}
|
|
1314
|
+
|
|
1315
|
+
export type CampaignUnarchiveBroadcastCampaignMutationResult = NonNullable<Awaited<ReturnType<typeof campaignUnarchiveBroadcastCampaign>>>
|
|
1316
|
+
|
|
1317
|
+
export type CampaignUnarchiveBroadcastCampaignMutationError = void
|
|
1318
|
+
|
|
1319
|
+
/**
|
|
1320
|
+
* @summary Unarchive a broadcast.
|
|
1321
|
+
*/
|
|
1322
|
+
export const useCampaignUnarchiveBroadcastCampaign = <TError = void,
|
|
1323
|
+
TContext = unknown>(options?: { mutation?:UseMutationOptions<Awaited<ReturnType<typeof campaignUnarchiveBroadcastCampaign>>, TError,{broadcastCampaignUid: string | null}, TContext>, request?: SecondParameter<typeof customFetch>}
|
|
1324
|
+
): UseMutationResult<
|
|
1325
|
+
Awaited<ReturnType<typeof campaignUnarchiveBroadcastCampaign>>,
|
|
1326
|
+
TError,
|
|
1327
|
+
{broadcastCampaignUid: string | null},
|
|
1328
|
+
TContext
|
|
1329
|
+
> => {
|
|
1330
|
+
|
|
1331
|
+
const mutationOptions = getCampaignUnarchiveBroadcastCampaignMutationOptions(options);
|
|
1332
|
+
|
|
1333
|
+
return useMutation(mutationOptions);
|
|
1334
|
+
}
|
|
1335
|
+
/**
|
|
1272
1336
|
* Sends to the logged-in user and optionally to additional recipients. Additional
|
|
1273
1337
|
recipients are specified as a list of person Uids and must belong to the same account
|
|
1274
1338
|
as the logged-in user.
|
|
@@ -5353,6 +5353,27 @@ export interface SetupIntent {
|
|
|
5353
5353
|
ToltReferralId?: string | null;
|
|
5354
5354
|
}
|
|
5355
5355
|
|
|
5356
|
+
/**
|
|
5357
|
+
* Request body for POST /api/v1/billing/paymentinformation/complete: the client
|
|
5358
|
+
secret of the Stripe intent the user confirmed.
|
|
5359
|
+
*/
|
|
5360
|
+
export interface PaymentInformationCompleteRequest {
|
|
5361
|
+
/** @nullable */
|
|
5362
|
+
ClientSecret?: string | null;
|
|
5363
|
+
}
|
|
5364
|
+
|
|
5365
|
+
/**
|
|
5366
|
+
* Request body for POST /api/v1/billing/paymentinformation/state: the account
|
|
5367
|
+
whose payment information is being updated, and the client secret of the Stripe
|
|
5368
|
+
intent the user is about to confirm.
|
|
5369
|
+
*/
|
|
5370
|
+
export interface PaymentInformationStateRequest {
|
|
5371
|
+
/** @nullable */
|
|
5372
|
+
AccountUid?: string | null;
|
|
5373
|
+
/** @nullable */
|
|
5374
|
+
ClientSecret?: string | null;
|
|
5375
|
+
}
|
|
5376
|
+
|
|
5356
5377
|
/**
|
|
5357
5378
|
* Request body for POST /api/v1/billing/subscriptions/changesubscription/complete:
|
|
5358
5379
|
the client secret of the Stripe intent the user confirmed.
|