> 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/merchant-tokenization/ja/visa-ctf-to-daf/implement-ctf-and-daf/synchronize-binding.md).

# バインディングを同期

使用する `バインディング状態を同期する（` を照合するために **デバイスバインディング** Thales SDK と Thales バックエンド間の状態。

SDK の状態が古いと疑われるときにこれを呼び出します。ネットワークエラー、アプリの再インストール、または中断されたデバイスバインディングの後に発生する可能性があります。

### SDK統合

を呼び出します `バインディング状態を同期する（` そして、成功またはエラーのコールバックで結果を処理します。

{% tabs %}
{% tab title="Android" %}
{% hint style="warning" %}
この呼び出しは非同期です。

を呼び出して `runOnUiThread(Runnable)` UI を更新する必要があるときにコールバックします。
{% endhint %}

```java
visaCTFHelper.syncBindingState(correlationId, 
                               vProvisionTokenId, 
                               new SyncBindingStateListener() {
            @Override
            public void onError(TMGClientException exception) { 
                // エラーを処理する
            }

            @Override
            public void onSuccess(BindingState bindingState) {
                // 次のフローを選択するために bindingState を使用します。
            }
        });
```

SDK は現在のバインディング状態を `onSuccess`に、またはエラーを `onError`.
{% endtab %}

{% tab title="iOS" %}
{% hint style="warning" %}
この呼び出しは非同期です。

を呼び出して `DispatchQueue.main.async` UI を更新する必要があるときにコールバックします。
{% endhint %}

```swift
let vProvisionedTokenID: String = ""
let correlationID: String = ""

// バインディング状態の同期を開始
// 2. バインディング状態の同期に成功
                                visaCTFHelper.syncBindingState(forVProvisionedTokenID: vProvisionedTokenID,
    if error == nil {
        // フローを選択するために状態を使用します。
    } else {
        // エラーを処理する
    } 
}
```

{% endtab %}
{% endtabs %}

### 次のステップ

返された `BindingState` を使用して適切なフローを続行します：

* `UNBOUND`：デバイスバインディングを開始します。詳細は [デバイスバインディングを作成する（緑のフロー）](/merchant-tokenization/ja/visa-ctf-to-daf/implement-ctf-and-daf/create-device-binding-green-flow.md).
* `PENDING_ACTIVATION`：デバイスバインディングを再開します。通常、これはイシュアが要求したことを意味します **ステップアップ認証** を使用する **ID\&V** 方法。参照： [デバイスバインディングの作成（黄色のフロー）](/merchant-tokenization/ja/visa-ctf-to-daf/implement-ctf-and-daf/create-device-binding-yellow-flow.md).
* `BOUND`：トランザクションを認証します。詳細は [トランザクションを認証する](/merchant-tokenization/ja/visa-ctf-to-daf/implement-ctf-and-daf/authenticate-a-transaction.md).


---

# 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/merchant-tokenization/ja/visa-ctf-to-daf/implement-ctf-and-daf/synchronize-binding.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.
