Bird
Raised Fist0
Postmantesting~8 mins

Duplicating and moving requests in Postman - Framework Patterns

Choose your learning style10 modes available
Framework Mode - Duplicating and moving requests
Folder Structure
Postman Collection
├── Folder 1
│   ├── Request A
│   └── Request B
├── Folder 2
│   ├── Request C
│   └── Request D
└── Environment Variables
    ├── Dev Environment
    └── Prod Environment
Test Framework Layers
  • Collections: Group related requests for organization and execution.
  • Folders: Subdivide collections to manage requests logically.
  • Requests: Individual API calls with method, URL, headers, and body.
  • Environment Variables: Store dynamic data like URLs, tokens for different environments.
  • Scripts: Pre-request and test scripts to automate checks and setup.
Configuration Patterns
  • Environments: Use environment files to switch base URLs, credentials, and tokens easily.
  • Global Variables: Store values accessible across collections and requests.
  • Collection Variables: Variables scoped to a collection for modularity.
  • Request Duplication: Duplicate requests to create variations without rewriting.
  • Moving Requests: Drag and drop requests between folders or collections to reorganize.
Test Reporting and CI/CD Integration
  • Postman Test Results: View pass/fail status in the Postman app after running collections.
  • Newman CLI: Run collections from command line and generate JSON, HTML reports.
  • CI/CD Integration: Use Newman in pipelines (GitHub Actions, Jenkins) to automate API testing.
  • Report Sharing: Export and share reports with team for visibility.
Best Practices
  • Use descriptive names for requests and folders to keep collections clear.
  • Duplicate requests when testing similar endpoints with different data to save time.
  • Organize requests by feature or API resource using folders for easy navigation.
  • Keep environment variables updated to avoid hardcoding sensitive data.
  • Regularly clean up unused requests to maintain a tidy workspace.
Self Check

Where in this folder structure would you add a new duplicated request for testing a different user role?

Key Result
Organize API tests in Postman by duplicating and moving requests within collections and folders for clarity and reuse.

Practice

(1/5)
1. What is the main benefit of duplicating a request in Postman?
easy
A. It exports the request to a file.
B. It saves time by reusing an existing request setup.
C. It merges two requests into one.
D. It deletes the original request automatically.

Solution

  1. Step 1: Understand duplicating requests

    Duplicating means making a copy of an existing request to reuse its setup.
  2. Step 2: Identify the benefit

    Reusing saves time because you don't have to create the request from scratch.
  3. Final Answer:

    It saves time by reusing an existing request setup. -> Option B
  4. Quick Check:

    Duplicating = Reuse setup [OK]
Hint: Duplicating means copying to reuse quickly [OK]
Common Mistakes:
  • Thinking it deletes the original request
  • Confusing duplication with merging requests
  • Assuming it exports the request
2. Which of the following is the correct way to duplicate a request in Postman?
easy
A. Rename the request with a new name.
B. Drag the request to the trash bin.
C. Click 'Send' button twice quickly.
D. Right-click the request and select 'Duplicate'.

Solution

  1. Step 1: Locate duplication method

    In Postman, duplicating is done by right-clicking the request and choosing 'Duplicate'.
  2. Step 2: Eliminate wrong options

    Dragging to trash deletes, clicking send sends request, renaming changes name only.
  3. Final Answer:

    Right-click the request and select 'Duplicate'. -> Option D
  4. Quick Check:

    Duplicate = Right-click + Duplicate [OK]
Hint: Right-click request to duplicate it [OK]
Common Mistakes:
  • Trying to duplicate by clicking send
  • Dragging request to trash instead of duplicating
  • Thinking renaming duplicates the request
3. Given a collection with requests A, B, and C, you duplicate request B and move the duplicate to a new folder named 'Tests'. What will be the order of requests in the original collection and the new folder?
medium
A. Original collection: A, B, C; New folder: B (duplicate)
B. Original collection: A, C; New folder: B (original and duplicate)
C. Original collection: A, B, C; New folder: empty
D. Original collection: A, B; New folder: C, B (duplicate)

Solution

  1. Step 1: Understand duplication effect

    Duplicating request B creates a copy but does not remove the original from the collection.
  2. Step 2: Understand moving the duplicate

    Moving the duplicate to 'Tests' folder places only the copy there; original stays in the main collection.
  3. Final Answer:

    Original collection: A, B, C; New folder: B (duplicate) -> Option A
  4. Quick Check:

    Duplicate copy moved; original stays [OK]
Hint: Duplicate copies; moving affects only the copy [OK]
Common Mistakes:
  • Assuming original is removed when duplicate is moved
  • Thinking duplicate appears in both places
  • Confusing original and duplicate requests
4. You tried to move a request to another folder in Postman but it did not move. What is the most likely reason?
medium
A. You dragged the request outside any folder accidentally.
B. The request is locked and cannot be moved.
C. You duplicated the request instead of moving it.
D. Postman does not support moving requests between folders.

Solution

  1. Step 1: Check Postman folder behavior

    Postman allows moving requests by dragging them into folders.
  2. Step 2: Identify common mistake

    Dragging outside any folder leaves the request in the original place, so it appears not moved.
  3. Final Answer:

    You dragged the request outside any folder accidentally. -> Option A
  4. Quick Check:

    Drag inside folder to move [OK]
Hint: Drag request carefully inside target folder [OK]
Common Mistakes:
  • Confusing duplication with moving
  • Assuming requests can be locked
  • Believing Postman disallows moving requests
5. You have a collection with 5 requests. You want to create a new folder and move 3 specific requests into it, but also keep duplicates of those 3 requests in the original collection. What is the correct sequence of actions in Postman?
hard
A. Delete the 3 requests, then create new ones in the folder.
B. Move the 3 requests into the new folder, then duplicate them back to the original collection.
C. Duplicate the 3 requests, then move the duplicates into the new folder.
D. Rename the 3 requests and drag them into the new folder.

Solution

  1. Step 1: Understand requirement

    You want duplicates in the new folder and originals to remain in place.
  2. Step 2: Choose correct order

    Duplicating first creates copies; moving duplicates places them in the folder without removing originals.
  3. Step 3: Eliminate wrong options

    Moving first removes originals from collection; deleting loses data; renaming doesn't duplicate.
  4. Final Answer:

    Duplicate the 3 requests, then move the duplicates into the new folder. -> Option C
  5. Quick Check:

    Duplicate first, then move duplicates [OK]
Hint: Duplicate first, then move copies to folder [OK]
Common Mistakes:
  • Moving first removes originals
  • Deleting requests instead of duplicating
  • Thinking renaming duplicates requests
Recommended

Ready to prove it?

Pass the test and this pattern moves unknown strong while earning +1 Grip toward your certificate.

10 questions~5 mineasy hard