'Prepare the access token request body.
The client makes a request to the token endpoint by adding the
following parameters using the "application/x-www-form-urlencoded"
format in the HTTP request entity-body:
:param client_id:   REQUIRED, if the client is not authenticating with the
authorization server as described in `Section 3.2.1`_.
:param code:    REQUIRED. The authorization code received from the
authorization server.
:param redirect_uri:    REQUIRED, if the "redirect_uri" parameter was included in the
authorization request as described in `Section 4.1.1`_, and their
values MUST be identical.
:param kwargs: Extra parameters to include in the token request.
In addition OAuthLib will add the ``grant_type`` parameter set to
``authorization_code``.
If the client type is confidential or the client was issued client
credentials (or assigned other authentication requirements), the
client MUST authenticate with the authorization server as described
in `Section 3.2.1`_::
>>> from oauthlib.oauth2 import WebApplicationClient
>>> client = WebApplicationClient(\'your_id\')
>>> client.prepare_request_body(code=\'sh35ksdf09sf\')
\'grant_type=authorization_code&code=sh35ksdf09sf\'
>>> client.prepare_request_body(code=\'sh35ksdf09sf\', foo=\'bar\')
\'grant_type=authorization_code&code=sh35ksdf09sf&foo=bar\'
.. _`Section 4.1.1`: http://tools.ietf.org/html/rfc6749#section-4.1.1
.. _`Section 3.2.1`: http://tools.ietf.org/html/rfc6749#section-3.2.1'

def prepare_request_body(self, client_id=None, code=None, body=u'', redirect_uri=None, **kwargs):

    code = (code or self.code)
    return prepare_token_request(u'authorization_code', code=code, body=body, client_id=self.client_id, redirect_uri=redirect_uri, **kwargs)
