Need to run Postman Collection on schedule, but can't leverage Postman Scheduler since it runs in Postman Cloud and these endpoints can only be reached behind a VPN. Help! How to schedule the postman collection

My question: I want to run my Postman Collection using the Schedule feature in Runs. But, the endpoints can only be reached when behind a certain VPN. When the scheduler runs postman collections, it is run the Postman Cloud, and isn’t run behind the required VPN, so I get the ECONNRESET error. Help please!!

Update: someone from Postman told me this:
From my understanding, you cannot leverage our scheduler because the endpoint is private.

We have users implement a cron script with either (Postman CLI or Newman) on a server.

However, I’m unsure if this would be by creating a Postman API or utilizing the Monitor.

Details (like screenshots):

How I found the problem:

I’ve already tried:

Hey @catherinewills-denve !

Yes, you’re right. When using the Postman Collection Runner (the scheduling feature you’re referencing), the collections are run on Postman’s own cloud infrastructure, and we don’t have access to your private network or VPN.

A potential solution would be to set up a proxy server that is accessible from both the Postman cloud and your internal network. This server would need to be set up to forward requests from Postman to the intended endpoint through the VPN. Essentially, it would act as a bridge between Postman’s cloud servers and your internal network.

Using a proxy in this manner does introduce some security concerns. The proxy would be a publicly accessible endpoint that routes requests into your internal network. Proper authentication, rate limiting, logging, and possibly even content inspection might be necessary to ensure that this proxy does not become a security vulnerability.

If setting up such a proxy is not feasible or desired due to security or other concerns, you may consider alternatives. One alternative would be using the Postman CLI or Newman, to run the collections locally (on a machine that’s connected to the VPN) and perhaps automate this using a CI/CD tool or task scheduler.

1 Like

Thanks Kevin! This is very helpful.

We wouldn’t want this API to be redeployed nightly (aka run on CICD). But can you further explain the task scheduler?

Or is there a way to utilize Postman API for my API to ping nightly on a schedule and run my Postman collection.


So you could set up a task with windows task scheduler or a cron job to execute a Newman command.

Here’s a basic step-by-step:

  1. First, ensure you’ve installed Newman on your machine.
  2. Export your Postman collection and the required environment (if any) as JSON files.
  3. Create a simple batch script or command-line instruction to use Newman to run your collection.
    newman run path_to_your_collection.json -e path_to_your_environment.json
  4. Open Task Scheduler and create a new task.
  5. Define when you want the task to run (e.g., nightly at a specific time).
  6. For the task action, select “Start a program” and input the command to run the script or Newman command.
  7. Make sure the machine will be powered on and connected to the VPN during the scheduled time, and the Task Scheduler will handle the execution.

Postman’s API is more about managing and accessing Postman resources (like collections, environments, etc.) programmatically, rather than executing them. You won’t be able to run a Postman collection directly through the Postman API in a way that would bypass the connectivity issues you’re experiencing with Postman’s cloud runner.
To automate the running of your Postman collection, using a task scheduler on a machine that’s connected to the required VPN would be the most straightforward approach.

I hope that clears things up. If you have any more questions or need further clarification, please don’t hesitate to ask! :slight_smile: