paddle-checkout-accelerator 3.0.1 → 3.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -430,6 +430,7 @@ function runDoctor() {
|
|
|
430
430
|
console.log(" npx paddle-checkout-accelerator verify");
|
|
431
431
|
console.log(" npx paddle-checkout-accelerator auth");
|
|
432
432
|
console.log(" npx paddle-checkout-accelerator bootstrap");
|
|
433
|
+
console.log(" npx paddle-checkout-accelerator connect");
|
|
433
434
|
|
|
434
435
|
process.exit(1);
|
|
435
436
|
}
|
|
@@ -1289,6 +1290,50 @@ export async function POST(request: NextRequest) {
|
|
|
1289
1290
|
);
|
|
1290
1291
|
}
|
|
1291
1292
|
|
|
1293
|
+
async function runConnect() {
|
|
1294
|
+
console.log("");
|
|
1295
|
+
console.log("Paddle Checkout Accelerator Connect");
|
|
1296
|
+
console.log("");
|
|
1297
|
+
|
|
1298
|
+
const env =
|
|
1299
|
+
readEnvFile();
|
|
1300
|
+
|
|
1301
|
+
const values =
|
|
1302
|
+
parseEnv(env);
|
|
1303
|
+
|
|
1304
|
+
if (!values.PADDLE_API_KEY) {
|
|
1305
|
+
console.log("❌ Missing PADDLE_API_KEY in .env.local");
|
|
1306
|
+
console.log("");
|
|
1307
|
+
console.log("Add your Paddle API key, then run:");
|
|
1308
|
+
console.log(" npx paddle-checkout-accelerator connect");
|
|
1309
|
+
process.exit(1);
|
|
1310
|
+
}
|
|
1311
|
+
|
|
1312
|
+
if (!values.PADDLE_WEBHOOK_SECRET) {
|
|
1313
|
+
console.log("❌ Missing PADDLE_WEBHOOK_SECRET in .env.local");
|
|
1314
|
+
console.log("");
|
|
1315
|
+
console.log("Add your Paddle webhook secret, then run:");
|
|
1316
|
+
console.log(" npx paddle-checkout-accelerator connect");
|
|
1317
|
+
process.exit(1);
|
|
1318
|
+
}
|
|
1319
|
+
|
|
1320
|
+
if (!values.NEXT_PUBLIC_PADDLE_CLIENT_TOKEN) {
|
|
1321
|
+
console.log("❌ Missing NEXT_PUBLIC_PADDLE_CLIENT_TOKEN in .env.local");
|
|
1322
|
+
console.log("");
|
|
1323
|
+
console.log("Add your Paddle client token, then run:");
|
|
1324
|
+
console.log(" npx paddle-checkout-accelerator connect");
|
|
1325
|
+
process.exit(1);
|
|
1326
|
+
}
|
|
1327
|
+
|
|
1328
|
+
await runBootstrap();
|
|
1329
|
+
|
|
1330
|
+
console.log("");
|
|
1331
|
+
console.log("Running final verification...");
|
|
1332
|
+
console.log("");
|
|
1333
|
+
|
|
1334
|
+
await runVerify();
|
|
1335
|
+
}
|
|
1336
|
+
|
|
1292
1337
|
async function main() {
|
|
1293
1338
|
if (
|
|
1294
1339
|
!command ||
|
|
@@ -1306,6 +1351,7 @@ Usage:
|
|
|
1306
1351
|
npx paddle-checkout-accelerator verify
|
|
1307
1352
|
npx paddle-checkout-accelerator auth
|
|
1308
1353
|
npx paddle-checkout-accelerator bootstrap
|
|
1354
|
+
npx paddle-checkout-accelerator connect
|
|
1309
1355
|
npx paddle-checkout-accelerator init --minimal
|
|
1310
1356
|
`);
|
|
1311
1357
|
process.exit(0);
|
|
@@ -1327,6 +1373,10 @@ Usage:
|
|
|
1327
1373
|
await runBootstrap();
|
|
1328
1374
|
}
|
|
1329
1375
|
|
|
1376
|
+
if (command === "connect") {
|
|
1377
|
+
await runConnect();
|
|
1378
|
+
}
|
|
1379
|
+
|
|
1330
1380
|
if (command !== "init") {
|
|
1331
1381
|
console.error(
|
|
1332
1382
|
`Unknown command: ${command}`
|