Guest User

Untitled

a guest
Jul 19th, 2018
84
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.62 KB | None | 0 0
  1. "success": true,
  2. "serverName": "mma.tour.com",
  3. "data": [
  4. [
  5. "01.08.2018",
  6. [
  7. "01.08"
  8. ],
  9. "ะกั€",
  10. 8,
  11. "09.08",
  12. [....... etc
  13.  
  14. public static JsonObject clientTest() {
  15. Vertx vertx = Vertx.vertx();
  16.  
  17. WebClient client = WebClient.create(vertx);
  18.  
  19. client
  20. .get("https://www.mma-tour.com/tariffsearch/getResult?" +
  21. "priceMin=0&priceMax=1500000&currency=533067&nightsMin=6&nightsMax=8" +
  22. "&hotelClassId=269506&accommodationId=2&rAndBId=15350&tourType=1&" +
  23. "locale=ru&cityId=786&countryId=1104&after=01.08.2018&before=01.08.2018&" +
  24. "hotelInStop=false&specialInStop=false&version=2&tourId=1285&" +
  25. "tourId=12689&tourId=12706&tourId=143330&tourId=9004247&" +
  26. "tourId=4433&tourId=5736&tourId=139343&tourId=4434&tourId=12691&" +
  27. "tourId=21301&tourId=12705&tourId=149827&tourId=4151426&hotelClassBetter=true&" +
  28. "rAndBBetter=true&noTicketsTo=false&noTicketsFrom=false&searchTypeId=3&" +
  29. "recommendedFlag=false&salePrivateFlag=false&onlineConfirmFlag=false&contentCountryId=1102")
  30. .send(ar -> {
  31. if (ar.succeeded()) {
  32. // Obtain response
  33. HttpResponse<Buffer> response = ar.result();
  34. Tour tour = new Tour.TourBuilder().build();
  35. JsonObject myTourJson = response.bodyAsJsonObject();
  36. myTourJson.getJsonArray("data"); //here
  37.  
  38. } else {
  39. }
  40. });
  41. return null;
  42. }
Add Comment
Please, Sign In to add comment