func New(accountSid, apiKey, apiSecret, identity string, ttl time.Duration) *AccessToken {
	return &AccessToken{
		accountSid: accountSid,
		apiKey:     apiKey,
		apiSecret:  []byte(apiSecret),
		identity:   identity,
		ttl:        ttl,
		grants:     make(map[string]interface{}),
	}
}
func New(accountSid, apiKey, apiSecret, identity string, ttl time.Duration) *AccessToken {
	return &AccessToken{
		accountSid: accountSid,
		apiKey:     apiKey,
		apiSecret:  []byte(apiSecret),
		identity:   identity,
		ttl:        ttl,
		grants:     make(map[string]interface{}),
	}
}
func New ( accountSid , apiKey , apiSecret , identity string , ttl time . Duration ) * AccessToken { return & AccessToken { accountSid : accountSid , apiKey : apiKey , apiSecret : [ ] byte ( apiSecret ) , identity : identity , ttl : ttl , grants : make ( map [ string ] interface { } ) , } }
// New generates a new AccessToken with the specified properties. identity is
// a unique ID for a particular user.
//
// To generate an apiKey and apiSecret follow this instructions:
// https://www.twilio.com/docs/api/rest/access-tokens#jwt-format
New generates a new AccessToken with the specified properties . identity is a unique ID for a particular user . To generate an apiKey and apiSecret follow this instructions : https : // www . twilio . com / docs / api / rest / access - tokens#jwt - format