This Excel add-in integrates with Polygon.io API to fetch financial data directly into your spreadsheets.
=POLYGON.getTickerDetails("AAPL")
- Get ticker details (name, market)=POLYGON.getTickerNews("AAPL", 5)
- Get latest news articles
- Node.js (v14+) and npm
- Microsoft Excel (Desktop or Online)
- Polygon.io API key
-
Clone & Install
git clone https://github.com/yourusername/polygon-ai.git cd polygon-ai npm install
-
Get Development Certificates
npx office-addin-dev-certs install
Note: If you receive a security prompt, select 'Yes' to install the certificate
-
Build the Project
npm run build
-
Start Development Server
npm run dev-server
The server will start at https://localhost:3000
- Open Excel and a blank workbook
- Go to Insert tab > Add-ins > My Add-ins > Manage My Add-ins > Upload My Add-in
- Browse to the project folder and select
manifest.xml
-
Create a network share using PowerShell (or use an existing share):
# Create a folder for sharing New-Item -Path "C:\PolygonShare" -ItemType Directory -Force # Share the folder (requires admin privileges) New-SmbShare -Name "PolygonShare" -Path "C:\PolygonShare" -FullAccess Everyone
-
Create the add-in folder and copy the manifest:
# Create add-in folder New-Item -Path "C:\PolygonShare\Polygon" -ItemType Directory -Force # Copy manifest to the shared folder Copy-Item -Path ".\manifest.xml" -Destination "C:\PolygonShare\Polygon\"
-
In Excel, go to File > Options > Trust Center > Trust Center Settings > Trusted Add-in Catalogs
-
Add the network path to your shared folder (e.g.,
\\localhost\PolygonShare\Polygon
) -
Check the "Show in Menu" option and click OK
-
Restart Excel
-
Go to Insert tab > Add-ins > My Add-ins
-
Select the "Shared Folder" tab, and you should see your add-in
- Open Excel Online and create a new workbook
- Go to Insert tab > Office Add-ins
- Select Upload My Add-in at the bottom of the dialog
- Browse to and select the
manifest.xml
file - Click Upload
- After sideloading, the add-in appears in the Home tab
- Click the add-in button to open the task pane
- Set your Polygon.io API key in the task pane
- Use the custom functions in your spreadsheet:
=POLYGON.getTickerDetails("AAPL")
=POLYGON.getTickerNews("AAPL", 5)
npm run build
- Build for productionnpm run build:dev
- Build for developmentnpm run dev-server
- Start dev servernpm run start
- Build and start debuggingnpm run validate
- Validate the manifest filenpm run lint
- Check for linting issues
/src/functions/
- Custom Excel functions implementation/src/taskpane/
- Task pane UI codemanifest.xml
- Add-in configuration file
- Update
webpack.config.js
to replace development URL with your production URL - Build the project:
npm run build
- Host the files from the
/dist
folder on your web server - Update the manifest.xml to point to your production URL
- Distribute the manifest.xml file to users
- If the add-in doesn't load, check browser console for errors (press F12 in Excel Online)
- Ensure your Polygon.io API key has been set
- Verify the dev server is running on https://localhost:3000
- Check Windows Firewall settings if connecting from another device
- PowerShell commands may require elevated permissions:
# Run PowerShell as Administrator Start-Process powershell -Verb RunAs
- If you see certificate errors:
# Reinstall development certificates npx office-addin-dev-certs install --machine
- Verify the manifest is correctly formatted using the validator:
npm run validate