def _refresh_access_token(self):
resource = "<STR_LIT>"<EOL>fields = dict(grant_type="<STR_LIT>", refresh_token=self.refresh_token,<EOL>client_id=self.auth.client_id, client_secret=self.auth.client_secret,<EOL>format="<STR_LIT>")<EOL>status, data = self._handle_response("<STR_LIT:POST>", resource, fields=fields, <EOL>refresh_access_token=False)<EOL>if "<STR_LIT>" in data:<EOL><INDENT>self.access_token = data["<STR_LIT>"]<EOL>if callable(self.access_token_refreshed_callback):<EOL><INDENT>self.access_token_refreshed_callback(self.access_token)<EOL><DEDENT>return True<EOL><DEDENT>return False<EOL>
If the client application has a refresh token, it can use it to send a request for a new access token. 

To ask for a new access token, the client application should send a POST request to https://login.instance_name/services/oauth2/token with the following query parameters:

    grant_type:     Value must be refresh_token for this flow.
    refresh_token:  The refresh token the client application already received. 
    client_id:      Consumer key from the remote access application definition.
    client_secret:  Consumer secret from the remote access application definition.
    format:         Expected return format. This parameter is optional. The default is json. Values are:

        * urlencoded
        * json
        * xml

e.g.

    $ curl -i --form grant_type=refresh_token \
        --form refresh_token=<refresh_token> \
        --form client_id=<client_id> \
        --form client_secret=<client_secret> \
        --form format=json \
        https://na1.salesforce.com/services/oauth2/token