> ## 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.

# 認証方法を削除

> 認証されたユーザーに紐づく1つの認証方法を削除します。

export const Scopes = ({scopes = []}) => {
  return <div>
      <div class="api-section-heading flex flex-col gap-y-4 w-full">
        <div class="flex items-baseline border-b pb-2.5 border-gray-100 dark:border-gray-800 w-full">
          <h4 class="api-section-heading-title flex-1 mb-0">Scopes</h4>
          <div class="flex items-center"></div>
        </div>
      </div>
      <div class="mt-4">
        <div class="space-y-4 whitespace-normal prose prose-sm prose-gray dark:prose-invert overflow-wrap-anywhere [&_*]:overflow-wrap-anywhere">
          <p class="whitespace-pre-line text-xs">
            {"スコープは、APIリクエストと認証トークンの権限およびアクセスレベルを定義します。"}
          </p>
        </div>
      </div>
      <div class="flex font-mono text-sm group/param-head param-head break-all relative mt-6" id="scopes-scopes">
        <div class="flex-1 flex flex-col content-start py-0.5 mr-5">
          <div class="flex items-center flex-wrap gap-2">
            <div class="absolute -top-1.5">
              <a href="#scopes-scopes" class="-ml-10 flex items-center opacity-0 border-0 group-hover/param-head:opacity-100 focus:opacity-100 focus:outline-0 py-2 [.expandable-content_&]:-ml-[2.1rem] group/link" aria-label="見出しに移動">
                ​
                <div class="w-6 h-6 rounded-md flex items-center justify-center shadow-sm text-gray-400 dark:text-white/50 dark:bg-background-dark dark:brightness-[1.35] dark:ring-1 dark:hover:brightness-150 bg-white ring-1 ring-gray-400/30 dark:ring-gray-700/25 hover:ring-gray-400/60 dark:hover:ring-white/20 group-focus/link:border-2 group-focus/link:border-primary dark:group-focus/link:border-primary-light">
                  <svg xmlns="http://www.w3.org/2000/svg" fill="gray" height="12px" viewBox="0 0 576 512">
                    <path d="M0 256C0 167.6 71.6 96 160 96h72c13.3 0 24 10.7 24 24s-10.7 24-24 24H160C98.1 144 48 194.1 48 256s50.1 112 112 112h72c13.3 0 24 10.7 24 24s-10.7 24-24 24H160C71.6 416 0 344.4 0 256zm576 0c0 88.4-71.6 160-160 160H344c-13.3 0-24-10.7-24-24s10.7-24 24-24h72c61.9 0 112-50.1 112-112s-50.1-112-112-112H344c-13.3 0-24-10.7-24-24s10.7-24 24-24h72c88.4 0 160 71.6 160 160zM184 232H392c13.3 0 24 10.7 24 24s-10.7 24-24 24H184c-13.3 0-24-10.7-24-24s10.7-24 24-24z"></path>
                  </svg>
                </div>
              </a>
            </div>
            {scopes.map((scope, index) => {
    return <span class="flex items-center px-2 py-0.5 rounded-md bg-gray-100/50 dark:bg-white/5 text-gray-600 dark:text-gray-200 font-medium break-all" style={{
      lineHeight: "1rem",
      fontSize: "0.75rem",
      fontFamily: 'var(--font-jetbrains-mono), ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace'
    }} data-component-part="field-info-pill" key={index}>
                  {scope}
                </span>;
  })}
          </div>
        </div>
      </div>
    </div>;
};

export const ApiReleaseLifecycle = ({releaseLifecycle = "GA"}) => {
  const lifecycleMap = {
    ea: "早期アクセス",
    ga: "一般提供",
    deprecated: "非推奨",
    planned: "計画中",
    beta: "ベータ"
  };
  const LIFECYCLE_THEMES = {
    info: {
      light: {
        bg: "lab(91.896% .077188 -6.94053)",
        text: "lab(36.091% 25.9241 -68.0384)"
      },
      dark: {
        bg: "lab(16.0426% 6.71726 -27.2409)",
        text: "lab(72.6029% 4.08953 -41.9669)"
      }
    },
    secondary: {
      light: {
        bg: "lab(90.8548% 11.3355 8.01476)",
        text: "lab(47.5286% 56.4238 43.4706)"
      },
      dark: {
        bg: "lab(16.3609% 37.191 25.6346)",
        text: "lab(71.881% 41.5 29.4839)"
      }
    },
    danger: {
      light: {
        bg: "lab(94.7916% -.0000298023 0)",
        text: "lab(54.3656% 0 -.0000119209)"
      },
      dark: {
        bg: "lab(13.232% 0 0)",
        text: "lab(51.6164% 0 0)"
      }
    }
  };
  const LIFECYCLE_THEME_MAP = {
    ea: "info",
    ga: "info",
    beta: "info",
    deprecated: "secondary",
    planned: "danger"
  };
  const lifecycle = releaseLifecycle.toLocaleLowerCase();
  const lifecycleText = lifecycleMap[lifecycle];
  if (!lifecycleText) {
    return null;
  }
  const theme = LIFECYCLE_THEMES[LIFECYCLE_THEME_MAP[lifecycle]];
  return <div>
      <div className="api-section-heading flex flex-col gap-y-4 w-full">
        <div className="flex items-baseline border-b pb-2.5 border-gray-100 dark:border-gray-800 w-full">
          <h4 className="api-section-heading-title flex-1 mb-0">リリースライフサイクル</h4>
        </div>
      </div>
      <div className="flex font-mono text-sm group/param-head param-head break-all relative mt-2.5" id="releaselifecycle-lifecycle">
        <div className="flex-1 flex flex-col content-start py-0.5 mr-5">
          <div className="flex items-center flex-wrap gap-2">
            <div className="absolute -top-1.5">
              <a href="#releaselifecycle-lifecycle" className="-ml-10 flex items-center opacity-0 border-0 group-hover/param-head:opacity-100 focus:opacity-100 focus:outline-0 py-2 [.expandable-content_&]:-ml-[2.1rem] group/link" aria-label="ヘッダーに移動">
                <div className="w-6 h-6 rounded-md flex items-center justify-center shadow-sm text-gray-400 dark:text-white/50 dark:bg-background-dark dark:brightness-[1.35] dark:ring-1 dark:hover:brightness-150 bg-white ring-1 ring-gray-400/30 dark:ring-gray-700/25 hover:ring-gray-400/60 dark:hover:ring-white/20 group-focus/link:border-2 group-focus/link:border-primary dark:group-focus/link:border-primary-light">
                  <svg xmlns="http://www.w3.org/2000/svg" fill="gray" height="12px" viewBox="0 0 576 512">
                    <path d="M0 256C0 167.6 71.6 96 160 96h72c13.3 0 24 10.7 24 24s-10.7 24-24 24H160C98.1 144 48 194.1 48 256s50.1 112 112 112h72c13.3 0 24 10.7 24 24s-10.7 24-24 24H160C71.6 416 0 344.4 0 256zm576 0c0 88.4-71.6 160-160 160H344c-13.3 0-24-10.7-24-24s10.7-24 24-24h72c61.9 0 112-50.1 112-112s-50.1-112-112-112H344c-13.3 0-24-10.7-24-24s10.7-24 24-24h72c88.4 0 160 71.6 160 160zM184 232H392c13.3 0 24 10.7 24 24s-10.7 24-24 24H184c-13.3 0-24-10.7-24-24s10.7-24 24-24z"></path>
                  </svg>
                </div>
              </a>
            </div>
            <span className="inline-flex items-center w-fit font-medium gap-1 py-0.5 px-2 rounded-md" style={{
    lineHeight: "1rem",
    fontSize: "0.75rem",
    fontFamily: 'var(--font-jetbrains-mono), ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace',
    backgroundColor: `light-dark(${theme.light.bg}, ${theme.dark.bg})`,
    color: `light-dark(${theme.light.text}, ${theme.dark.text})`,
    borderColor: `light-dark(color-mix(in oklab, ${theme.light.text} 25%, transparent), color-mix(in oklab, ${theme.dark.text} 25%, transparent))`
  }}>
              {lifecycleText}
            </span>
          </div>
        </div>
      </div>
    </div>;
};

<ApiReleaseLifecycle releaseLifecycle="GA" />

<Scopes scopes={["delete:me:authentication_methods"]} />


## OpenAPI

````yaml ja/docs/oas/myaccount/myaccount-api-oas.json DELETE /authentication-methods/{authentication_method_id}
openapi: 3.1.0
info:
  description: >-
    Auth0 My Account API
    には、ユーザーが自身のアカウント情報を管理するための専用エンドポイントのセットが用意されています。お客様は、これらの API
    を使用してアプリケーション内にセルフサービス機能を構築したり、ユーザーアカウントの詳細情報を段階的に追加したりできます。


    My Account API は、現在ログインしているユーザーのコンテキストで動作し、ユーザー向けアプリケーション内で直接使用できます。


    :::tip Auth0 ドメインとカスタムドメインの使い分け


    My Account API では、正規の Auth0
    ドメインまたはカスタムドメインを使用できますが、次の各処理を含むプロセス全体を通して、同じドメインを使用する必要があります。


    - アクセストークンの取得

    - audience 値の設定

    - My Account API エンドポイントの呼び出し


    詳しくは、[Custom Domains](https://auth0.com/docs/customize/custom-domains)
    を参照してください。


    :::


    ## My Account API を有効化する


    Auth0 Dashboard で、テナントの My Account API を有効化できます。


    1. Authentication > APIs に移動します。

    2. MyAccount API バナーを見つけます。

    3. Activate を選択します。


    ![](https://images.ctfassets.net/cdy7uua7fh8z/DGkDQNIHcegN8vtQyEvF3/a2e98b06867701a66fa1f1b3df1c996b/My_Account_API_-_Activate.png)


    デフォルトでは、My Account API は次のアプリケーション API アクセスポリシーで作成されます。


    `require_client_grant`（ユーザーフロー用）


    `deny_all`（クライアント（マシン間）フロー用）


    アプリケーションがユーザーに代わって My Account API
    にアクセスするには、そのアプリケーション用のクライアントグラントを明示的に作成する必要があります。これにより、そのアプリケーションが要求できる最大スコープを定義できます。あるいは、ユーザーアクセスフローのポリシーを
    allow_all に変更することもできます。これにより、テナント内の任意のアプリケーションが My Account API
    に対して任意のスコープを要求できるようになります。


    My Account API では機密性の高い情報や操作が公開されるため、Auth0 は、ユーザーアクセスフローで allow_all
    を使用することを推奨していません。My Account API
    では最小権限の原則に従い、アプリケーションが本当に必要なものにのみアクセスできるようにして、潜在的なセキュリティリスクを最小限に抑える必要があります。


    アプリケーションに最終的に付与される Permissions は、アプリケーション API
    アクセスポリシーで許可されたスコープ、エンドユーザーに割り当てられたロールベースアクセス制御（RBAC）の権限、およびユーザーの同意（該当する場合）の積集合によって決まります。


    :::info サポート対象フロー


    My Account API へのクライアントアクセスに対するアプリケーション API ポリシーは更新できません。つまり、Client
    Credentials フローを使用して My Account API にアクセスすることはできません。


    :::


    アプリケーション API アクセスポリシーと、それに関連付けられたクライアントグラントの管理方法について詳しくは、[Application Access
    to APIs: Client
    Grants](https://auth0.com/docs/get-started/applications/application-access-to-apis-client-grants)
    を参照してください。


    ## アクセストークンを取得する


    My Account API 用のアクセストークンは、自身の API 用のアクセストークンを取得するのと同じ方法で取得できます。


    :::info &nbsp

    My Account API で機密性の高い操作（認証方法の登録など）を許可する場合は、[多要素認証
    (MFA)](https://auth0.com/docs/secure/multi-factor-authentication)
    によって追加のセキュリティポリシーを適用するため、[Step-up
    Authentication](https://auth0.com/docs/secure/multi-factor-authentication/step-up-authentication)
    を使用することを強くお勧めします。

    :::


    Universal Login を使用している場合は、次の記事を参照してください。


    - [Call Your API Using the Authorization Code
    Flow](https://auth0.com/docs/get-started/authentication-and-authorization-flow/authorization-code-flow/call-your-api-using-the-authorization-code-flow)

    - [Call Your API Using the Authorization Code Flow with
    PKCE](https://auth0.com/docs/get-started/authentication-and-authorization-flow/authorization-code-flow-with-pkce/call-your-api-using-the-authorization-code-flow-with-pkce)


    埋め込みログインを使用している場合は、次の記事を参照してください。


    - [Call Your API Using Resource Owner Password
    Flow](https://auth0.com/docs/get-started/authentication-and-authorization-flow/resource-owner-password-flow/call-your-api-using-resource-owner-password-flow)

    - [Login Flow with Native Passkeys
    API](https://auth0.com/docs/native-passkeys-api#login-flow)


    ## 例


    ### 認可コードフローを使用する Universal Login


    **ステップ 1: 認可コードをリクエストする**


    ```

    curl --request GET \
      --url 'https://{yourDomain}/authorize?response_type=code&client_id={yourClientId}&redirect_uri=%7ByourRedirectUri%7D&scope=create%3Ame%3Aauthentication_methods&offline_access=&audience=https%3A%2F%2F{yourDomain}%2Fme%2F'
    ```


    **ステップ 2: code をアクセストークンに交換する**


    ```

    curl --request POST \
      --url 'https://{yourDomain}/oauth/token' \
      --header 'content-type: application/json' \
      --data '{"grant_type": "authorization_code","client_id": "{yourClientId}","client_secret": "{yourClientSecret}","code": "{yourAuthorizationCode}","redirect_uri": "{yourRedirectUri}","audience": "{yourAudience}","scope": "create:me:authentication_methods","offline_access": ""}'
    ```


    ### ネイティブパスキーを使用する埋め込みログイン


    **ステップ 1: ログインチャレンジをリクエストする**


    ```

    curl --request POST \
      --url 'https://{yourDomain}/passkey/challenge' \
      --header 'content-type: application/json' \
      --data '{"client_id": "{yourClientId}"}'
    ```


    **ステップ 2: 既存のユーザーを認証する**


    ```

    curl --request POST \
      --url 'https://{yourDomain}/oauth/token' \
      --header 'content-type: application/json' \
      --data '{  "grant_type": "urn:okta:params:oauth:grant-type:webauthn",  "client_id": "{yourClientId}",  "scope": "create:me:authentication_methods offline_access",  "audience": "https://{yourDomain}/me/",  "auth_session": "{sessionIdFromTheFirstRequest}",  "authn_response": "{authenticatorResponse}"}'
    ```
  title: My Account
  version: '1.0'
servers:
  - url: https://{host}/me/v1
    variables:
      host:
        default: auth0.auth0.com
        description: カスタムまたは正規のホスト名
security: []
tags:
  - description: 認証要素
    name: factors
    x-displayName: Factors
  - description: 接続済みアカウント
    name: connected-accounts
    x-displayName: Connected Accounts
  - description: 認証方法
    name: authentication-methods
    x-displayName: Authentication Methods
  - description: 同意
    name: consents
    x-displayName: Consents
paths:
  /authentication-methods/{authentication_method_id}:
    delete:
      tags:
        - authentication-methods
      summary: ID を指定して認証方法を削除
      description: 認証されたユーザーに紐づく1つの認証方法を削除します。
      operationId: deleteAuthenticationMethod
      parameters:
        - $ref: '#/components/parameters/PathAuthenticationMethodId'
      responses:
        '204':
          description: 認証方法を正常に削除しました
          headers:
            x-ratelimit-limit:
              $ref: '#/components/headers/XRateLimitLimitHeader'
            x-ratelimit-remaining:
              $ref: '#/components/headers/XRateLimitRemainingHeader'
            x-ratelimit-reset:
              $ref: '#/components/headers/XRateLimitResetHeader'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '403':
          $ref: '#/components/responses/Forbidden'
        '429':
          $ref: '#/components/responses/TooManyRequests'
      security:
        - Bearer-DPoP:
            - delete:me:authentication_methods
      x-codeSamples: []
components:
  parameters:
    PathAuthenticationMethodId:
      description: 認証方法 ID。この値は、認証方法の作成時に返される Location ヘッダーの一部です。変更を加えず、そのまま使用してください。
      in: path
      name: authentication_method_id
      required: true
      schema:
        $ref: '#/components/schemas/PathAuthenticationMethodId'
  headers:
    XRateLimitLimitHeader:
      description: 制限ウィンドウ内で許可されるリクエストの最大数
      required: true
      schema:
        type: number
    XRateLimitRemainingHeader:
      description: リクエストが拒否されるまで、現在のウィンドウ内で残っているリクエスト数
      required: true
      schema:
        type: number
    XRateLimitResetHeader:
      description: バケットが補充される予定時刻（秒単位の UNIX タイムスタンプ）
      required: true
      schema:
        type: number
    RetryAfterHeader:
      description: 新しいリクエストを送信するまでにクライアントが待機すべき秒数
      required: true
      schema:
        type: number
    XAuth0ErrorKindHeader:
      description: レート制限の超過がグローバル（テナント単位の）制限であることを示す指標。
      schema:
        const: global-rate-limit
        type: string
  responses:
    BadRequest:
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
      description: スキーマに基づいて無効な入力です。
    Unauthorized:
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
      description: 認証されていません。
    Forbidden:
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
      description: アクセスが禁止されています。
    TooManyRequests:
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
      description: リクエストが多すぎます。
      headers:
        retry-after:
          $ref: '#/components/headers/RetryAfterHeader'
        x-auth0-error-kind:
          $ref: '#/components/headers/XAuth0ErrorKindHeader'
        x-ratelimit-limit:
          $ref: '#/components/headers/XRateLimitLimitHeader'
        x-ratelimit-remaining:
          $ref: '#/components/headers/XRateLimitRemainingHeader'
        x-ratelimit-reset:
          $ref: '#/components/headers/XRateLimitResetHeader'
  schemas:
    PathAuthenticationMethodId:
      type: string
    ErrorResponse:
      additionalProperties: false
      properties:
        detail:
          type: string
        status:
          type: number
        title:
          type: string
        type:
          type: string
        validation_errors:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
      required:
        - type
        - status
        - title
        - detail
      type: object
    ValidationError:
      additionalProperties: false
      properties:
        detail:
          type: string
        field:
          type: string
        pointer:
          type: string
        source:
          type: string
      required:
        - detail
      type: object
  securitySchemes:
    Bearer-DPoP:
      description: Bearer トークンと DPoP トークンは、API の設定に応じてサポートされます
      scheme: bearer
      type: http

````