feat: run content generation on Kyma API - #3
Merged
Merged
Conversation
The write and image routes now call Claude Sonnet 4.6 through Kyma's Anthropic-compatible endpoint, so the app needs one KYMA_API_KEY instead of an Anthropic key. The SDK calls are unchanged: only the client base URL, the key, and the model id move. Brave Search still powers the research step. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01JjoE3dRyR4WnS3zjGkAAgS
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
The Write and Generate Image steps call Claude Sonnet 4.6 through Kyma API's Anthropic-compatible endpoint instead of calling Anthropic directly.
src/app/api/write/route.tsnew Anthropic()→new Anthropic({ baseURL: "https://kymaapi.com", apiKey: process.env.KYMA_API_KEY }), modelclaude-sonnet-4-6src/app/api/image/route.ts.env.example,README.mdANTHROPIC_API_KEY→KYMA_API_KEY, setup text and the Deploy button updatedBrave Search in
src/app/api/research/route.tsis unchanged.Why
The live demo stalls at "Generating..." on step 4. Research works, and the write and image routes validate input correctly, so the failure is in the model call.
Verified
KYMA_API_KEYis set on the Vercel project in Production, using a dedicated key namedcontent-pipeline-demo.https://kymaapi.com/v1/messageswith that key andclaude-sonnet-4-6returns a completion.npx tsc --noEmitpasses.After merge, run all four steps on the live demo and confirm step 4 produces text.
🤖 Generated with Claude Code
https://claude.ai/code/session_01JjoE3dRyR4WnS3zjGkAAgS