0

I need to send a http request with requests in python. Proxy need to be in US so i get american currency. So far i did this:

import requests
proxies = {'httpс': 'httpс://97.77.104.22:3128'}

response = requests.get("https://www.ncl.com/ca/en/search_vacations?cruise=1&cruiseTour=1&cruiseHotel=1&cruiseHotelAir=1&flyCruise=1&numberOfGuests=4294953449&state=undefined&pageSize=10&currentPage=", proxies=proxies)
cruise_results = response.json()
for line in cruise_results['results']:
    print(line)

Tried with several different IP/Port combinations but i still get the EUR prices. Am i doing something wrong?

1 Answer 1

1

The proxies dictionary should have http and https keys. Not httpc

import requests
proxies = {'https': 'httpс://97.77.104.22:3128'}

response = requests.get("https://www.ncl.com/ca/en/search_vacations?cruise=1&cruiseTour=1&cruiseHotel=1&cruiseHotelAir=1&flyCruise=1&numberOfGuests=4294953449&state=undefined&pageSize=10&currentPage=", proxies=proxies)
Sign up to request clarification or add additional context in comments.

1 Comment

happens to everyone :)

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.