Hi Edward,
Good update. If the overseas platform is working now, I’d treat StepFun’s “use the overseas endpoint for overseas invocation” as the most reliable rule for direct calls.
For direct StepFun calls, yes, I would separate them like this:
China mainland / domestic StepFun account:
https://api.stepfun.com/step_plan/v1
Overseas / international StepFun account:
https://api.stepfun.ai/step_plan/v1
So for the OpenAI-compatible chat completions path, that becomes:
https://api.stepfun.com/step_plan/v1/chat/completions
https://api.stepfun.ai/step_plan/v1/chat/completions
For Vercel AI Gateway, I would think about it differently: your app’s baseURL should be the AI Gateway endpoint, not StepFun’s endpoint directly:
https://ai-gateway.vercel.sh/v1
Then you call the StepFun model through the Gateway model ID, using your AI Gateway key. BYOK means Gateway can use your provider credentials, but I would not assume you can choose api.stepfun.com vs api.stepfun.ai as the upstream route unless the Gateway UI/docs expose that option for StepFun specifically.
So my practical recommendation would be:
Need strict China/overseas endpoint control?
→ Call StepFun directly and choose .com or .ai yourself.
Want unified logging, budgets, model routing, and Gateway behavior?
→ Use Vercel AI Gateway, but test whether its StepFun route matches your region/compliance needs.
I’d run both paths with the same prompt and log only non-sensitive fields:
provider: direct-stepfun-cn / direct-stepfun-overseas / vercel-ai-gateway
vercel region: process.env.VERCEL_REGION
status code
latency
error type
request timestamp
If direct api.stepfun.ai works from Vercel but Gateway has a different failure pattern, then it’s a Gateway/provider-routing question. If Gateway works consistently, it may be the cleaner option for observability and budgets.