Hi,
I have tried to use dynamic variables for images as stated in documentation Use dynamic variables to return randomly generated data | Postman Learning Center
I have used console to see the output:
console.log(pm.variables.replaceIn('{{$randomAvatarImage}}'));
console.log(pm.variables.replaceIn('{{$randomPeopleImage}}'));
console.log(pm.variables.replaceIn('{{$randomAbstractImage}}'));
console.log(pm.variables.replaceIn('{{$randomAnimalsImage}}'));
console.log(pm.variables.replaceIn('{{$randomBusinessImage}}'));
console.log(pm.variables.replaceIn('{{$randomFoodImage}}'));
console.log(pm.variables.replaceIn('{{$randomSportsImage}}'));
console.log(pm.variables.replaceIn('{{$randomTransportImage}}'));
The output does not contain any valid image URL. Examples:
βhttps://cdn.fakercloud.com/avatars/buleswapnil_128.jpgβ
βhttp://placeimg.com/640/480/peopleβ
βhttp://placeimg.com/640/480/abstractβ
βhttp://placeimg.com/640/480/animalsβ
βhttp://placeimg.com/640/480/businessβ
βhttp://placeimg.com/640/480/foodβ
βhttp://placeimg.com/640/480/sportsβ
βhttp://placeimg.com/640/480/transportβ
- Potentially unsafe URL in the first variable, that is blocked by Chrome.
- Placeimg.com is deprecated since July 2023.
Is it an oversight? Or the aim of these variables is just to generate any URL without ensuring there is really an image?
Thank you!