@appconda/nextjs 1.0.61 → 1.0.63

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.
@@ -43,3 +43,15 @@ export declare const CreateWaitlistSignup: import("next-safe-action").SafeAction
43
43
  waitlistId?: string[];
44
44
  };
45
45
  }, readonly [], WaitlistSignup>;
46
+ export declare const CreateWaitlistOffboardedSignup: import("next-safe-action").SafeActionFn<string, import("zod").ZodObject<{
47
+ waitlistSignupId: import("zod").ZodString;
48
+ }, "strip", import("zod").ZodTypeAny, {
49
+ waitlistSignupId?: string;
50
+ }, {
51
+ waitlistSignupId?: string;
52
+ }>, readonly [], {
53
+ formErrors: string[];
54
+ fieldErrors: {
55
+ waitlistSignupId?: string[];
56
+ };
57
+ }, readonly [], WaitlistSignup>;
@@ -2,7 +2,7 @@
2
2
  import { actionClient } from '../../actions/actionClient';
3
3
  import { getSDKForCurrentUser } from '../../getSDKForCurrentUser';
4
4
  import { getSDKForService } from '../../getSDKForService';
5
- import { CreateWaitlistSchema, CreateWaitlistSignupSchema, ListWaitlistSignupsSchema } from "./schema";
5
+ import { CreateWaitlistOffboardedSignupSchema, CreateWaitlistSchema, CreateWaitlistSignupSchema, ListWaitlistSignupsSchema } from "./schema";
6
6
  export const ListWaitlistSignups = actionClient
7
7
  .schema(ListWaitlistSignupsSchema)
8
8
  .action(async ({ parsedInput }) => {
@@ -51,3 +51,15 @@ export const CreateWaitlistSignup = actionClient
51
51
  throw new Error('Failed to fetch ListWaitlists');
52
52
  }
53
53
  });
54
+ export const CreateWaitlistOffboardedSignup = actionClient
55
+ .schema(CreateWaitlistOffboardedSignupSchema)
56
+ .action(async ({ parsedInput }) => {
57
+ try {
58
+ const { waitlist } = await getSDKForService();
59
+ return await waitlist.CreateWaitlistOffboardedSignup(parsedInput);
60
+ }
61
+ catch (error) {
62
+ console.error('Error in ListWaitlists:', error);
63
+ throw new Error('Failed to fetch ListWaitlists');
64
+ }
65
+ });
@@ -23,3 +23,10 @@ export declare const CreateWaitlistSignupSchema: z.ZodObject<{
23
23
  email?: string;
24
24
  waitlistId?: string;
25
25
  }>;
26
+ export declare const CreateWaitlistOffboardedSignupSchema: z.ZodObject<{
27
+ waitlistSignupId: z.ZodString;
28
+ }, "strip", z.ZodTypeAny, {
29
+ waitlistSignupId?: string;
30
+ }, {
31
+ waitlistSignupId?: string;
32
+ }>;
@@ -9,3 +9,6 @@ export const CreateWaitlistSignupSchema = z.object({
9
9
  waitlistId: z.string(),
10
10
  email: z.string()
11
11
  });
12
+ export const CreateWaitlistOffboardedSignupSchema = z.object({
13
+ waitlistSignupId: z.string(),
14
+ });
@@ -1,11 +1,12 @@
1
1
  import z from "zod";
2
2
  import { ServiceClient } from "../../service-client";
3
3
  import { Waitlist, WaitlistSignup } from "./types";
4
- import { CreateWaitlistSchema, CreateWaitlistSignupSchema } from "./schema";
4
+ import { CreateWaitlistOffboardedSignupSchema, CreateWaitlistSchema, CreateWaitlistSignupSchema } from "./schema";
5
5
  export declare class WaitlistService extends ServiceClient {
6
6
  protected getServiceName(): string;
7
7
  ListWiatlistSignups(waitlistId: string): Promise<any[]>;
8
8
  ListWaitlists(): Promise<any[]>;
9
9
  CreateWaitlist(payload: z.infer<typeof CreateWaitlistSchema>): Promise<Waitlist>;
10
10
  CreateWaitlistSignup(payload: z.infer<typeof CreateWaitlistSignupSchema>): Promise<WaitlistSignup>;
11
+ CreateWaitlistOffboardedSignup(payload: z.infer<typeof CreateWaitlistOffboardedSignupSchema>): Promise<WaitlistSignup>;
11
12
  }
@@ -18,4 +18,7 @@ export class WaitlistService extends ServiceClient {
18
18
  async CreateWaitlistSignup(payload) {
19
19
  return await this.actionCall('CreateWaitlistSignup', payload);
20
20
  }
21
+ async CreateWaitlistOffboardedSignup(payload) {
22
+ return await this.actionCall('CreateWaitlistOffboardedSignup', payload);
23
+ }
21
24
  }
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "@appconda/nextjs",
3
3
  "homepage": "https://appconda.io/support",
4
4
  "description": "Appconda is an open-source self-hosted backend server that abstract and simplify complex and repetitive development tasks behind a very simple REST API",
5
- "version": "1.0.61",
5
+ "version": "1.0.63",
6
6
  "license": "BSD-3-Clause",
7
7
  "main": "dist/index.js",
8
8
  "types": "dist/index.d.ts",
@@ -4,7 +4,7 @@
4
4
  import { actionClient } from '../../actions/actionClient';
5
5
  import { getSDKForCurrentUser } from '../../getSDKForCurrentUser';
6
6
  import { getSDKForService } from '../../getSDKForService';
7
- import { CreateWaitlistSchema, CreateWaitlistSignupSchema, ListWaitlistSignupsSchema } from "./schema";
7
+ import { CreateWaitlistOffboardedSignupSchema, CreateWaitlistSchema, CreateWaitlistSignupSchema, ListWaitlistSignupsSchema } from "./schema";
8
8
  import { Waitlist, WaitlistSignup } from './types';
9
9
 
10
10
 
@@ -63,3 +63,17 @@ export const CreateWaitlistSignup = actionClient
63
63
  throw new Error('Failed to fetch ListWaitlists');
64
64
  }
65
65
  });
66
+
67
+ export const CreateWaitlistOffboardedSignup = actionClient
68
+ .schema(CreateWaitlistOffboardedSignupSchema)
69
+ .action(async ({ parsedInput }): Promise<WaitlistSignup> => {
70
+ try {
71
+
72
+ const { waitlist } = await getSDKForService();
73
+ return await waitlist.CreateWaitlistOffboardedSignup(parsedInput);
74
+
75
+ } catch (error) {
76
+ console.error('Error in ListWaitlists:', error);
77
+ throw new Error('Failed to fetch ListWaitlists');
78
+ }
79
+ });
@@ -12,4 +12,9 @@ export const CreateWaitlistSchema = z.object({
12
12
  export const CreateWaitlistSignupSchema = z.object({
13
13
  waitlistId: z.string(),
14
14
  email: z.string()
15
+ });
16
+
17
+
18
+ export const CreateWaitlistOffboardedSignupSchema = z.object({
19
+ waitlistSignupId: z.string(),
15
20
  });
@@ -3,7 +3,7 @@ import z from "zod";
3
3
  import { Payload } from "../../client";
4
4
  import { ServiceClient } from "../../service-client";
5
5
  import { Waitlist, WaitlistSignup } from "./types";
6
- import { CreateWaitlistSchema, CreateWaitlistSignupSchema } from "./schema";
6
+ import { CreateWaitlistOffboardedSignupSchema, CreateWaitlistSchema, CreateWaitlistSignupSchema } from "./schema";
7
7
 
8
8
  export class WaitlistService extends ServiceClient {
9
9
  protected getServiceName(): string {
@@ -29,4 +29,8 @@ export class WaitlistService extends ServiceClient {
29
29
  return await this.actionCall('CreateWaitlistSignup', payload);
30
30
  }
31
31
 
32
+ public async CreateWaitlistOffboardedSignup(payload: z.infer<typeof CreateWaitlistOffboardedSignupSchema>): Promise<WaitlistSignup> {
33
+ return await this.actionCall('CreateWaitlistOffboardedSignup', payload);
34
+ }
35
+
32
36
  }