Practice - 5 Tasks
Answer the questions below
1fill in blank
easyComplete the code to create a new monitor with a name.
Postman
pm.monitor.create({ name: [1] }); Drag options to blanks, or click blank then click option'
Attempts:
3 left
💡 Hint
Common Mistakes
Forgetting to put quotes around the monitor name.
Using a number or boolean instead of a string.
✗ Incorrect
The monitor name must be a string, so it needs quotes around it.
2fill in blank
mediumComplete the code to set the monitor schedule to run every hour.
Postman
pm.monitor.create({ schedule: { interval: [1] } }); Drag options to blanks, or click blank then click option'
Attempts:
3 left
💡 Hint
Common Mistakes
Using an unsupported interval like "daily" when hourly is needed.
Not using quotes around the interval string.
✗ Incorrect
The interval value must be the string "hourly" to run the monitor every hour.
3fill in blank
hardFix the error in the code to correctly create a monitor with a collection ID.
Postman
pm.monitor.create({ collectionId: [1] }); Drag options to blanks, or click blank then click option'
Attempts:
3 left
💡 Hint
Common Mistakes
Using the collection ID without quotes causing syntax errors.
Using boolean or null instead of a string.
✗ Incorrect
The collection ID must be a string, so it needs quotes around it.
4fill in blank
hardFill both blanks to create a monitor with a name and an environment ID.
Postman
pm.monitor.create({ name: [1], environmentId: [2] }); Drag options to blanks, or click blank then click option'
Attempts:
3 left
💡 Hint
Common Mistakes
Using numbers or booleans instead of strings.
Forgetting quotes around either value.
✗ Incorrect
Both name and environmentId must be strings, so both need quotes.
5fill in blank
hardFill all three blanks to create a monitor with a name, schedule interval, and collection ID.
Postman
pm.monitor.create({ name: [1], schedule: { interval: [2] }, collectionId: [3] }); Drag options to blanks, or click blank then click option'
Attempts:
3 left
💡 Hint
Common Mistakes
Using booleans or unquoted values causing errors.
Mixing data types for these fields.
✗ Incorrect
All values must be strings, so quotes are needed for name, interval, and collectionId.