[PR #10904] Feat: support json output for bing-search #26983

Closed
opened 2026-02-21 20:40:38 -05:00 by yindo · 0 comments
Owner

Original Pull Request: https://github.com/langgenius/dify/pull/10904

State: closed
Merged: Yes


Summary

Support json output for bing-search

Example

option:
Screenshot 2024-11-21 at 09 38 02

result:

{
  "text": "",
  "files": [],
  "json": [
    {
      "organic": [
        {
          "title": "Nikola Tesla | Biography, Facts, & Inventions | Britannica",
          "snippet": "Nikola Tesla (born July 9/10, 1856, Smiljan, Austrian Empire [now in Croatia]—died January 7, 1943, New York, New York, U.S.) was a Serbian American inventor and engineer who discovered and patented the rotating magnetic field, the basis of most alternating-current machinery. He also developed the three-phase system of electric power transmission.",
          "url": "https://www.britannica.com/biography/Nikola-Tesla",
          "siteName": "Britannica"
        },
        {
          "title": "Nikola Tesla ‑ Inventions, Facts & Death - HISTORY",
          "snippet": "Nikola Tesla was a Serbian-American engineer and physicist who invented the AC motor and developed AC power technology. He had a rivalry with Thomas Edison, a partnership with George Westinghouse and a mysterious death in 1943.",
          "url": "https://www.history.com/topics/inventions/nikola-tesla",
          "siteName": "History"
        },
        {
          "title": "Tesla, Inc. | History, Cars, Elon Musk, & Facts | Britannica Money",
          "snippet": "Tesla, Inc. is an American manufacturer of electric vehicles, solar panels, and automobile batteries. It was founded in 2003 by American entrepreneurs Martin Eberhard and Marc Tarpenning and was named after Serbian American inventor Nikola Tesla. Elon Musk, an early investor in the company, became CEO in 2008.",
          "url": "https://www.britannica.com/money/Tesla-Motors",
          "siteName": "Britannica"
        },
        {
          "title": "Nikola Tesla: Biography, Inventor, Scientist, Engineer",
          "snippet": "Nikola Tesla invented the Tesla coil and alternating-current (AC) electricity. Read about his inventions, relationship with Thomas Edison, death ray, and death.",
          "url": "https://www.biography.com/inventors/nikola-tesla",
          "siteName": "Biography"
        },
        {
          "title": "Nikola Tesla – The Genius Who Lit the World and Saw the Future",
          "snippet": "Nikola Tesla was one of the most forward-thinking inventors and engineers in history whose pioneering work with electricity literally lit up the modern world. Though underappreciated in his own time, Tesla created hundreds of groundbreaking innovations that fundamentally advanced technology and changed the course of history.",
          "url": "https://www.historytools.org/people/nikola-tesla-complete-biography",
          "siteName": ""
        }
      ]
    }
  ]
}

Checklist

Important

Please review the checklist below before submitting your pull request.

  • This change requires a documentation update, included: Dify Document
  • I understand that this PR may be closed in case there was no previous discussion or issues. (This doesn't apply to typos!)
  • I've added a test for each change that was introduced, and I tried as much as possible to make a single atomic change.
  • I've updated the documentation accordingly.
  • I ran dev/reformat(backend) and cd web && npx lint-staged(frontend) to appease the lint gods
**Original Pull Request:** https://github.com/langgenius/dify/pull/10904 **State:** closed **Merged:** Yes --- # Summary Support json output for bing-search ## Example **option**: <img width="397" alt="Screenshot 2024-11-21 at 09 38 02" src="https://github.com/user-attachments/assets/49edc4b1-89df-467c-babd-37fa9816598a"> **result**: ```json { "text": "", "files": [], "json": [ { "organic": [ { "title": "Nikola Tesla | Biography, Facts, & Inventions | Britannica", "snippet": "Nikola Tesla (born July 9/10, 1856, Smiljan, Austrian Empire [now in Croatia]—died January 7, 1943, New York, New York, U.S.) was a Serbian American inventor and engineer who discovered and patented the rotating magnetic field, the basis of most alternating-current machinery. He also developed the three-phase system of electric power transmission.", "url": "https://www.britannica.com/biography/Nikola-Tesla", "siteName": "Britannica" }, { "title": "Nikola Tesla ‑ Inventions, Facts & Death - HISTORY", "snippet": "Nikola Tesla was a Serbian-American engineer and physicist who invented the AC motor and developed AC power technology. He had a rivalry with Thomas Edison, a partnership with George Westinghouse and a mysterious death in 1943.", "url": "https://www.history.com/topics/inventions/nikola-tesla", "siteName": "History" }, { "title": "Tesla, Inc. | History, Cars, Elon Musk, & Facts | Britannica Money", "snippet": "Tesla, Inc. is an American manufacturer of electric vehicles, solar panels, and automobile batteries. It was founded in 2003 by American entrepreneurs Martin Eberhard and Marc Tarpenning and was named after Serbian American inventor Nikola Tesla. Elon Musk, an early investor in the company, became CEO in 2008.", "url": "https://www.britannica.com/money/Tesla-Motors", "siteName": "Britannica" }, { "title": "Nikola Tesla: Biography, Inventor, Scientist, Engineer", "snippet": "Nikola Tesla invented the Tesla coil and alternating-current (AC) electricity. Read about his inventions, relationship with Thomas Edison, death ray, and death.", "url": "https://www.biography.com/inventors/nikola-tesla", "siteName": "Biography" }, { "title": "Nikola Tesla – The Genius Who Lit the World and Saw the Future", "snippet": "Nikola Tesla was one of the most forward-thinking inventors and engineers in history whose pioneering work with electricity literally lit up the modern world. Though underappreciated in his own time, Tesla created hundreds of groundbreaking innovations that fundamentally advanced technology and changed the course of history.", "url": "https://www.historytools.org/people/nikola-tesla-complete-biography", "siteName": "" } ] } ] } ``` # Checklist > [!IMPORTANT] > Please review the checklist below before submitting your pull request. - [ ] This change requires a documentation update, included: [Dify Document](https://github.com/langgenius/dify-docs) - [x] I understand that this PR may be closed in case there was no previous discussion or issues. (This doesn't apply to typos!) - [x] I've added a test for each change that was introduced, and I tried as much as possible to make a single atomic change. - [x] I've updated the documentation accordingly. - [x] I ran `dev/reformat`(backend) and `cd web && npx lint-staged`(frontend) to appease the lint gods
yindo added the pull-request label 2026-02-21 20:40:38 -05:00
yindo closed this issue 2026-02-21 20:40:38 -05:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: langgenius/dify#26983