ZhimaCreditPeUserAuthApplyResponse.py 1.5 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455
  1. #!/usr/bin/env python
  2. # -*- coding: utf-8 -*-
  3. import json
  4. from alipay.aop.api.response.AlipayResponse import AlipayResponse
  5. class ZhimaCreditPeUserAuthApplyResponse(AlipayResponse):
  6. def __init__(self):
  7. super(ZhimaCreditPeUserAuthApplyResponse, self).__init__()
  8. self._auth_code = None
  9. self._error_scope = None
  10. self._scope = None
  11. self._state = None
  12. @property
  13. def auth_code(self):
  14. return self._auth_code
  15. @auth_code.setter
  16. def auth_code(self, value):
  17. self._auth_code = value
  18. @property
  19. def error_scope(self):
  20. return self._error_scope
  21. @error_scope.setter
  22. def error_scope(self, value):
  23. self._error_scope = value
  24. @property
  25. def scope(self):
  26. return self._scope
  27. @scope.setter
  28. def scope(self, value):
  29. self._scope = value
  30. @property
  31. def state(self):
  32. return self._state
  33. @state.setter
  34. def state(self, value):
  35. self._state = value
  36. def parse_response_content(self, response_content):
  37. response = super(ZhimaCreditPeUserAuthApplyResponse, self).parse_response_content(response_content)
  38. if 'auth_code' in response:
  39. self.auth_code = response['auth_code']
  40. if 'error_scope' in response:
  41. self.error_scope = response['error_scope']
  42. if 'scope' in response:
  43. self.scope = response['scope']
  44. if 'state' in response:
  45. self.state = response['state']