Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewWithSDK ¶ added in v0.2.0
func NewWithSDK(api PixivAPI, downloads DownloadManager, logger *slog.Logger, service application.SDKService, request application.SDKClientRequest) *mcp.Server
NewWithSDK 在保留旧 Source 工具的同时,为新增领域工具注入公共 SDK 接缝。 SDKService 会在每次 MCP tool 调用时建立独立的配置/认证 operation snapshot。
Types ¶
type DownloadManager ¶
type PixivAPI ¶
type PixivAPI interface {
Refresh(context.Context) error
SetRefreshToken(string)
RefreshTokenValue() string
UserID() int64
UserName() string
IsAuthenticated() bool
SearchIllust(context.Context, string, string, string, string, int) (*pixiv.IllustList, error)
IllustDetail(context.Context, int64) (*pixiv.IllustDetail, error)
IllustRelated(context.Context, int64, int) (*pixiv.IllustList, error)
IllustRanking(context.Context, string, string, int) (*pixiv.IllustList, error)
SearchUser(context.Context, string, int) (*pixiv.UserPreviewList, error)
IllustRecommended(context.Context, int) (*pixiv.IllustList, error)
TrendingTagsIllust(context.Context) (*pixiv.TrendTags, error)
IllustFollow(context.Context, string, int) (*pixiv.IllustList, error)
UserBookmarks(context.Context, int64, string, string, int64) (*pixiv.IllustList, error)
UserFollowing(context.Context, int64, string, int) (*pixiv.UserPreviewList, error)
Download(context.Context, string, io.Writer) error
}
Click to show internal directories.
Click to hide internal directories.