import requests
import copy

class Client(object):
    def __init__(self, api_key):
        self.payload = {'key': api_key}
        self.url = 'https://www.googleapis.com/language/translate/v2?'
        
    def translate(self, target='es', source=None, query=None):
        payload = copy.copy(self.payload)
        if source:
            payload['source'] = source
        payload['target'] = target
        payload['q'] = query
        r = requests.get(self.url, params=payload)
        return r.json()

@@ -13,33 +13,1950 @@
 sts%0A
-import copy%0A%0Aclass Client
+%0Alangs = %7B%0A            'Afrikaans': 'af',%0A            'Albanian': 'sq',%0A            'Arabic': 'ar',%0A            'Azerbaijani': 'az',%0A            'Basque': 'eu',%0A            'Belarusian': 'be',%0A            'Bengali': 'bn',%0A            'Bulgarian': 'bg',%0A            'Catalan': 'ca',%0A            'Chinese Simplified': 'zh-CN',%0A            'Chinese Traditional': 'zh-TW',%0A            'Croatian': 'hr',%0A            'Czech': 'cs',%0A            'Danish': 'da',%0A            'Dutch': 'nl',%0A            'English': 'en',%0A            'Esperanto': 'eo',%0A            'Estonian': 'et',%0A            'Filipino': 'tl',%0A            'Finnish': 'fi',%0A            'French': 'fr',%0A            'Galician': 'gl',%0A            'Georgian': 'ka',%0A            'German': 'de',%0A            'Greek': 'el',%0A            'Gujarati': 'gu',%0A            'Haitian Creole': 'ht',%0A            'Hebrew': 'iw',%0A            'Hindi': 'hi',%0A            'Hungarian': 'hu',%0A            'Icelandic': 'is',%0A            'Indonesian': 'id',%0A            'Irish': 'ga',%0A            'Italian': 'it',%0A            'Japanese': 'ja',%0A            'Kannada': 'kn',%0A            'Korean': 'ko',%0A            'Latin': 'la',%0A            'Latvian': 'lv',%0A            'Lithuanian': 'lt',%0A            'Macedonian': 'mk',%0A            'Malay': 'ms',%0A            'Maltese': 'mt',%0A            'Norwegian': 'no',%0A            'Persian': 'fa',%0A            'Polish': 'pl',%0A            'Portuguese': 'pt',%0A            'Romanian': 'ro',%0A            'Russian': 'ru',%0A            'Serbian': 'sr',%0A            'Slovak': 'sk',%0A            'Slovenian': 'sl',%0A            'Spanish': 'es',%0A            'Swahili': 'sw',%0A            'Swedish': 'sv',%0A            'Tamil': 'ta',%0A            'Telugu': 'te',%0A            'Thai': 'th',%0A            'Turkish': 'tr',%0A            'Ukrainian': 'uk',%0A            'Urdu': 'ur',%0A            'Vietnamese': 'vi',%0A            'Welsh': 'cy',%0A            'Yiddish': 'yi'%0A        %7D%0A%0A%0Aclass Translate
 (obj
@@ -2105,24 +2105,16 @@
 te/v2?'%0A
-        
 %0A    def
@@ -2114,24 +2114,30 @@
     def 
+build_
 translat
 e(self, 
@@ -2128,17 +2128,27 @@
 translat
-e
+ion_request
 (self, t
@@ -2156,38 +2156,15 @@
 rget
-='es', source=None
 , query
-=None
 ):%0A 
@@ -2184,153 +2184,245 @@
 d = 
-copy.copy(self.payload)%0A        if source:%0A            payload%5B'source'%5D = source%0A        payload%5B'target'%5D = target%0A        payload%5B'q'%5D =
+dict(target=target, source=source, q=query, **self.payload)%0A        return payload%0A%0A    def translate(self, target='Spanish', source=None, query=None):%0A        payload = self.build_translation_request(langs%5Btarget%5D, langs%5Bsource%5D,
  query
+)
 %0A   

Add langs dict and edit translate