> For the complete documentation index, see [llms.txt](https://docs.payments.thalescloud.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.payments.thalescloud.io/nfc-wallet-sdk-android/ja/help/error-management/cps-error-management/provisioningserviceerror.md).

# ProvisioningServiceError

### 概要

トークナイゼーション中に、次を使用します `ProvisioningServiceManager`。操作が失敗した場合、SDKは次をスローします `ProvisioningServiceError`.

次を使用して `ProvisioningServiceError` エラーのカテゴリと詳細を読み取ります:

* `getSdkErrorCode()`：返す値 `ProvisioningServiceErrorCodes`.
* `getCpsErrorCode()`：CPSサーバーのエラーコードを返します。
* `getHttpStatusCode()`：HTTPステータスコードを返します。
* `getErrorMessage()`：人間が読めるメッセージを返します。
* `getTokenId()`：カード固有の場合、トークンIDを返します。
* `getStatusAdditionalInfo()`：利用可能な場合、追加のCPSリクエストの詳細を返します。

このセクションではエラーの解析方法を示します。

### エラーを解析する

SDKが `ProvisioningServiceError`をスローしたときは、次のように解析します:

1. 呼び出す `getSdkErrorCode()` を取得するために `ProvisioningServiceErrorCodes`.
2. コードが等しい場合 `COMMON_COMM_ERROR`、呼び出す `getHttpStatusCode()`.
3. コードが等しい場合 `COMMON_SERVER_ERROR`、呼び出す `getCpsErrorCode()`.
4. 呼び出す `getErrorMessage()` 説明メッセージを取得するために。
5. エラーがカード固有の場合は、呼び出します `getTokenId()`.
6. エラーがCPSリクエストに関連している場合は、呼び出します `getStatusAdditionalInfo()`.

{% hint style="info" %}
その他のエラーも同様の構造を持ちます。詳細は次を参照してください [Android API](/nfc-wallet-sdk-android/ja/android-api.md).
{% endhint %}

すべての値を確認してください `ProvisioningServiceErrorCodes` での [Android API](/nfc-wallet-sdk-android/ja/android-api.md)。例えば:

* `COMMON_COMM_TIMEOUT_ERROR`：サーバー接続を開く際の接続タイムアウト。
* `COMMON_NO_INTERNET`：データ接続が利用できません。

### サーバーエラーの詳細

を受け取ったとき、 `COMMON_SERVER_ERROR`、呼び出す `getCpsErrorCode()`。また、呼び出してください `getErrorMessage()`.

既知のサーバーエラーコードとメッセージにはこれらのクラスを使用してください:

* `KnownCpsErrorCodes`
* `KnownMessageCode`

{% hint style="info" %}
ここに一覧されているエラーコードとエラーメッセージは網羅的ではありません。
{% endhint %}

{% hint style="warning" %}
これらのエラーを受け取ったときに同じリクエストを自動的に再試行しないでください。エンドユーザーに通知してください。サーバーエラーコードを添えてサポートチームに連絡するよう依頼してください。
{% endhint %}


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.payments.thalescloud.io/nfc-wallet-sdk-android/ja/help/error-management/cps-error-management/provisioningserviceerror.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
