Phil Clarke

Read this first

BookNet Canada Tech Forum 2014 Reading Recommendations

It’s Complicated: The Social Lives of Networked Teens

Danah Boyd

It's Complicated: The Social Lives of Networked Teens

Creativity, Inc.: Overcoming the Unseen Forces That Stand in the Way of True Inspiration

Ed Catmull

Creativity, Inc.: Overcoming the Unseen Forces That Stand in the Way of True Inspiration by Ed Catmull

Just Enough Research (A Book Apart #9)

Erika Hall

Just Enough Research (A Book Apart #9) by Erika Hall

Smarter Than You Think: How Technology is Changing Our Minds for the Better

Clive Thompson

Smarter Than You Think: How Technology is Changing Our Minds for the Better by Clive Thompson

Continue reading →


Automating short URL creation on iOS

 Requirements

  • Drafts by Agile Tortoise
  • Pythonista by omz:software
  • A bitly API Token

 Drafts action

pythonista://shortenURL?action=run&argv=[[title]]

 Pythonista script

import urllib
import json
import webbrowser
import sys
url = sys.argv[1]
api = 'https://api-ssl.bitly.com/v3/shorten'
token = 'Insert your token here'
request = api + '?access_token=' + token + '&longURL=' + url

usock = urllib.urlopen(request)
data = usock.read()
dataJSON = json.loads(data)
shortURL = dataJSON["data"]["url"]

outputURL = 'drafts://x-callback-url/create?text=' + shortURL

webbrowser.open(outputURL)
usock.close()

 Usage

  • Create a new draft that has one line consisting of the URL to shorten
  • Run the newly created action
  • A new draft is automatically created with the short URL

 Notes

If you do not have Pythonista this could be accomplished in a slightly less automated fashion using bitly’s

Continue reading →