       params = json.loads(conf)
       auth = 'Basic %s' % plpy.execute("SELECT cartodb._CDB_Group_API_Auth('%s', '%s') as auth" % (params['username'], params['password']))[0]['auth']
       return { "host": params['host'], "port": params['port'], 'timeout': params['timeout'], 'auth': auth }
-      # return params
 $$ LANGUAGE 'plpythonu' VOLATILE;
 
 CREATE OR REPLACE

    base64.encodestring('%s:%s' % (username, password)).replace('\n', '')
$$ LANGUAGE 'plpythonu' IMMUTABLE;

CREATE OR REPLACE
FUNCTION cartodb._CDB_Group_API_Request(method text, url text, body text, valid_return_codes int[])
    RETURNS int AS


DO LANGUAGE 'plpgsql' $$
BEGIN
    DROP TYPE IF EXISTS _CDB_Group_API_Params;
END
$$;
