Conversational App Capability APIs: From Client-Side Glue to Server-Side Integration
This article explains how conversational-app APIs are shifting from client-side glue work—search, scraping, prompt assembly, and safety—to native server-side tools. It covers the capability set, a minimal request pattern, billing caveats, hard limits, and a staged migration path for teams building retrieval-augmented chat apps.
Background: Conversational Apps as Glue Engineering
Over the past year, building a conversational bot that feels as polished as a first-party app has typically been glue work. Take web search as an example. Developers often had to:
- Call a third-party search API for raw results.
- Write scraping logic to clean HTML and drop noise.
- Design a context-assembly strategy: truncate, deduplicate, and insert results into the prompt.
- Add a safety layer for sensitive-term filtering or compliance checks on model output.
The pipeline is long, and each hop depends on a separate third-party service. More importantly, fragmented context assembly hurts how well the model uses tool results. When search snippets are dumped at the end of the conversation, the model often cannot tell which facts actually answer the current question.
The core change in this API update is that features that used to live as client-side add-ons are now native server-side capabilities, invoked via request parameters. The server owns tool routing, context assembly, and safety. Developers no longer have to build and operate that chain themselves.
How the Server Unbundles the Stack
1. Capability list
According to the official conversational-bot guide, the newly exposed capabilities fall into five groups:
- Web search: the server rewrites the query, ranks results, and extracts summaries.
- URL reading: when a user sends a URL, the server fetches page body text and strips navigation and ads.
- File input: OCR and multimodal parsing (text and tables in images).
- Voice: ASR and TTS, callable independently.
- Safety: bidirectional content review on input and output, with configurable strength.
Tool calls and context assembly run entirely on the server. From the client, response chunks already contain structured data such as search summaries, citation links, and formatted file content. The client only renders blocks; it does not need to know how content was produced.
2. Minimal integration: enable capabilities with a few fields
A simplified request based on the official chat-bot guide:
curl https://api.example.com/v1/messages \-H "Content-Type: application/json" \-H "x-api-key: ${API_KEY}" \-d '{"model": "flash-latest","thinking": {"type": "enabled"},"tools": [{"type": "web_search", "name": "web_search"},{"type": "read_url", "name": "read_url"}],"safety_check": {"level": "high"},"title": {"enabled": true},"messages": [{"role": "user", "content": "2026年AI应用开发有哪些新趋势?"}],"stream": true}'
Compared with a plain chat request, only three areas are new:
tools: native tool types to enable; multiple tools can be combined.safety_check: review strength (high/medium/off).title: auto-generate conversation titles and similar features.
3. Protocol compatibility
Officially, the three common protocol surfaces (messages, responses, and completions) all support these fields. Existing integrations do not need protocol-layer changes; they only append the corresponding JSON fields.
Teams that already run a custom tool chain should estimate migration cost. If assembly depended on heavy prompt tricks (for example few-shot examples that teach the model how to read search summaries), the new paradigm often requires less prompt engineering. The server already structures results; extra “coaching” can interfere with the model’s judgment.
Cost Model: Two Ledgers
1. Pricing structure
Billing is dual-track:
- Model side: still billed by tokens, same as ordinary chat.
- Tool side: billed by call count or duration. Search and page fetch are on the order of about 0.005 CNY per call. Speech synthesis and recognition have time-limited discounts and a relatively lower unit price after discount.
2. Hidden variable: the model decides when to call tools
Unit prices are modest, but an easy-to-miss variable is that the model chooses when and how often to invoke tools. In a complex multi-turn session it may trigger search or URL reading multiple times; add reasoning tokens, and per-turn cost is not a simple fixed number.
When budgeting, watch:
- Search trigger rate: if freshness is not critical (for example internal knowledge-base Q&A), restrict tools to explicit triggers so the model does not search every turn.
- Return length: summaries and page bodies consume context. For short answers, cap returned character size.
Teams that rely on context or semantic cache should note that enabling tools changes context structure and can lower cache hit rate, raising token spend. Establish a new cost baseline in a small-traffic canary.
3. Recommended layout: isolate tool configs by scenario
In one app, use multiple tool policies, for example:
- Basic Q&A: all tools off; pure inference to keep cache benefits.
- Time-sensitive Q&A: search on, and use the
titleparameter so the model can judge result freshness. - Document parsing: only file input and URL reading; no search, to avoid unrelated tokens.
Hard Limits: Three Boundaries
The API is convenient, but scope is explicit. Check these before integrating:
1. Model binding
Native tools currently bind only to lightweight inference models. They do not work with third-party models or privately deployed local models. If the product requires a specific fine-tuned model, keep the traditional tool chain.
2. Parameter takeover
Once tools are on, the server takes over some generation parameters:
If you declare search or URL-read tools, set safety review to high, or enable auto titles, some sampling parameters are forced by the server and client values are ignored.
Commonly overridden parameters include temperature and top_p. For low-latency, highly reproducible work (code generation, structured output), the server may lower temperature, producing more conservative style that may not match the original prompt.
3. Observability and latency
Safety and tool lookups increase end-to-end time (search, fetch, review queues). For TTFT-sensitive apps (voice assistants, live replies), benchmark separately and check tolerance.
Migration and Outlook
1. Staged rollout
- Stage 1: small live A/B. For internal knowledge Q&A, split ~5% traffic to the tool-enabled path vs. the old path; compare TTFT, tool success rate, and user feedback.
- Stage 2: recalibrate cost. From live data, tune search-trigger caps and safety strength; decide whether multi-turn internalized cache is needed.
- Stage 3: full cutover after accuracy and cost meet the bar.
2. What the shift implies
Moving from “model APIs” to “application-capability APIs” is cloud-native packaging of tool orchestration and context engineering. For smaller teams, the gain is not only less ops, but less mystique around prompt assembly: the platform absorbs the tedious stitching so developers can focus on UX.
Bottom line: if the goal is to replicate mainstream retrieval-augmented chat quickly and the team lacks infrastructure to self-host the pipeline, this paradigm is worth adopting first. If the product needs fine-grained generation control, private models, or extreme low latency, keep the self-built chain and wait for later capability upgrades.
