Spaces:
Running
Running
File size: 3,880 Bytes
dff941e c73909d 60c7a7f c73909d 60c7a7f c73909d 60c7a7f c73909d 60c7a7f c73909d 60c7a7f c73909d 60c7a7f c73909d 60c7a7f c73909d 60c7a7f c73909d 60c7a7f c73909d 60c7a7f c73909d 60c7a7f c73909d 60c7a7f c73909d 60c7a7f c73909d 60c7a7f c73909d 60c7a7f c73909d 60c7a7f c73909d 60c7a7f c73909d 60c7a7f c73909d 60c7a7f c73909d |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 |
---
title: Proxy Lite Experimental
emoji: π¨
colorFrom: green
colorTo: purple
sdk: docker
pinned: false
---
# Proxy-lite Salesforce Automation
A Salesforce automation system using Proxy-lite that works with any Salesforce org. The backend is already deployed and ready to use - you just need to add the Lightning Web Component to your org.
## β
What You Need
- A Salesforce org (any org)
- Salesforce CLI (sfdx)
- Your Salesforce username and password
## π Quick Setup (5 minutes)
### Step 1: Deploy the Lightning Web Component
```bash
# Clone this repository
git clone [your-repo-url]
cd proxy-litev2\ copy
# Deploy to your Salesforce org
cd proxy-lite-work
sfdx force:auth:web:login -a yourorg
sfdx force:source:push -u yourorg
```
### Step 2: Add Component to Your Page
1. Go to **Setup** β **Lightning App Builder**
2. Edit any Lightning page (like Home page)
3. Add the **"Salesforce Automation with Proxy Lite"** component
4. Save and activate
### Step 3: Use the Component
1. Open the Lightning page where you added the component
2. Select a target page from the dropdown
3. Enter your automation task (e.g., "Enable the toggle switch")
4. Click "Run Automation"
**That's it!** The component will connect to the already-deployed backend automatically.
## π§ How It Works
- **Backend**: Already deployed on Hugging Face Spaces (no setup needed)
- **Frontend**: Lightning Web Component in your Salesforce org
- **Authentication**: Uses your Salesforce credentials automatically
- **URLs**: Dynamically adapts to your org's domain
## π Supported Automation Tasks
The system can automate various Salesforce setup pages:
- Warranty Lifecycle Management
- Account Forecasting Settings
- Sales Agreements
- Account Manager Targets
- Custom tasks on any setup page
## π οΈ Advanced Configuration (Optional)
### Custom Endpoint (Enterprise Users)
If you need your own private instance:
1. **Fork this repository**
2. **Deploy to Hugging Face Spaces**:
- Create a new Space
- Connect your forked repo
- Set environment variables:
```
GEMINI_API_KEY=your_key
SALESFORCE_USERNAME=your_username
SALESFORCE_PASSWORD=your_password
```
3. **Update Apex Class**:
- Go to **Setup** β **Apex Classes** β **ProxyLiteService**
- Update the endpoint URL in `getProxyLiteEndpoint()` method
### Environment Variables for Custom Deployment
Only needed if deploying your own instance:
```env
# Required: At least one API key
GEMINI_API_KEY=your_gemini_api_key
HF_API_TOKEN=your_hf_token
# Required: Your Salesforce credentials
[email protected]
SALESFORCE_PASSWORD=your_salesforce_password
# Optional: Browser settings
BROWSER_HEADLESS=true
BROWSER_VIEWPORT_WIDTH=1280
BROWSER_VIEWPORT_HEIGHT=720
```
## π Troubleshooting
### Common Issues
1. **Component not showing**: Check if you've pushed the LWC to your org
2. **"Endpoint not configured" error**: The Apex class needs the correct endpoint URL
3. **Authentication errors**: Verify your Salesforce credentials work
4. **Timeout errors**: Large tasks may take time - be patient
### Debug Steps
1. Check browser console for errors
2. Verify the LWC is properly deployed
3. Test with a simple task first
4. Check Salesforce debug logs
## π‘ Why This Approach?
- **No Python setup needed** - Backend already deployed
- **Works with any Salesforce org** - No hardcoded URLs
- **Free to use** - Powered by Hugging Face Spaces
- **Secure** - Uses your org's authentication
- **Simple deployment** - Just add the LWC component
## π Support
If you encounter issues:
1. Check the troubleshooting section above
2. Verify your Salesforce org permissions
3. Test with a different browser
4. Check the component is properly added to your page
## π License
This project is licensed under the MIT License.
|