Files
Daniel Salazar aef0a32d72 fix(ai): hold credits for image and video generation (#4164)
Image and video providers checked the balance with hasEnoughCredits /
getRemainingUsage and took no hold, so concurrent requests each saw the
full balance until the first one recorded usage. They now reserve the
estimate through the cost-factored reserveAiCredits and release it in a
finally block once usage is recorded, like chat, speech and OCR.

The video duration clamp now prices seconds at the model's cost factor
and holds the clamped clip's cost for the job (poll window plus create
time). Replicate holds the output-only estimate before fetching inputs
and the input surcharge on top once it is measured.
2026-10-11 09:18:13 -07:00
..
2026-10-03 10:27:23 +07:00
…

Puter.js Docs

Docs · Developer · Puter.com · X

screenshot


Puter.js Docs

The Puter.js documentation contains everything you need to build powerful applications with Puter.js.

  • Get started with Puter.js by reading documentations on usage and best practices
  • Browse all available APIs, including AI, networking, authentication, and cloud services
  • Find code examples and implementations to speed up your development

Getting Started

💻 Local Development

git clone https://github.com/HeyPuter/docs
cd docs
npm install
npm run dev

→ This should launch Puter.js Docs at http://127.0.0.1:8080 (or the next available port).


Support

Connect with the maintainers and community through these channels:

We are always happy to help you with any questions you may have. Don't hesitate to ask!


License

This repository, including its sub-projects, modules, and components, is licensed under MIT, and its content is licensed under CC BY-SA 4.0 unless explicitly stated otherwise. Third-party libraries included in this repository may be subject to their own licenses.