feat(api-client-phase10): API um project-templates erweitern [tsc:fail]

This commit is contained in:
Dennis (via Claude+Gemma) 2026-05-23 06:19:32 +02:00
parent 5b48d79516
commit 5b1f87e2b9
3 changed files with 28 additions and 16 deletions

View File

@ -1,11 +1,12 @@
{
"completed_features": [],
"current_feature": "keyboard-help-modal",
"current_feature": "api-client-phase10",
"started_at": "2026-05-23T06:10:51.530595",
"attempted_features": [
"markdown-notes-time-entry",
"customer-tags",
"project-templates",
"language-toggle"
"language-toggle",
"keyboard-help-modal"
]
}

View File

@ -1248,3 +1248,20 @@ src/index.ts(27,25): error TS2769: No overload matches this call.
Overload 2 of 3, '(plugin: FastifyPluginAsync<{ limits: { fileSize: number; }; }, RawServerDefault, FastifyTypeProvider, FastifyBaseLogger>, opts?: FastifyRegisterOptions<...> | undefined): FastifyInstance<...> & PromiseLike<...>', gave the following error.
Argument of type 'Promise<FastifyMultipartPlugin>' is not assignable to parameter of type 'FastifyPluginAsync<{ limits: { fileSize: number; }; }, RawServerDefault, FastifyTypeProvider, FastifyBaseLogger>'.
Type 'Promise<FastifyMultipartPlugin>' provides no match for the signature '(instance: FastifyInstance<RawServerDefault, IncomingMessage, ServerResponse<IncomingMessage>, FastifyBaseLogger, FastifyTy
- `06:18:47` **INFO** Committed feature keyboard-help-modal
- `06:18:47` **INFO** Pushed: rc=0
## Phase-3 Feature: api-client-phase10 (2026-05-23 06:18:47)
- `06:18:47` **INFO** Description: API um project-templates erweitern
- `06:18:47` **INFO** Generating apps/web/src/lib/api.ts (ERWEITERT — behalte ALLES. Füge: listProjectTemplates(), createProject…)
- `06:19:31` **INFO** wrote 5036 chars in 43.5s (attempt 1)
- `06:19:31` **INFO** Running tsc --noEmit on api…
- `06:19:32` **WARN** tsc errors:
src/index.ts(27,25): error TS2769: No overload matches this call.
Overload 1 of 3, '(plugin: FastifyPluginCallback<{ limits: { fileSize: number; }; }, RawServerDefault, FastifyTypeProvider, FastifyBaseLogger>, opts?: FastifyRegisterOptions<...> | undefined): FastifyInstance<...> & PromiseLike<...>', gave the following error.
Argument of type 'Promise<FastifyMultipartPlugin>' is not assignable to parameter of type 'FastifyPluginCallback<{ limits: { fileSize: number; }; }, RawServerDefault, FastifyTypeProvider, FastifyBaseLogger>'.
Type 'Promise<FastifyMultipartPlugin>' provides no match for the signature '(instance: FastifyInstance<RawServerDefault, IncomingMessage, ServerResponse<IncomingMessage>, FastifyBaseLogger, FastifyTypeProvider>, opts: { ...; }, done: (err?: Error | undefined) => void): void'.
Overload 2 of 3, '(plugin: FastifyPluginAsync<{ limits: { fileSize: number; }; }, RawServerDefault, FastifyTypeProvider, FastifyBaseLogger>, opts?: FastifyRegisterOptions<...> | undefined): FastifyInstance<...> & PromiseLike<...>', gave the following error.
Argument of type 'Promise<FastifyMultipartPlugin>' is not assignable to parameter of type 'FastifyPluginAsync<{ limits: { fileSize: number; }; }, RawServerDefault, FastifyTypeProvider, FastifyBaseLogger>'.
Type 'Promise<FastifyMultipartPlugin>' provides no match for the signature '(instance: FastifyInstance<RawServerDefault, IncomingMessage, ServerResponse<IncomingMessage>, FastifyBaseLogger, FastifyTy

View File

@ -178,33 +178,27 @@ export const api = {
})
},
async listWebhooks() {
return request<any[]>("/webhooks")
async listProjectTemplates() {
return request<any[]>("/projects/templates")
},
async createWebhook(data: { url: string; event: string }) {
return request("/webhooks", {
async createProjectTemplate(data: any) {
return request("/projects/templates", {
method: "POST",
body: JSON.stringify(data)
})
},
async updateWebhook(id: string, data: { url?: string; event?: string }) {
return request(`/webhooks/${id}`, {
async updateProjectTemplate(id: string, data: any) {
return request(`/projects/templates/${id}`, {
method: "PATCH",
body: JSON.stringify(data)
})
},
async deleteWebhook(id: string) {
return request(`/webhooks/${id}`, {
async deleteProjectTemplate(id: string) {
return request(`/projects/templates/${id}`, {
method: "DELETE"
})
},
async testWebhook(id: string) {
return request(`/webhooks/${id}/test`, {
method: "POST"
})
}
}