Skip to content

Commit

Permalink
更换免费打码接口地址 #140
Browse files Browse the repository at this point in the history
  • Loading branch information
pjialin committed Mar 7, 2019
1 parent cdedfa8 commit c87724d
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
4 changes: 2 additions & 2 deletions py12306/helpers/OCR.py
Original file line number Diff line number Diff line change
Expand Up @@ -60,9 +60,9 @@ def get_image_by_free_site(self, img):
}
response = self.session.post(API_FREE_CODE_QCR_API, json=data)
result = response.json()
if result.get('success') and result.get('check'):
if result.get('success') and result.get('data.check'):
check_data = {
'check': result.get('check'),
'check': result.get('data.check'),
'img_buf': img,
'logon': 1,
'type': 'D'
Expand Down
3 changes: 2 additions & 1 deletion py12306/helpers/api.py
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,8 @@
API_NOTIFICATION_BY_VOICE_CODE = 'http://ali-voice.showapi.com/sendVoice?'
API_NOTIFICATION_BY_VOICE_CODE_DINGXIN = 'http://yuyin2.market.alicloudapi.com/dx/voice_notice'

API_FREE_CODE_QCR_API = 'http://60.205.200.159/api'
# API_FREE_CODE_QCR_API = 'http://60.205.200.159/api' # 19-03-07 接口已失效
API_FREE_CODE_QCR_API = 'https://12306.jiedanba.cn/api/v2/getCheck'
API_FREE_CODE_QCR_API_CHECK = 'http://check.huochepiao.360.cn/img_vcode'

API_CHECK_CDN_AVAILABLE = 'https://{}/otn/dynamicJs/omseuuq'

0 comments on commit c87724d

Please sign in to comment.