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
$ curl https://api.opencnam.com/v2/phone/+16502530000?format=yaml | |
{created: !!python/unicode '2012-09-23T16:19:56.265300', name: !!python/unicode 'GOOGLE INC', number: !!python/unicode '+16502530000', price: 0, updated: !!python/unicode '2012-10-23T23:46:23.036676', uri: /v2/phone/%2B16502530000} | |
$ curl -H "Accept: text/yaml" https://api.opencnam.com/v2/phone/+16502530000 | |
{created: !!python/unicode '2012-09-23T16:19:56.265300', name: !!python/unicode 'GOOGLE INC', number: !!python/unicode '+16502530000', price: 0, updated: !!python/unicode '2012-10-23T23:46:23.036676', uri: /v2/phone/%2B16502530000} |
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
$ curl https://api.opencnam.com/v2/phone/+16502530000?format=xml | |
<?xml version='1.0' encoding='utf-8'?> | |
<phone><number>+16502530000</number><name>GOOGLE INC</name><created>2012-09-23T16:19:56.265300</created><updated>2012-10-23T23:46:23.036676</updated><price>0</price><uri>/v2/phone/%2B16502530000</uri></phone> | |
$ curl -H "Accept: application/xml" https://api.opencnam.com/v2/phone/+16502530000 | |
<?xml version='1.0' encoding='utf-8'?> | |
<phone><number>+16502530000</number><name>GOOGLE INC</name><created>2012-09-23T16:19:56.265300</created><updated>2012-10-23T23:46:23.036676</updated><price>0</price><uri>/v2/phone/%2B16502530000</uri></phone> |
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
$ curl https://api.opencnam.com/v2/phone/+16502530000?format=jsonp | |
callback({"updated": "2012-10-23T23:46:23.036676", "name": "GOOGLE INC", "created": "2012-09-23T16:19:56.265300", "price": 0, "uri": "/v2/phone/%2B16502530000", "number": "+16502530000"}) | |
$ curl -H "Accept: text/javascript" https://api.opencnam.com/v2/phone/+16502530000 | |
callback({"updated": "2012-10-23T23:46:23.036676", "name": "GOOGLE INC", "created": "2012-09-23T16:19:56.265300", "price": 0, "uri": "/v2/phone/%2B16502530000", "number": "+16502530000"}) |
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
$ curl https://api.opencnam.com/v2/phone/+16502530000?format=json | |
{ | |
"updated": "2012-10-23T23:46:23.036676", | |
"name": "GOOGLE INC", | |
"created": "2012-09-23T16:19:56.265300", | |
"price": 0, | |
"uri": "/v2/phone/%2B16502530000", | |
"number": "+16502530000" | |
} |
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
$ curl https://api.opencnam.com/v2/phone/+16502530000?format=pbx | |
GOOGLE INC | |
$ curl -H "Accept: text/pbx" https://api.opencnam.com/v2/phone/+16502530000 | |
GOOGLE INC |
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
$ curl https://api.opencnam.com/v2/phone/+16502530000?format=text | |
GOOGLE INC | |
$ curl -H "Accept: text/plain" https://api.opencnam.com/v2/phone/+16502530000 | |
GOOGLE INC |
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
$ curl https://api.opencnam.com/v2/phone/+16502530000?format=html | |
GOOGLE INC | |
$ curl -H "Accept: text/html" https://api.opencnam.com/v2/phone/+16502530000 | |
GOOGLE INC |
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
https://api.opencnam.com/v2/phone/<number> |
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
"""Flask URL configuration example.""" | |
from myapp import app | |
@app.route('/create') | |
def create_account(): | |
pass | |
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
"""Django URL configuration example.""" | |
from django.conf.urls.defaults import patterns, url | |
urlpatterns = patterns('apps.accounts.views', | |
url(r'^create/$', 'create_account', name='create_account'), | |
url(r'^delete/$', 'delete_account', name='delete_account'), | |
url(r'^edit/$', 'edit_account', name='edit_account'), | |
) |