def get_auth_url(self, app_id, canvas_url, perms=None, **kwargs):
url = "<STR_LIT>".format(<EOL>FACEBOOK_WWW_URL, self.version, FACEBOOK_OAUTH_DIALOG_PATH<EOL>)<EOL>args = {"<STR_LIT>": app_id, "<STR_LIT>": canvas_url}<EOL>if perms:<EOL><INDENT>args["<STR_LIT>"] = "<STR_LIT:U+002C>".join(perms)<EOL><DEDENT>args.update(kwargs)<EOL>return url + urlencode(args)<EOL>
Build a URL to create an OAuth dialog.