A. User Authorization

A1. Authorize through AlipayHK app

A. User Authorization
  1. User triggers authorization request in Merchant's App.
  2. Merchant gets authorization URL from AlipayHK's backend.
  3. AlipayHK's backend returns the authorization URL.
  4. Merchant opens the authorization URL (redirects to AlipayHK app).
  5. AlipayHK displays T&C and confirmation page to the user.
  6. User agrees T&C and confirms authorization.
  7. AlipayHK returns authorization code to merchant.
  8. Merchant uses the authorization code to apply access token.
  9. AlipayHK returns access token to merchant.
  10. Merchant stores the tokens and redirects user to the result page.