webscriptio/lib — pull request #1 by devinrader (2013-01-12 18:54:38+00:00)
Title: Added the ability to generate Twilio capability tokens, which are used by Twilio Client

Added two files:

- twilio.capability.lua - Twilio Capability API
- jwt.lua - JSON Web Token generator

Usage looks like this:

twilioCapability = require('devinrader/lib/twilio.capability.lua')

twilioCapability.initialize("[YOUR_ACCOUNT_SID]","[YOUR_AUTH_TOKEN]")
twilioCapability.allowClientIncoming("bob")
twilioCapability.allowClientOutgoing("[APP_ID]")
return twilioCapability.generateToken(3600)