class SocialMedia:
    def __init__(self):
        pass
    
    def GetSocialMediaSites_NiceNames(self):
        return {
			'add.this':'AddThis',
			'blogger':'Blogger',
			'buffer':'Buffer',
			'diaspora':'Diaspora',
			'digg':'Digg',
			'douban':'Douban',
			'email':'EMail',
			'evernote':'EverNote',
			'getpocket':'Pocket',
			'facebook':'FaceBook',
			'flattr':'Flattr',
			'flipboard':'FlipBoard',
			'google.bookmarks':'GoogleBookmarks',
			'instapaper':'InstaPaper',
			'line.me':'Line.me',
			'linkedin':'LinkedIn',
			'livejournal':'LiveJournal',
			'gmail':'GMail',
			'hacker.news':'HackerNews',
			'ok.ru':'OK.ru',
			'pinterest.com':'Pinterest',
			'google.plus':'GooglePlus',
			'qzone':'QZone',
			'reddit':'Reddit',
			'renren':'RenRen',
			'skype':'Skype',
			'sms':'SMS',
			'stumbleupon':'StumbleUpon',
			'surfingbird.ru':'SurfingBird.ru',
			'telegram.me':'Telegram.me',
			'threema':'Threema',
			'tumblr':'Tumblr',
			'twitter':'Twitter',
			'vk':'VK',
			'weibo':'Weibo',
			'xing':'Xing',
			'yahoo':'Yahoo',
        }

    def GetSocialMediaSites_WithShareLinks_OrderedByPopularity(self):
        return [
			'google.plus',
			'google.bookmarks',
			'facebook',
			'reddit',
			'twitter',
			'linkedin',
			'tumblr',
			'pinterest',
			'blogger',
			'livejournal',
			'evernote',
			'add.this',
			'getpocket',
			'hacker.news',
			'stumbleupon',
			'digg',
			'buffer',
			'flipboard',
			'instapaper',
			'surfingbird.ru',
			'flattr',
			'diaspora',
			'qzone',
			'vk',
			'weibo',
			'ok.ru',
			'douban',
			'xing',
			'renren',
			'threema',
			'sms',
			'line.me',
			'skype',
			'telegram.me',
			'email',
			'gmail',
			'yahoo',
		]
	
    def GetSocialMediaSites_WithShareLinks_OrderedByAlphabet(self):
        socialmediasites = self.GetSocialMediaSites_NiceNames().keys()
        socialmediasites.sort()
        return socialmediasites
    
    def GetSocialMediaSiteLinks_WithShareLinks(self, args):
        safeargs = [
            'url',
            'title',
            'image',
            'desc',
            'appid',
            'redirecturl',
            'via',
            'hash_tags',
            'provider',
            'language',
            'user_id',
            'category',
            'phone_number',
            'email_address',
            'cc_email_address',
            'bcc_email_address',
        ]
        
        for safearg in safeargs:
            if not args.get(safearg):
                args[safearg] = ''
        
        text = args['title']
        
        if len(args['desc']):
            text += '%20%3A%20' + args['desc']

        return {
            'add.this':'http://w...content-available-to-author-only...s.com/bookmark.php?url=' + args['url'],
            'blogger':'https://w...content-available-to-author-only...r.com/blog-this.g?u=' + args['url'] + '&n=' + args['title'] + '&t=' + args['desc'],
            'buffer':'https://b...content-available-to-author-only...r.com/add?text=' + text + '&url=' + args['url'],
            'diaspora':'https://s...content-available-to-author-only...n.org/?title=' + args['title'] + '&url=' + args['url'],
            'digg':'http://d...content-available-to-author-only...g.com/submit?url=' + args['url'] + '&title=' + text,
            'douban':'http://w...content-available-to-author-only...n.com/recommend/?url=' + args['url'] + '&title=' + text,
            'email':'mailto:' + args['email_address'] + '?subject=' + args['title'] + '&body=' + args['desc'],
            'evernote':'http://w...content-available-to-author-only...e.com/clip.action?url=' + args['url'] + '&title=' + text,
            'getpocket':'https://g...content-available-to-author-only...t.com/edit?url=' + args['url'],
            'facebook':'http://w...content-available-to-author-only...k.com/sharer.php?u=' + args['url'],
            'flattr':'https://f...content-available-to-author-only...r.com/submit/auto?user_id=' + args['user_id'] + '&url=' + args['url'] + '&title=' + args['title'] + '&description=' + text + '&language=' + args['language'] + '&tags=' + args['hash_tags'] + '&hidden=HIDDEN&category=' + args['category'],
            'flipboard':'https://s...content-available-to-author-only...d.com/bookmarklet/popout?v=2&title=' + text + '&url=' + args['url'], 
            'gmail':'https://mail.google.com/mail/?view=cm&to=' + args['email_address'] + '&su=' + args['title'] + '&body=' + args['url'] + '&bcc=' + args['bcc_email_address'] + '&cc=' + args['cc_email_address'],
            'google.bookmarks':'https://www.google.com/bookmarks/mark?op=edit&bkmk=' + args['url'] + '&title=' + args['title'] + '&annotation=' + text + '&labels=' + args['hash_tags'] + '',
            'instapaper':'http://w...content-available-to-author-only...r.com/edit?url=' + args['url'] + '&title=' + args['title'] + '&description=' + args['desc'],
            'line.me':'https://l...content-available-to-author-only...e.me/share/ui?url=' + args['url'] + '&text=' + text,
            'linkedin':'https://w...content-available-to-author-only...n.com/shareArticle?mini=true&url=' + args['url'] + '&title=' + args['title'] + '&summary=' + text + '&source=' + args['provider'],
            'livejournal':'http://w...content-available-to-author-only...l.com/update.bml?subject=' + text + '&event=' + args['url'],
            'hacker.news':'https://n...content-available-to-author-only...r.com/submitlink?u=' + args['url'] + '&t=' + args['title'],
            'ok.ru':'https://c...content-available-to-author-only...k.ru/dk?st.cmd=WidgetSharePreview&st.shareUrl=' + args['url'],
            'pinterest':'http://p...content-available-to-author-only...t.com/pin/create/button/?url=' + args['url'] ,
            'google.plus':'https://plus.google.com/share?url=' + args['url'] + '&text=' + text,
            'qzone':'http://s...content-available-to-author-only...q.com/cgi-bin/qzshare/cgi_qzshare_onekey?url=' + args['url'],
            'reddit':'https://r...content-available-to-author-only...t.com/submit?url=' + args['url'] + '&title=' + args['title'],
            'renren':'http://w...content-available-to-author-only...n.com/dialog/share?resourceUrl=' + args['url'] + '&srcUrl=' + args['url'] + '&title=' + text + '&description=' + args['desc'],
            'skype':'https://w...content-available-to-author-only...e.com/share?url=' + args['url'] + '&text=' + text,
            'sms':'sms:' + args['phone_number'] + '?body=' + text,
            'stumbleupon':'http://w...content-available-to-author-only...n.com/submit?url=' + args['url'] + '&title=' + text,
            'surfingbird.ru':'http://s...content-available-to-author-only...d.ru/share?url=' + args['url'] + '&description=' + args['desc'] + '&screenshot=' + args['image'] + '&title=' + args['title'],
            'telegram.me':'https://content-available-to-author-only.me/share/url?url=' + args['url'] + '&text=' + text + '&to=' + args['phone_number'],
            'threema':'threema://compose?text=' + text + '&id=' + args['user_id'],
            'tumblr':'https://w...content-available-to-author-only...r.com/widgets/share/tool?canonicalUrl=' + args['url'] + '&title=' + args['title'] + '&caption=' + args['desc'] + '&tags=' + args['hash_tags'],
            'twitter':'https://t...content-available-to-author-only...r.com/intent/tweet?url=' + args['url'] + '&text=' + text + '&via=' + args['via'] + '&hashtags=' + args['hash_tags'],
            'vk':'http://content-available-to-author-only.com/share.php?url=' + args['url'] + '&title=' + args['title'] + '&comment=' + args['desc'],
            'weibo':'http://s...content-available-to-author-only...o.com/share/share.php?url=' + args['url'] + '&appkey=&title=' + args['title'] + '&pic=&ralateUid=',
            'xing':'https://w...content-available-to-author-only...g.com/app/user?op=share&url=' + args['url'],
            'yahoo':'http://c...content-available-to-author-only...o.com/?to=' + args['email_address'] + '&subject=' + args['title'] + '&body=' + text,
        }

sm = SocialMedia()
#socialmediasites = sm.GetSocialMediaSites_WithShareLinks_OrderedByAlphabet()
socialmediasites = sm.GetSocialMediaSites_WithShareLinks_OrderedByPopularity()
socialmediaurls = sm.GetSocialMediaSiteLinks_WithShareLinks({
	'url':'http://w...content-available-to-author-only...t.com/',
    'title':'EarthFluent',
})
#print(socialmediaurls['add.this'])
#print(socialmediaurls.keys())

for socialmediasite in socialmediasites:
    print(socialmediasite + " : " + socialmediaurls[socialmediasite])
    pass