You do not need Selenium for this. Check the payload needed to send along with the request in your browser and attach it with the request.
I tried this with your site, the following snippet works -
def start_requests(self):
url = "http://www.myntra.com/search-service/searchservice/search/filteredSearch"
payload = [{
"query": "(global_attr_age_group:(\"Adults-Unisex\" OR \"Adults-Women\") AND global_attr_master_category:(\"Footwear\"))",
"start": 0,
"rows": 96,
"facetField": [],
"pivotFacets": [],
"fq": ["count_options_availbale:[1 TO *]"],
"sort": [
{"sort_field": "count_options_availbale", "order_by": "desc"},
{"sort_field": "score", "order_by": "desc"},
{"sort_field": "style_store1_female_sort_field", "order_by": "desc"},
{"sort_field": "potential_revenue_female_sort_field", "order_by": "desc"},
{"sort_field": "global_attr_catalog_add_date", "order_by": "desc"}
],
"return_docs": True,
"colour_grouping": True,
"useCache": True,
"flatshot": False,
"outOfStock": False,
"showInactiveStyles": False,
"facet": True
}]
yield Request(url, self.parse, method="POST", body=json.dumps(payload))
def parse(self, response):
data = json.loads(response.body)
print data
source
share