Commit Graph

696 Commits

Author SHA1 Message Date
Maries c6f83a63e1 feat[0.4.2]: Tool OAuth (#179)
* chore: fix ruff issue

* feat(oauth): implement OAuth

* feat(invoke-message): refactor message handling and introduce InvokeMessage class

* feat(plugin-oauth): add credential_id and credential_type to tool parameters

* feat(plugin-oauth): add credential_id and credential_type to tool parameters

* chore: update dify_plugin version to 0.5.0b4 and clean up github.yaml

* chore: update plugin version to 0.1.2 in manifest.yaml

* feat(session): session context and tool backwards invocation credential support

* feat(oauth): session context and tool backwards invocation credential support

* feat: update README and requirements for OAuth support in version 0.4.2

* feat: add .gitignore to exclude IDE files and secret keys

* chore: apply ruff

* feat: bump version to 0.4.2b1

* feat: update GitHub plugin configuration for OAuth support and improve credential handling

* feat: update .gitignore to exclude dify plugin files and public keys

* feat: fix credential validation for GitHub API and bump version to 0.2.1

* feat: update GitHub plugin to support multiple access tokens and bump version to 0.2.5

* chore: apply ruff

* feat: add ToolProviderOAuthError for improved OAuth error handling in GitHub plugin

* chore: apply ruff

* chore: bump version to 0.4.2

* chore: update examples sdk version to 0.4.2

* fix: thread deadlock in PluginRunner when running tests without gevent monkey patching

* feat: add support for refreshing OAuth credentials in Plugin and GitHub provider

* feat: refactor OAuth credential handling to return structured OAuthCredentials object

* apply ruff

* feat: refactor OAuth credential handling to use ToolOAuthCredentials for improved structure

* feat: reorganize imports in __init__.py for improved clarity and structure

* feat: add Microsoft To Do plugin for refresh token example

* chore: apply ruff

* fix: update author in GitHub configuration and clean up Microsoft To Do schema

* chore: bump version to 0.4.2b2 in pyproject.toml

* feat: update Microsoft To Do plugin to handle OAuth token encoding and version bump

* feat:remove inelegant example

* chore: update dify_plugin version to 0.4.2

* chore: bump version to 0.4.2 in pyproject.toml

---------

Co-authored-by: Yeuoly <admin@srmxy.cn>
2025-07-23 13:49:01 +08:00
Harry f9b82334e4 chore: update version numbers in manifest and requirements for release 2025-07-18 21:32:02 +08:00
Harry f8e8f3aa47 chore: bump version to 0.5.0b6 in pyproject.toml 2025-07-18 20:05:19 +08:00
Harry 6bf1431954 feat: enhance type hints and improve error handling in Notion datasource 2025-07-18 20:04:46 +08:00
Maries f55014d757 Merge branch 'main' into feat/datasource 2025-07-18 19:53:48 +08:00
Harry 3497cb2ae9 chore: bump version to 0.5.0b5 in pyproject.toml 2025-07-18 19:49:18 +08:00
Harry 6e3a6fc4d4 feat(notion): add Notion datasource plugin with OAuth support and initial implementation 2025-07-18 19:43:31 +08:00
Harry 1915391a14 Merge branch 'feat/plugin-oauth' into feat/datasource 2025-07-14 11:01:08 +08:00
Harry d846ab2699 feat(oauth): session context and tool backwards invocation credential support 2025-07-14 10:30:05 +08:00
Harry 3f1899a1dd feat(session): session context and tool backwards invocation credential support 2025-07-13 01:33:41 +08:00
Harry 1621c0c1ed chore: update plugin version to 0.1.2 in manifest.yaml 2025-07-11 22:38:05 +08:00
Harry 8db6eeaf5c chore: update dify_plugin version to 0.5.0b4 and clean up github.yaml 2025-07-11 22:35:54 +08:00
Harry 88f6f63905 feat(plugin-oauth): add credential_id and credential_type to tool parameters 2025-07-11 14:27:05 +08:00
Harry b4a9ef23d1 feat(plugin-oauth): add credential_id and credential_type to tool parameters 2025-07-11 14:26:34 +08:00
Yeuoly 21e77bd043 Bump to 0.4.1 (#178) 2025-07-09 20:18:47 +08:00
Kalo Chin 2bf1a2a5a8 docs/bump up sdk ver guide (#174)
* chore: update version constraint for dify_plugin to 0.3.0,<0.4.0 in README.md

* Update README.md

* Update README.md

* Update README.md
2025-07-09 20:17:32 +08:00
Yeuoly d27bbddc02 feat: dark icon (#173)
* docs: update README.md to include support for `dark-icon` field in manifest versioning

* feat: add dark mode icon fields to Tool and SimpleProviderEntity models

- Introduced `icon_dark` field in ToolProviderIdentity for dark mode support.
- Added `icon_small_dark` and `icon_large_dark` fields in SimpleProviderEntity for dark mode icons.
2025-07-09 16:06:20 +08:00
Harry 0c66b22aac feat: bump to 0.5.0b4 2025-07-08 13:31:14 +08:00
Harry 68abb06abf feat: clean up imports in agent.py, github_repositories.py, and request.py 2025-07-07 17:50:42 +08:00
Harry f4c32abecc Merge branch 'feat/plugin-oauth' into feat/datasource
# Conflicts:
#	python/dify_plugin/core/entities/plugin/request.py
#	python/dify_plugin/core/plugin_executor.py
#	python/dify_plugin/entities/__init__.py
#	python/dify_plugin/entities/agent.py
#	python/dify_plugin/entities/tool.py
#	python/examples/github/tools/github_repositories.py
2025-07-07 17:44:05 +08:00
Harry 799bea4c41 feat(invoke-message): refactor message handling and introduce InvokeMessage class 2025-07-07 17:33:23 +08:00
Harry 0ec96aea2a feat(oauth): implement OAuth 2025-07-07 15:16:56 +08:00
Harry 2aedda0652 chore: fix ruff issue 2025-07-06 16:37:04 +08:00
Harry f2e9190d2d feat: add CredentialType enum and integrate into ToolRuntime and update examples 2025-07-04 19:12:09 +08:00
Harry 401d0d4f97 chore: bump version to 0.5.0b3 2025-07-02 23:21:54 +08:00
Harry 89137a3694 refactor: rename OnlineDocumentPagesMessage to DatasourceGetPagesResponse and update related methods 2025-07-02 23:18:09 +08:00
Harry 9b6c626798 chore: remove outdated examples 2025-07-02 23:18:08 +08:00
Harry e3c751ec2c chore: remove outdated GitHub Actions workflow for plugin publishing 2025-07-02 16:43:31 +08:00
Harry a844db7a68 refactor: streamline code by improving import order and simplifying function definitions 2025-07-02 16:32:20 +08:00
Harry e8cc4760cb refactor: update type hints to use union syntax and improve import order 2025-07-02 16:15:28 +08:00
Harry 1d92e2dbc0 chore: bump version to 0.5.0b2 in pyproject.toml 2025-07-02 15:45:54 +08:00
Harry 97ed0503d7 chore: bump version to 0.5.0b1 in pyproject.toml 2025-07-02 15:42:22 +08:00
Harry 2f5d00aee6 fix: update import statements to include LogMetadata from provider_config 2025-07-02 14:14:31 +08:00
Harry e59d246115 Merge remote-tracking branch 'origin/main' into feat/oauth-datasource
# Conflicts:
#	python/dify_plugin/core/entities/plugin/request.py
#	python/dify_plugin/core/plugin_executor.py
#	python/dify_plugin/entities/__init__.py
#	python/dify_plugin/entities/tool.py
#	python/dify_plugin/interfaces/tool/__init__.py
#	python/dify_plugin/plugin.py
#	python/pyproject.toml
2025-07-02 14:08:12 +08:00
Harry b835fddf34 feat: update _browse_files method to return OnlineDriveBrowseFilesResponse 2025-07-02 13:30:16 +08:00
Yeuoly c1e36d653c Refactor: standardize string quotes for model name retrieval in OpenAI compatible interfaces (#168) 2025-06-28 00:24:10 +08:00
cyflhn 4aabe2b650 add endpoint model name in credentials for openai compatible interface (#24)
Co-authored-by: root <root@localhost.localdomain>
2025-06-27 23:58:22 +08:00
Harry ab07c664d9 feat: rename online driver to online drive and update related classes and methods :) 2025-06-27 20:13:00 +08:00
Harry 7b06a2ac23 feat: add online driver datasource 2025-06-27 16:33:44 +08:00
Yeuoly 600b4b1d40 Bump to 0.4.0 (#167) 2025-06-27 16:28:01 +08:00
belugaliu cfb551dd88 fix[0.4.0]: add response body to CredentialsValidateFailedError exceptions to aid in error diagnosis, especially useful for locally provided models (#161)
* fix: Add response body to CredentialsValidateFailedError exceptions to aid in error diagnosis, especially useful for locally provided models

* fix: linter

---------

Co-authored-by: liull <liulili@thunisoft.com>
Co-authored-by: Yeuoly <admin@srmxy.cn>
2025-06-27 16:04:40 +08:00
Yeuoly 132d6572ee feat[0.4.0]: add dynamic select support (#163)
* feat: add dynamic select support

- Introduced ParameterOption class for parameter options with value, label, and optional icon.
- Updated ToolParameterOption to inherit from ParameterOption.
- Added DYNAMIC_SELECT to CommonParameterType enum.
- Implemented fetch_parameter_options method in Tool class for fetching parameter options.
- Created DynamicSelectProtocol for dynamic select functionality.
- Added tests for Tool construction and parameter options fetching.

* feat: implement dynamic parameter fetching functionality

- Added DynamicParameterFetchParameterOptionsRequest class for dynamic parameter requests.
- Introduced DynamicParameterActions enum for action types related to dynamic parameters.
- Enhanced PluginExecutor with methods to handle dynamic parameter fetching.
- Updated Tool interface to include a method for fetching parameter options.
- Documented the DynamicSelectProtocol for clarity on its usage.

* feat: enhance plugin functionality with dynamic parameter options and trigger interface

- Added dynamic parameter fetching capabilities to the Plugin class.
- Introduced TriggerProvider and Trigger classes for managing trigger functionalities.
- Updated Tool interface to enforce implementation of credential validation and OAuth methods.
- Enhanced error messages for NotImplementedError in ToolProvider and Trigger classes.
- Removed deprecated tools and their configurations from the codebase.

* docs: update README.md to include support for `dynamic-select` parameter type in manifest versioning

* chore: remove code_based_workflow
2025-06-27 15:59:22 +08:00
Bowen Liang 3babba0c65 update gevent~=25.5.1 (#157) 2025-06-27 15:56:42 +08:00
Yeuoly 1ec2ff6d6c feat[0.4.0]: add LLMStructuredOutput and LLMStructuredOutputInvocation for s… (#166)
* feat: add LLMStructuredOutput and LLMStructuredOutputInvocation for structured output handling

- Introduced LLMStructuredOutput model class for structured output representation.
- Added LLMStructuredOutputInvocation class to handle invocation with structured output.
- Updated ModelInvocations to include LLMStructuredOutputInvocation.
- Modified InvokeType enum to support LLMStructuredOutput type.

* docs: update README.md to include support for LLM structured output in manifest versioning
2025-06-27 15:54:42 +08:00
Harry 758af03409 fix: datasource oauth schema 2025-06-26 16:14:49 +08:00
Harry 856dffeda8 feat: update OAuth methods to include redirect_uri parameter 2025-06-26 14:38:28 +08:00
Harry 666663683d update: github oauth example 2025-06-26 13:16:07 +08:00
Yeuoly a9a752af23 docs: update README.md with manifest versioning details and enhance s… (#164)
* docs: update README.md with manifest versioning details and enhance setup.py field descriptions for version compatibility

* docs: enhance README.md with manifest versioning details and update Python SDK README for version constraints
2025-06-25 19:24:48 +08:00
Yeuoly 5ba4e2fffc Merge branch 'feat/dynamic-select' into feat/trigger 2025-06-25 15:04:23 +08:00
Yeuoly 5415dbafa9 feat: enhance plugin functionality with dynamic parameter options and trigger interface
- Added dynamic parameter fetching capabilities to the Plugin class.
- Introduced TriggerProvider and Trigger classes for managing trigger functionalities.
- Updated Tool interface to enforce implementation of credential validation and OAuth methods.
- Enhanced error messages for NotImplementedError in ToolProvider and Trigger classes.
- Removed deprecated tools and their configurations from the codebase.
2025-06-25 15:03:28 +08:00