[object Object]

← back to Designer Wallcoverings

auto-save: 2026-06-24T12:57:01 (3 files) — mailers/cc-api/oauth-setup.js shopify/display-variant-backfill/progress.json vendor-scrapers/china-seas-refresh

bb5316e3b3430d0817ab5b72fe61189e75198b6d · 2026-06-24 12:57:07 -0700 · Steve Abrams

Files touched

Diff

commit bb5316e3b3430d0817ab5b72fe61189e75198b6d
Author: Steve Abrams <steve@designerwallcoverings.com>
Date:   Wed Jun 24 12:57:07 2026 -0700

    auto-save: 2026-06-24T12:57:01 (3 files) — mailers/cc-api/oauth-setup.js shopify/display-variant-backfill/progress.json vendor-scrapers/china-seas-refresh
---
 mailers/cc-api/oauth-setup.js                  | 6 +++++-
 shopify/display-variant-backfill/progress.json | 2 +-
 2 files changed, 6 insertions(+), 2 deletions(-)

diff --git a/mailers/cc-api/oauth-setup.js b/mailers/cc-api/oauth-setup.js
index 3a1edbb7..ce7fd56f 100644
--- a/mailers/cc-api/oauth-setup.js
+++ b/mailers/cc-api/oauth-setup.js
@@ -15,11 +15,15 @@
  *   node oauth-setup.js token "<full redirected URL>"   # also accepts the whole URL
  */
 const crypto = require('crypto');
+const path = require('path');
+// Auto-load the saved creds (CC_CLIENT_ID/SECRET) from the gitignored local .env.
+try { require('dotenv').config({ path: path.join(__dirname, '.env') }); } catch { /* dotenv optional */ }
 
 const AUTHORIZE_URL = 'https://authz.constantcontact.com/oauth2/default/v1/authorize';
 const TOKEN_URL = 'https://authz.constantcontact.com/oauth2/default/v1/token';
 const REDIRECT_URI = process.env.CC_REDIRECT_URI || 'https://localhost';
-const SCOPE = 'campaign_data offline_access';
+// contact_data = read/manage lists (set recipients via API); campaign_data = create/send; offline_access = refresh token.
+const SCOPE = process.env.CC_SCOPE || 'contact_data campaign_data offline_access';
 
 function need(name) {
   const v = process.env[name];
diff --git a/shopify/display-variant-backfill/progress.json b/shopify/display-variant-backfill/progress.json
index 1f4a243d..0051ec33 100644
--- a/shopify/display-variant-backfill/progress.json
+++ b/shopify/display-variant-backfill/progress.json
@@ -1 +1 @@
-{"status":"running","total":20137,"tagged":5675,"failed":0,"priorityCount":266,"restCount":19871,"startedAt":1782330432823,"updatedAt":1782330963165,"currentGid":"gid://shopify/Product/1498296680560","rate":10.7,"etaSec":1352,"note":"priority = products purchased in last 90d (client-engaged), tagged first"}
\ No newline at end of file
+{"status":"running","total":20137,"tagged":6400,"failed":0,"priorityCount":266,"restCount":19871,"startedAt":1782330432823,"updatedAt":1782331026519,"currentGid":"gid://shopify/Product/1498811596912","rate":10.8,"etaSec":1274,"note":"priority = products purchased in last 90d (client-engaged), tagged first"}
\ No newline at end of file

← 8aa32e71 CC API: auto-load creds from gitignored .env (dotenv); China  ·  back to Designer Wallcoverings  ·  CC OAuth: add contact_data scope (list read/set) + dotenv au dfd19842 →