Understanding Chat completions API limitations for File uploads

I am working on an agentic application and use Gemini API for powering the application. I need to know the exact file upload limits (size, number, etc) for all kinds of files supported by Gemini. For this I need an answer to these questions.

  • Are the 10-file upload limits only for the Gemini UI, and not enforced by the model itself when using the API?

  • When calling the model via the API, is there no hard limit on the number of files you can include in a single request (aside from context size and file size)?

  • What are the official backend/API limits for file uploads (file count, file size, total data)?