Convert Postman Collection to Cypress API Tests
Migrate Postman collections to Cypress API tests using cy.request. Preserve folders, assertions, and environment variables with a free converter.

2026-07-17 · By Avinash K
Teams standardising on Cypress for both UI and API testing want their Postman work migrated once — cleanly. Here is the workflow.
1. Export & convert
Export the collection v2.1 and use the Postman → Code Converter with target "Cypress". Each folder becomes a describe; each request an it.
2. Sample output
describe('Orders API', () => {
it('creates an order', () => {
cy.request({
method: 'POST',
url: `${Cypress.env('baseUrl')}/orders`,
headers: { 'Authorization': `Bearer ${Cypress.env('token')}` },
body: { productId: 42, qty: 2 },
}).then((res) => {
expect(res.status).to.eq(201);
expect(res.body.status).to.eq('created');
});
});
});3. Environment mapping
Postman env Cypress
baseUrl Cypress.env('baseUrl')
token Cypress.env('token')Set them in cypress.config.js under env: or via --env flag.
4. Add UI + API in one spec
Log in via API in a before(), seed data via cy.request, then drive UI with cy.visit. Way faster than UI-only login for every test.