Skip to content

[Bug]: Web検索機能が動作しません #69

@satorua

Description

@satorua

What happened?

Bug Report: WebSearch Functionality Not Working

Summary

WebSearch functionality in Z.ai's API is not returning search results, always returning empty results.

Environment

Steps to Reproduce

  1. Make an API call with web_search tool
  2. Include a search query
  3. Observe the response

Expected Behavior

WebSearch should return search results from the web.

Actual Behavior

WebSearch returns empty results:

"web_search_prime_result_summary": [{"text": [], "type": "text"}]


### Relevant log output

```shell
# Test API connectivity
curl -I https://api.z.ai/api/anthropic

# Test WebSearch via API
curl -X POST https://api.z.ai/api/anthropic/v1/messages \
  -H "Content-Type: application/json" \
  -H "x-api-key: YOUR_API_KEY" \
  -d '{
    "model": "glm-5",
    "max_tokens": 100,
    "tools": [{"name": "web_search", "description": "Search the web for current information"}],
    "messages": [{"role": "user", "content": "Search for AI news"}]
  }'

Code of Conduct

  • I agree to follow this project's Code of Conduct

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions