Skip to content

Pinterest Auto-Poster #69

Pinterest Auto-Poster

Pinterest Auto-Poster #69

Workflow file for this run

name: Pinterest Auto-Poster
on:
schedule:
- cron: '0 9 * * *' # Runs every day at 9:00 AM UTC
workflow_dispatch: # Allows manual trigger
jobs:
post-pins:
runs-on: ubuntu-latest
steps:
- name: Checkout Code
uses: actions/checkout@v3
- name: Setup Node.js
uses: actions/setup-node@v3
with:
node-version: '18'
- name: Run Pinterest Bot
env:
PINTEREST_APP_ID: ${{ secrets.PINTEREST_APP_ID }}
PINTEREST_APP_SECRET: ${{ secrets.PINTEREST_APP_SECRET }}
PINTEREST_REFRESH_TOKEN: ${{ secrets.PINTEREST_REFRESH_TOKEN }}
PINTEREST_BOARD_ID: ${{ secrets.PINTEREST_BOARD_ID }}
PINS_PER_DAY: 3
run: node scripts/pinterest-bot.mjs
- name: Commit Updated DB
uses: stefanzweifel/git-auto-commit-action@v4
with:
commit_message: "chore: Auto-update pins database"
file_pattern: "scripts/pins-data.json"