Completed

Scrapy website pinnacle api

Need help to scrapy pinnacle api response in json format.

The following code didn't work for me.

import scrapy

import json

import time

class ntschoolsSpider([login to view URL]):

name = 'ntschools'

start_urls =['[login to view URL]']

headers ={

"accept": "application/json",

"accept-encoding": "gzip, deflate, br",

"accept-language": "zh-CN,zh;q=0.9,en;q=0.8,en-US;q=0.7",

"cache-control": "no-cache",

"content-type": "application/json",

"origin": "[login to view URL]",

"pragma": "no-cache",

"referer": "[login to view URL]",

"sec-fetch-dest": "empty",

"sec-fetch-mode": "cors",

"sec-fetch-site": "same-site",

"user-agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/84.0.4147.135 Safari/537.36",

"x-api-key": "CmX2KcMrXuFmNg6YFbmTxE0y9CIrOi0R",

"x-device-uuid": "85df1f63-58fd26a6-3d6a328e-91531147",

"x-session": "CdX75Ec6lXrxKVVORELs3sIho0V4XhWT",

}

headers1 ={

"accept": "application/json",

"accept-encoding": "gzip, deflate, br",

"accept-language": "zh-CN,zh;q=0.9,en;q=0.8,en-US;q=0.7",

"cache-control": "no-cache",

"content-type": "application/json",

"origin": "[login to view URL]",

"pragma": "no-cache",

"referer": "[login to view URL]",

"sec-fetch-dest": "empty",

"sec-fetch-mode": "cors",

"sec-fetch-site": "same-site",

"user-agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/84.0.4147.135 Safari/537.36",

"x-api-key": "CmX2KcMrXuFmNg6YFbmTxE0y9CIrOi0R",

"x-device-uuid": "85df1f63-58fd26a6-3d6a328e-91531147",

"x-session": "CdX75Ec6lXrxKVVORELs3sIho0V4XhWT",

}

def parse(self, response):

url = '[login to view URL]'

request = [login to view URL](url,

callback=self.parse_api,

headers=[login to view URL])

[login to view URL](2)

yield request

def parse_api(self,response):

base_url='[login to view URL]'

#1766/matchups

raw_data = [login to view URL]

data = [login to view URL](raw_data)

for league in data:

group = league['group']

league_name = league['name'].replace(' ','')

match_up_count= league['matchupCount']

league_id = league['id']

league_match_url = base_url + league_id +'/matchups'

request=[login to view URL](

league_match_url, callback=self.parse_matchup,headers=[login to view URL]

)

yield request

def parse_matchup(self,response):

raw_data = [login to view URL]

data = [login to view URL](raw_data)

yield {

'ageLimit': data['ageLimit'],

'match_id': data['id'],

'home': data['participants'][0]['name'],

'away': data['participants'][1]['name'],

'startTime': data['startTime']

}

Skills: Python, Web Scraping, JavaScript

See more: github pinnacle api, scrapy cookies, scrapy tutorial, scrapy documentation, pinnacle api pricing, pinnacle api python, scrapy pagination, pinnacle api documents, ringtone website php api, need create sports betting website, shopping website php api, design website using joomla need template pages, need writers sports website, website connects people need help, api need video player symbian, multilingual website google api, website facebook api, using fasthost api need help, need writers sports, need free sports score ticker website

About the Employer:
( 1 review ) ardrossan, Canada

Project ID: #27093017

Awarded to:

alexeygamil

Hi I am Python, Javascript, Webscraping expert and I only apply to jobs when I know I can do it. I am confident that I will deliver you the best solution possible and will exceed your expectations. I never left a clie More

$140 USD in 7 days
(4 Reviews)
3.8

6 freelancers are bidding on average $149 for this job

umg536

Hi there, I'm bidding on your project "Scrapy website pinnacle api" Being an expert in Python and matlab programming I can do this project for you. please leave a message on my chat so we can discuss the budget and de More

$250 USD in 3 days
(9 Reviews)
4.9
RavenSolutions

Hello! I have went through about your project Scrapy website pinnacle api I am an expert in Web Scraping, Python and JavaScript, so I'am totally sure I can deliver Your project ! Please send a message to discuss more a More

$155 USD in 1 day
(1 Review)
3.8
vovandeveloper

Hello, I am Python web developer. I have rich knowledge of Python webscrapy. I used scrapy and selenium, pandas... to scrape a online stores and blogs. I can generated csv or txt files and make a standalone program. More

$150 USD in 7 days
(3 Reviews)
3.5
maximmironenkore

Sup! How are you today ​I specialize in web scraping jobs like this one and have a rich experience. Hire me, a professional with a rock solid reputation and best experience specifically in writing scraping code like t More

$150 USD in 3 days
(1 Review)
1.2
shekhawat1019

I have been working on scraping projects from last 7 years and have developed many scrapers using Scrapy, Splash, Selenium. I have gone through your project details and it seems you are trying to get all the leagues as More

$50 USD in 2 days
(0 Reviews)
0.0