@pollinations/cli 0.1.54 → 0.1.55
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.
- package/dist/index.js +7 -4
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -14,7 +14,7 @@ var init_package = __esm({
|
|
|
14
14
|
"package.json"() {
|
|
15
15
|
package_default = {
|
|
16
16
|
name: "@pollinations/cli",
|
|
17
|
-
version: "0.1.
|
|
17
|
+
version: "0.1.55",
|
|
18
18
|
description: "The Pollinations CLI \u2014 for humans, AI agents, and everything in between",
|
|
19
19
|
type: "module",
|
|
20
20
|
bin: {
|
|
@@ -959,9 +959,12 @@ async function budgetHint(status4, bodyText) {
|
|
|
959
959
|
`Server said: ${bodyText}`
|
|
960
960
|
].join("\n");
|
|
961
961
|
}
|
|
962
|
-
const balance = await gen(
|
|
963
|
-
|
|
964
|
-
|
|
962
|
+
const balance = await gen(
|
|
963
|
+
"/account/balance",
|
|
964
|
+
{
|
|
965
|
+
apiKey: requireKey()
|
|
966
|
+
}
|
|
967
|
+
).then((r) => r.accountBalance?.total).catch(() => null);
|
|
965
968
|
const lines = [
|
|
966
969
|
code === "INSUFFICIENT_BALANCE" ? "Insufficient pollen balance." : "Check your pollen balance and API key budget.",
|
|
967
970
|
"Balance: https://enter.pollinations.ai/pollen",
|