A PicGo plugin to upload images to 123pan (123云盘). This plugin leverages the official 123pan OpenAPI for secure and efficient uploads.
- Official API Integration: Uses 123pan's official OpenAPI for reliable uploads
- Optimized for Typora: Special handling for Typora image uploads
- Robust Error Recovery: Automatic retries and fallback mechanisms
- GUI Support: Full integration with PicGo GUI, including custom menu options
- Fast Upload: Supports server-side duplicate detection for instant uploads
- Secure: Your credentials remain securely stored locally
- Download PicGo: Get the app from the official PicGo website
- Install the Plugin:
- Open PicGo
- Go to "Plugin Settings"
- Search for "123pan" in the plugin search
- Click "Install"
-
Install PicGo-Core (command-line version) if you prefer CLI usage:
npm install picgo -g
-
Install the Plugin:
- PicGo-Core (CLI):
picgo install 123pan
- PicGo GUI Manual Installation:
- Download the latest release package
- In PicGo, go to "Plugin Settings"
- Click "Install from local file"
- Select the downloaded package
- PicGo-Core (CLI):
To use this plugin, you need:
- A 123pan account with OpenAPI access (currently only available for VIP members)
- Your
clientID
andclientSecret
from the 123pan OpenAPI management interface
- Open PicGo
- Go to "Image Uploader" in the sidebar
- Select "123pan" as the uploader
- Enter your credentials:
- Client ID: Your 123pan API client ID
- Client Secret: Your 123pan API client secret
- Parent Folder Name (Optional): The name of a folder to store your images
Edit your PicGo configuration file (usually located at ~/.picgo/config.json
on Linux/macOS or %USERPROFILE%\.picgo\config.json
on Windows):
{
"picBed": {
"uploader": "123pan",
"current": "123pan",
"123pan": {
"clientID": "your_client_id",
"clientSecret": "your_client_secret",
}
},
"picgoPlugins": {
"picgo-plugin-123pan": true
}
}
-
Upload via Clipboard:
- Copy an image to your clipboard
- Click the PicGo tray icon
- Select "Upload from Clipboard"
-
Upload from File:
- Click the PicGo tray icon
- Select "Upload from Files"
- Choose image(s) to upload
-
Upload from Screenshot (if you have screenshot plugin):
- Use your configured screenshot shortcut
- The image will be automatically uploaded
-
Using Plugin Menu Options:
- In PicGo, navigate to the 123pan plugin settings
- Use additional options like "Upload from URL" or "Configure API settings"
-
Configure Typora:
- Open Typora
- Go to File > Preferences > Image
- Select "Upload image" for Image insertion
- Choose "PicGo-Core (command line)" or "Custom Command" with path to PicGo
- Click "Test Uploader" to verify the setup
-
Using with Typora:
- Paste an image directly from clipboard (Ctrl+V)
- Typora will automatically upload via PicGo
Upload an image using the command line:
picgo upload /path/to/your/image.jpg
-
"PreuploadID cannot be empty" Error:
- This can occur during first-time uploads with Typora
- Solution: The plugin will automatically retry. If it fails, try manually uploading by right-clicking the image in Typora.
-
Upload Hanging in Typora:
- If an upload seems to hang indefinitely in Typora
- Solution: The plugin has a built-in 60-second timeout that will force completion. You can try again if needed.
-
Authentication Errors:
- Check that your Client ID and Client Secret are correct
- Verify your 123pan VIP subscription is active
- Try regenerating your API credentials from the 123pan website
-
Folder Creation Failures:
- If specified parent folder can't be created
- Solution: The plugin will default to uploading to the root directory
For advanced troubleshooting, you can enable debug logging:
- PicGo GUI: Go to "PicGo Settings" > Enable "Log Level - Debug"
- PicGo-Core: Set the debug environment variable:
DEBUG=picgo* picgo upload /path/to/image.jpg
In PicGo GUI, you can use Ctrl+Alt+1
as a shortcut for quick uploads from clipboard.
Setting a parent folder name in the configuration will:
- Create the folder if it doesn't exist
- Find the folder ID if it already exists
- Use that folder for all uploads
The plugin automatically handles token refresh and maintains a 5-minute buffer before expiration to ensure seamless uploads.