According to this question I understand that pathParam is parameter for path in query. But I don't understand what is the usage of that instead of writing the full path in get query like this if we have only one path anyway?
given().
baseUri("https://postman-echo.com")
.pathParam("userId", "1")
.when()
.get("/api/users/{userId}")
.then()
.log().ifError()
.assertThat()
.statusCode(200)