Feature Request: Add API Support for Retrieving Pod Logs
Is your feature request related to a problem? Please describe.
Yes - currently, RunPod’s API doesn’t provide access to pod logs, even though logs are available through the RunPod console. This creates a problem when automating workflows or debugging issues programmatically. For example, when provisioning a container, if an error occurs, we have no way to retrieve the logs via the API to understand what went wrong. This forces us to rely on the UI, which isn’t ideal for automated or large-scale deployments.
In cases like SkyPilot provisioning, when the container fails to start correctly, we need to see the logs to diagnose issues such as missing dependencies, incorrect environment variables, or service startup failures. Without API access to logs, we’re left guessing or repeatedly retrying without knowing the root cause.
Describe the solution you’d like
We’d like to have an API endpoint that allows us to fetch pod logs, similar to docker logs or kubectl logs. This would make it easier to programmatically diagnose issues during provisioning or runtime failures. Ideally, the API should support:
- Retrieving logs from specific pods or containers
- Filtering logs by time or line limits (e.g.,
tailfunctionality) - Optionally streaming logs for real-time monitoring
Describe alternatives you’ve considered
- Manually logging into the RunPod console to check logs, which is not scalable for automation.
Additional context
Adding API access to container logs would significantly improve the debugging experience, especially for automated workflows like SkyPilot. This would not only help quickly identify issues during the provisioning phase but also make RunPod a more robust and developer-friendly platform for large-scale deployments. Since SkyPilot already integrates with RunPod, better log visibility would enhance its support and potentially encourage more users to choose RunPod for their compute workloads.
+1 this would definitely be very useful
Hi @deanq, hope you're having a great week.
Just wanted to gently follow up on this feature request. As you can see, there's continued interest from the community in getting API access for pod logs. This would be a huge help for automated workflows and debugging, particularly for tools like SkyPilot.
Would you have a moment to take a look and perhaps share your thoughts on its feasibility or priority? We'd greatly appreciate any insights you might have.
Thanks!
Hi, having programmatic access to pod logs is definitely needed for automated monitoring at scale
Hey, this feature would be super helpful for automated workflows!