<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def uma_rp_get_rpt(self, ticket, claim_token=None, claim_token_format=None, pct=None, rpt=None, scope=None, state=None):
 """Function to be used by a UMA Requesting Party to get RPT token. Parameters: * **ticket (str, REQUIRED):
** ticket * **claim_token (str, OPTIONAL):
** claim token * **claim_token_format (str, OPTIONAL):
** claim token format * **pct (str, OPTIONAL):
** pct * **rpt (str, OPTIONAL):
** rpt * **scope (list, OPTIONAL):
** scope * **state (str, OPTIONAL):
** state that is returned from `uma_rp_get_claims_gathering_url` command Returns: **dict:** The response from the OP. Success response:: { "status":"ok", "data":{ "access_token":"SSJHBSUSSJHVhjsgvhsgvshgsv", "token_type":"Bearer", "pct":"c2F2ZWRjb25zZW50", "upgraded":true } } NeedInfoError response:: { 					"error":"need_info", 					"ticket":"ZXJyb3JfZGV0YWlscw==", 					"required_claims":[ 						{ 							"claim_token_format":[ 								"http://openid.net/specs/openid-connect-core-1_0.html#IDToken" 							], 							"claim_type":"urn:oid:0.9.2342.19200300.100.1.3", 							"friendly_name":"email", 							"issuer":["https://example.com/idp"], 							"name":"email23423453ou453" 						} 					], 					"redirect_user":"https://as.example.com/rqp_claims?id=2346576421" 				} 				 Raises: **OxdServerError:** When oxd-server reports a generic internal_error **InvalidTicketError:** When the oxd server returns a "invalid_ticket" error 			 """

        params = {
            "oxd_id": self.oxd_id,
            "ticket": ticket
            }
        if claim_token:
            params["claim_token"] = claim_token
        if claim_token_format:
            params["claim_token_format"] = claim_token_format
        if pct:
            params["pct"] = pct
        if rpt:
            params["rpt"] = rpt
        if scope:
            params["scope"] = scope
        if state:
            params["state"] = state

        logger.debug("Sending command `uma_rp_get_rpt` with params %s", params)
        response = self.msgr.request("uma_rp_get_rpt", **params)
        logger.debug("Received response: %s", response)

        if response['status'] == 'ok':
            return response['data']

        if response['data']['error'] == 'internal_error':
            raise OxdServerError(response['data'])

        if response['data']['error'] == 'need_info':
            return response['data']

        if response['data']['error'] == 'invalid_ticket':
            raise InvalidTicketError(response['data'])