Support OAuth Integration for Plugin Tools (#22550)

Co-authored-by: zxhlyh <jasonapring2015@outlook.com>
Co-authored-by: Yeuoly <admin@srmxy.cn>
This commit is contained in:
Maries 2025-07-17 17:18:44 +08:00 • committed by GitHub
commit a4ef900916
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
89 changed files with 5516 additions and 875 deletions

View file

@ -16,10 +16,11 @@ import {
const NAME_SPACE = 'tools'
const useAllToolProvidersKey = [NAME_SPACE, 'allToolProviders']
export const useAllToolProviders = () => {
export const useAllToolProviders = (enabled = true) => {
return useQuery<Collection[]>({
queryKey: useAllToolProvidersKey,
queryFn: () => get<Collection[]>('/workspaces/current/tool-providers'),
enabled,
})
}