This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$users = array("+15556667777", "+15556667778"); | |
require_once('auth.php'); | |
require_once('Services/Twilio.php'); | |
$body = $_REQUEST['Body']; | |
$from = $_REQUEST['From']; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
host.brooklynhacker.com: | |
Data failed to compile: | |
---------- | |
Pillar failed to render with the following messages: | |
---------- | |
Rendering SLS 'mysql' failed, render error: | |
found undefined alias 'Bxxxxxxxxxxxxxxxxxxxxxxxxxxx' | |
in "<unicode string>", line 2, column 18: | |
root_password: *Bxxxxxxxxxxxxxxxxxxxxxxx ... |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from flask import Flask | |
from flask import request | |
from twilio import twiml | |
app = Flask(__name__) | |
@app.route('/gather', methods=['POST']) | |
def gather(): | |
response = twiml.Response() |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
packages: | |
pkg.installed: | |
- names: | |
- python | |
- python-dev | |
- python-pip | |
pip-upgrade: | |
pip.installed: | |
- upgrade: True |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
vim-deps: | |
pkg.installed: | |
- names: | |
- exuberant-ctags | |
- require_in: | |
- pkg: vim | |
vim-vundle: | |
git.latest: | |
- name: git://github.com/gmarik/vundle.git |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import unittest | |
from mock import patch | |
import mymodule | |
class APITest(unittest.TestCase): | |
@patch('requests.get') | |
def test_wrapped_example(self, MockRequests): | |
mock_request = MockRequests() | |
# Set your status code you want to test against |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from flask import Flask | |
from twilio import twiml | |
# First, we'll add your favorite HTTP client and mine, Requests | |
import requests | |
app = Flask(__name__) | |
# First, we give our app the key we retrieved from the | |
# New York Times API developer dashboard | |
app.config['NYTIMES_API_KEY'] = "key_we_registered" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from flask import Flask | |
from twilio import twiml | |
app = Flask(__name__) | |
# Let's adjust this route to create a custom wait | |
# experience for our conference call. | |
@app.route('/conference', methods=['POST']) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Import our dependencies | |
from flask import Flask | |
from twilio import twiml | |
# Instantiate our Flask app | |
app = Flask(__name__) | |
# Create an endpoint '/conference' to serve as our |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from flask import Flask | |
from flask import render_template | |
app = Flask(__name__) | |
@app.route('/') | |
def index(): | |
return render_template('index.html') | |
if __name__ == "__main__": |