This directory contains a merged Postman collection that combines both the collection and environment variables, making it ready to run with Newman.
- 
merged_collection_for_newman.json- The merged collection file that includes:- All environment variables from DC_Dev_Setup.postman_environment.json
- All requests from New Presigned.postman_collection.json
- Test scripts and authentication
 
- All environment variables from 
- 
run_with_newman.bat- Windows batch script to run the collection
- 
run_with_newman.ps1- PowerShell script to run the collection
- 
README.md- This instruction file
run_with_newman.bat.\run_with_newman.ps1newman run merged_collection_for_newman.json --reporters cli,html --reporter-html-export report_newman.html- Node.js - Make sure Node.js is installed on your system
- Newman - The scripts will automatically install Newman if it's not already installed
The merged collection contains two requests:
- 
"OneTime and manual" - A POST request that: - Sends farmer data to the staging environment
- Uses Bearer token authentication
- Extracts the presigned URL from the response
- Runs various tests to validate the response
 
- 
"presigned" - A PUT request that: - Uploads a file using the presigned URL from the previous request
- Uses form-data to upload the file
- Runs performance and validation tests
 
The merged collection includes all environment variables:
- STAGINGHOST: http://51.20.115.76:3344/api/v1
- DEVHOST: http://164.160.187.141:3344/api/v1/
- PRODHOST: http://16.171.24.129:3344/api/v1/
- LOCALHOST: http://localhost:3344/api/v1/
- LERSHAHOST: http://164.160.187.141:7000/api/
- LERSH_APIKEY: e8e44e0492ce7e6ce1ab3c5a9638ccaf1374412764624ce87b56290a9ce5083c
- presignedUrl: (dynamically set by the first request)
- And other variables for JWT tokens
After running the collection, you'll get:
- Console output showing test results
- An HTML report file (report_newman.html) with detailed test results
- The collection uses the staging environment by default (STAGINGHOST)
- The file upload uses dc_large_83.zipfrom thefiles/directory
- All authentication tokens and sensitive data are preserved in the merged file
- The collection will run both requests in sequence, with the second request using the presigned URL from the first request's response