Skip to content

Commit 910c852

Browse files
authored
Merge pull request #43 from get-convex/seth/component-api
"legacyComponentApi": true
2 parents a6c057e + a4851a7 commit 910c852

File tree

3 files changed

+130
-17
lines changed

3 files changed

+130
-17
lines changed

convex.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,6 @@
22
"$schema": "./node_modules/convex/schemas/convex.schema.json",
33
"functions": "example/convex",
44
"codegen": {
5-
"legacyComponentApi": false
5+
"legacyComponentApi": true
66
}
77
}

example/convex/_generated/api.d.ts

Lines changed: 129 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,5 +51,133 @@ export declare const internal: FilterApi<
5151
>;
5252

5353
export declare const components: {
54-
resend: import("@convex-dev/resend/_generated/component.js").ComponentApi<"resend">;
54+
resend: {
55+
lib: {
56+
cancelEmail: FunctionReference<
57+
"mutation",
58+
"internal",
59+
{ emailId: string },
60+
null
61+
>;
62+
cleanupAbandonedEmails: FunctionReference<
63+
"mutation",
64+
"internal",
65+
{ olderThan?: number },
66+
null
67+
>;
68+
cleanupOldEmails: FunctionReference<
69+
"mutation",
70+
"internal",
71+
{ olderThan?: number },
72+
null
73+
>;
74+
createManualEmail: FunctionReference<
75+
"mutation",
76+
"internal",
77+
{
78+
from: string;
79+
headers?: Array<{ name: string; value: string }>;
80+
replyTo?: Array<string>;
81+
subject: string;
82+
to: string;
83+
},
84+
string
85+
>;
86+
get: FunctionReference<
87+
"query",
88+
"internal",
89+
{ emailId: string },
90+
{
91+
complained: boolean;
92+
createdAt: number;
93+
errorMessage?: string;
94+
finalizedAt: number;
95+
from: string;
96+
headers?: Array<{ name: string; value: string }>;
97+
html?: string;
98+
opened: boolean;
99+
replyTo: Array<string>;
100+
resendId?: string;
101+
segment: number;
102+
status:
103+
| "waiting"
104+
| "queued"
105+
| "cancelled"
106+
| "sent"
107+
| "delivered"
108+
| "delivery_delayed"
109+
| "bounced"
110+
| "failed";
111+
subject: string;
112+
text?: string;
113+
to: string;
114+
} | null
115+
>;
116+
getStatus: FunctionReference<
117+
"query",
118+
"internal",
119+
{ emailId: string },
120+
{
121+
complained: boolean;
122+
errorMessage: string | null;
123+
opened: boolean;
124+
status:
125+
| "waiting"
126+
| "queued"
127+
| "cancelled"
128+
| "sent"
129+
| "delivered"
130+
| "delivery_delayed"
131+
| "bounced"
132+
| "failed";
133+
} | null
134+
>;
135+
handleEmailEvent: FunctionReference<
136+
"mutation",
137+
"internal",
138+
{ event: any },
139+
null
140+
>;
141+
sendEmail: FunctionReference<
142+
"mutation",
143+
"internal",
144+
{
145+
from: string;
146+
headers?: Array<{ name: string; value: string }>;
147+
html?: string;
148+
options: {
149+
apiKey: string;
150+
initialBackoffMs: number;
151+
onEmailEvent?: { fnHandle: string };
152+
retryAttempts: number;
153+
testMode: boolean;
154+
};
155+
replyTo?: Array<string>;
156+
subject: string;
157+
text?: string;
158+
to: string;
159+
},
160+
string
161+
>;
162+
updateManualEmail: FunctionReference<
163+
"mutation",
164+
"internal",
165+
{
166+
emailId: string;
167+
errorMessage?: string;
168+
resendId?: string;
169+
status:
170+
| "waiting"
171+
| "queued"
172+
| "cancelled"
173+
| "sent"
174+
| "delivered"
175+
| "delivery_delayed"
176+
| "bounced"
177+
| "failed";
178+
},
179+
null
180+
>;
181+
};
182+
};
55183
};

package-lock.json

Lines changed: 0 additions & 15 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)