> ## Documentation Index
> Fetch the complete documentation index at: https://translations.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

> Auth0 Dashboard または Management API を使用してリフレッシュトークンローテーションを無効にする方法を説明します。

# リフレッシュトークンローテーションを無効にする

export const AuthCodeBlock = ({filename, icon, language, highlight, children}) => {
  const [displayText, setDisplayText] = useState(children);
  const [copyText, setCopyText] = useState(children);
  const wrapperRef = React.useRef(null);
  useEffect(() => {
    let unsubscribe = null;
    function init() {
      if (!window.autorun || !window.rootStore) {
        return;
      }
      unsubscribe = window.autorun(() => {
        let processedChildrenForDisplay = children;
        let processedChildrenForCopy = children;
        for (const [key, value] of window.rootStore.variableStore.values.entries()) {
          const escapedKey = key.replaceAll(/[.*+?^${}()|[\]\\]/g, (String.raw)`\$&`);
          let displayValue = value;
          if (key === "{yourClientSecret}" && value !== "{yourClientSecret}") {
            displayValue = value.substring(0, 3) + "*****MASKED*****";
          }
          processedChildrenForDisplay = processedChildrenForDisplay.replaceAll(new RegExp(escapedKey, "g"), displayValue);
          processedChildrenForCopy = processedChildrenForCopy.replaceAll(new RegExp(escapedKey, "g"), value);
        }
        setDisplayText(processedChildrenForDisplay);
        setCopyText(processedChildrenForCopy);
      });
    }
    if (window.rootStore) {
      init();
    } else {
      window.addEventListener("adu:storeReady", init);
    }
    return () => {
      window.removeEventListener("adu:storeReady", init);
      unsubscribe?.();
    };
  }, [children]);
  useEffect(() => {
    if (!wrapperRef.current) return;
    const originalWriteText = navigator.clipboard.writeText.bind(navigator.clipboard);
    let isOverriding = false;
    const handleClick = e => {
      const button = e.target.closest('[data-testid="copy-code-button"]');
      if (!button || !wrapperRef.current.contains(button)) return;
      isOverriding = true;
      navigator.clipboard.writeText = text => {
        if (isOverriding) {
          isOverriding = false;
          navigator.clipboard.writeText = originalWriteText;
          return originalWriteText(copyText);
        }
        return originalWriteText(text);
      };
      setTimeout(() => {
        if (isOverriding) {
          isOverriding = false;
          navigator.clipboard.writeText = originalWriteText;
        }
      }, 100);
    };
    const wrapper = wrapperRef.current;
    wrapper.addEventListener('click', handleClick, true);
    return () => {
      wrapper.removeEventListener('click', handleClick, true);
      if (navigator.clipboard.writeText !== originalWriteText) {
        navigator.clipboard.writeText = originalWriteText;
      }
    };
  }, [copyText]);
  return <div ref={wrapperRef}>
      <CodeBlock filename={filename} icon={icon} language={language} lines highlight={highlight}>
        {displayText}
      </CodeBlock>
    </div>;
};

export const codeExample = `const auth0 = await createAuth0Client({
  domain: '{yourDomain}',
  client_id: '{yourClientId}',
  audience: '{yourApiIdentifier}',
  useRefreshTokens: false
});`;

各アプリケーションの<Tooltip tip="リフレッシュトークン: ユーザーに再度ログインを求めることなく、新しいアクセストークンを取得するために使用されるトークンです。" cta="用語集を見る" href="/docs/ja-jp/glossary?term=refresh+token">リフレッシュトークン</Tooltip>ローテーションは、Auth0 Dashboard または <Tooltip tip="リフレッシュトークン: ユーザーに再度ログインを求めることなく、新しいアクセストークンを取得するために使用されるトークンです。" cta="用語集を見る" href="/docs/ja-jp/glossary?term=Management+API">Management API</Tooltip> を使用して無効にできます。

<div id="disable-with-the-dashboard">
  ## Auth0 Dashboardで無効にする
</div>

1. [Auth0 Dashboard](https://manage.auth0.com/#) で **アプリケーション > アプリケーション** に移動し、設定するアプリケーションを選択します。
2. Settings タブで、リフレッシュトークンローテーション セクションを見つけ、Allow Refresh Token Rotation トグルをオフにします。
3. 画面下部にある **変更を保存** を選択します。

<div id="disable-with-the-management-api">
  ## Management API で無効にする
</div>

1. Management API を使用して、各アプリケーションでリフレッシュトークンローテーションを無効にします。

   <AuthCodeBlock children={codeExample} language="javascript" />

2. 次のように、ローテーションしないリフレッシュトークンを設定します。

   ```http lines theme={null}
   PATCH /api/v2/clients/{client_id}
   {
      "refresh_token": {
        "rotation_type": "non-rotating",
        "expiration_type": "non-expiring"
      }
   }
   ```

<div id="learn-more">
  ## さらに詳しく
</div>

* [リフレッシュトークンローテーション](/docs/ja-jp/secure/tokens/refresh-tokens/refresh-token-rotation)
* [リフレッシュトークンローテーションを設定する](/docs/ja-jp/secure/tokens/refresh-tokens/configure-refresh-token-rotation)
* [リフレッシュトークンローテーションを利用する](/docs/ja-jp/secure/tokens/refresh-tokens/use-refresh-token-rotation)
