|
|
|
@ -28,6 +28,9 @@ parser = HTMLtoBBcode() |
|
|
|
with open(CREDENTIALS_FILE, 'r') as fp: |
|
|
|
config = json.load(fp) |
|
|
|
|
|
|
|
@app.route('/') |
|
|
|
def webhook_home(): |
|
|
|
return "<h1>Hello world</h1>" |
|
|
|
|
|
|
|
@app.route('/wordpress_webhook', methods=['POST']) |
|
|
|
def webhook_handler(): |
|
|
|
@ -50,13 +53,13 @@ def webhook_handler(): |
|
|
|
|
|
|
|
logger.info(post_BB) |
|
|
|
|
|
|
|
outcome = post_HFR(config['user'], |
|
|
|
config['user_hash'], |
|
|
|
config['posturl'], |
|
|
|
post_BB) |
|
|
|
#outcome = post_HFR(config['user'], |
|
|
|
# config['user_hash'], |
|
|
|
# config['posturl'], |
|
|
|
# post_BB) |
|
|
|
|
|
|
|
logger.info(outcome) |
|
|
|
logger.info(outcome.text) |
|
|
|
#logger.info(outcome) |
|
|
|
#logger.info(outcome.text) |
|
|
|
|
|
|
|
return '' |
|
|
|
|
|
|
|
|