Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
D
dify
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
ai-tech
dify
Commits
83063532
Unverified
Commit
83063532
authored
Feb 01, 2024
by
Yeuoly
Committed by
GitHub
Feb 01, 2024
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix/api tool (#2317)
parent
07279558
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
4 additions
and
4 deletions
+4
-4
tool_providers.py
api/controllers/console/workspace/tool_providers.py
+2
-2
tools_manage_service.py
api/services/tools_manage_service.py
+2
-2
No files found.
api/controllers/console/workspace/tool_providers.py
View file @
83063532
...
...
@@ -171,8 +171,8 @@ class ToolApiProviderUpdateApi(Resource):
parser
.
add_argument
(
'schema'
,
type
=
str
,
required
=
True
,
nullable
=
False
,
location
=
'json'
)
parser
.
add_argument
(
'provider'
,
type
=
str
,
required
=
True
,
nullable
=
False
,
location
=
'json'
)
parser
.
add_argument
(
'original_provider'
,
type
=
str
,
required
=
True
,
nullable
=
False
,
location
=
'json'
)
parser
.
add_argument
(
'icon'
,
type
=
str
,
required
=
True
,
nullable
=
False
,
location
=
'json'
)
parser
.
add_argument
(
'privacy_policy'
,
type
=
str
,
required
=
True
,
nullable
=
Fals
e
,
location
=
'json'
)
parser
.
add_argument
(
'icon'
,
type
=
dict
,
required
=
True
,
nullable
=
False
,
location
=
'json'
)
parser
.
add_argument
(
'privacy_policy'
,
type
=
str
,
required
=
True
,
nullable
=
Tru
e
,
location
=
'json'
)
args
=
parser
.
parse_args
()
...
...
api/services/tools_manage_service.py
View file @
83063532
...
...
@@ -362,7 +362,7 @@ class ToolManageService:
@
staticmethod
def
update_api_tool_provider
(
user_id
:
str
,
tenant_id
:
str
,
provider_name
:
str
,
original_provider
:
str
,
icon
:
str
,
credentials
:
dict
,
user_id
:
str
,
tenant_id
:
str
,
provider_name
:
str
,
original_provider
:
str
,
icon
:
dict
,
credentials
:
dict
,
schema_type
:
str
,
schema
:
str
,
privacy_policy
:
str
):
"""
...
...
@@ -387,7 +387,7 @@ class ToolManageService:
# update db provider
provider
.
name
=
provider_name
provider
.
icon
=
icon
provider
.
icon
=
json
.
dumps
(
icon
)
provider
.
schema
=
schema
provider
.
description
=
extra_info
.
get
(
'description'
,
''
)
provider
.
schema_type_str
=
ApiProviderSchemaType
.
OPENAPI
.
value
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment