# showAuthPage

> The Alipay+ client SDK calls the showAuthPage API to display the authorization page for the user to proceed with the authorization.

The Alipay+ client SDK calls the **showAuthPage** API to display the authorization page for the user to proceed with the authorization.

## Method signature

```java
public interface AutoDebitService {

    void showAuthPage(SignContractOAuthServiceParams params, Callback<SignContractOAuthServiceResult> callback);

}

```

## Request parameters

| **Item** | **Type** | **Description** | **Required** |
| --- | --- | --- | --- |
| params | [SignContractOAuthServiceParams](android_appendix#ZUE1t) | Parameters that are required to render the authorization page. | M |
| callback | Callback | The callback to be invoked after the authorization process ends. See [Callback](#NN7sw) for details. | M |

#### Callback

| **Item** | **Type** | **Description** | **Required** |
| --- | --- | --- | --- |
| result | [SignContractOAuthServiceResult](android_appendix#ZN1i2) | The authorization information that is required if the authorization is successful. | O |
| errorCode | String | The error code that is required if the authorization fails. | O |
| errorMessage | String | The error message that is required if the authorization fails. | O |

## Response parameters

N/A

## Sample

Definition of `_YOUR_AUTODEBIT_SERVICE_CLASS_`:

```java
public class YOUR_AUTODEBIT_SERVICE_CLASS implements AutoDebitService {

    public void showAuthPage(SignContractOauthServiceParams params, Callback<SignContractOAuthServiceResult> callback) {

        //Open the authUrl
        // Callback when user confirms authorization
        SignContractOAuthServiceResult result = new SignContractOAuthServiceResult();
        callback.onSuccess(result);
        // Callback when authorization fails
        callback.onFailure(errorCode, errorMessage);

    }

}

```

Instance of `_YOUR_AUTODEBIT_SERVICE_CLASS_`:

```java
AlipayPlusClientAutoDeibt.getInstance().autoDebitService = new YOUR_AUTODEBIT_SERVICE_CLASS;
```