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

# 電話番号認証の認証要素を更新

> Didit で登録済みの TOTP 認証要素の表示名、メタデータ、状態を変更します。名前の変更、メタデータの置き換え、無効化と再有効化ができます。

次も参照してください: [電話番号認証ファクターを削除する](https://docs.didit.me/ja/standalone-apis/phone-factor-delete.md)。


## OpenAPI

````yaml ja/openapi-25.json PATCH /v3/phone/factors/{factor_id}/
openapi: 3.0.0
info:
  version: 3.0.0
  title: Didit Verification API
  description: Identity verification API. Authenticate with x-api-key header.
servers:
  - url: https://verification.didit.me
security: []
tags:
  - name: Bank Data
    description: >-
      Bank Link, connections, accounts, balances, transactions, institutions and
      coverage. Bank data is available for sandbox applications. A live
      application's calls answer `404` until live access is announced. Nothing
      is charged in sandbox. A call made with an API key needs a key that
      carries the Bank data permission (`bank-data`): read for reads, write for
      operations that change something. The account check is the exception: it
      needs write access to sessions, or full access, and not the Bank data
      permission. Bank data is not part of full access: a full-access key is
      refused, and the call answers `403 bank_data_access_denied` until you
      create a key that carries the permission. Raw bank data (accounts,
      balances, transactions and the change feed) also refuses a request that
      carries no API key.


      Every refusal under `/v3/bank/` except the account check's has the same
      JSON body (`code`, `message`, `request_id`, `field`, `next_action`,
      `retry_after`). A path that is not an operation, an id that is not a UUID
      or an unknown sub-resource answers `404 not_found` for every method, and
      any unexpected error answers `500 internal_error` with a `request_id`.
      Where Bank data is not available, every operation answers the platform's
      standard `404`, exactly as an unknown route does.
paths:
  /v3/phone/factors/{factor_id}/:
    patch:
      tags:
        - Standalone APIs
      summary: Change a factor's name, metadata or state
      description: >-
        Change a factor without enrolling it again: rename it (`friendly_name`),
        replace your `metadata`, or disable it or turn it back on (`status`).
        The answer is the factor as it now stands.


        `disabled` stops the factor's checks and `verified` turns a disabled
        factor back on. A factor that was never verified cannot be turned on:
        finish its first check instead, or the call answers `409
        factor_unverified`.


        `metadata` replaces the keys and values you sent before: up to 10 keys,
        each value at most 500 characters, or the call answers `400
        invalid_metadata`.


        **Authentication.** Send your application's API key in `x-api-key`.


        **Rate limit.** Requests count against the key's budget; over it the
        answer is `429` with `Retry-After`.
      operationId: update_phone_factor
      parameters:
        - name: factor_id
          in: path
          required: true
          description: The factor to change.
          schema:
            type: string
            example: fa_01JCH8K2
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/PhoneFactorUpdateRequest'
            examples:
              Rename and disable:
                summary: Rename and disable
                value:
                  friendly_name: Work phone
                  metadata:
                    device: iPhone 16
                  status: disabled
      responses:
        '200':
          description: The factor as it now stands.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PhoneFactor'
              examples:
                Disabled:
                  summary: Disabled
                  value:
                    factor_id: fa_01JCH8K2
                    type: totp
                    status: disabled
                    user_id: u_481
                    friendly_name: Work phone
                    metadata:
                      device: iPhone 16
                    created_at: '2026-11-02T08:14:00Z'
                    last_used_at: '2026-11-21T09:58:00Z'
        '400':
          description: >-
            `invalid_metadata` - More than 10 keys, or a value over 500
            characters.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PhoneApiError'
        '401':
          description: >-
            The `x-api-key` is wrong, revoked or expired: replace the
            credential.
        '403':
          description: >-
            The `x-api-key` header is missing, or a scoped key lacks the
            permission this call needs.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PhoneApiError'
        '404':
          description: '`not_found` - No factor with this id in your application.'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PhoneApiError'
        '409':
          description: >-
            `factor_unverified` - An unverified factor cannot be turned back on:
            finish its first check.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PhoneApiError'
        '429':
          description: >-
            `rate_limited` - Over 600 requests a minute for the key: wait for
            Retry-After.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PhoneApiError'
      security:
        - ApiKeyAuth: []
      x-codeSamples: []
components:
  schemas:
    PhoneFactorUpdateRequest:
      type: object
      properties:
        friendly_name:
          type: string
          description: A new name for the authenticator app.
          example: Work phone
        metadata:
          type: object
          description: Replaces your keys and values with these, up to 10.
          maxProperties: 10
          additionalProperties:
            type: string
            maxLength: 500
          example:
            device: iPhone 16
        status:
          type: string
          enum:
            - disabled
            - verified
          description: >-
            `disabled` stops the factor's checks; `verified` turns a disabled
            factor back on.
          example: disabled
    PhoneFactor:
      type: object
      properties:
        factor_id:
          type: string
          description: The factor.
          example: fa_01JCH8K2
        type:
          type: string
          enum:
            - totp
          description: The factor.
          example: totp
        status:
          type: string
          enum:
            - unverified
            - verified
            - disabled
          description: >-
            `unverified` until the first successful check, `verified` after it,
            `disabled` while its checks are turned off.
          example: verified
        user_id:
          type: string
          description: Your id for the user it belongs to.
          example: u_481
        friendly_name:
          type: string
          description: Shown in the authenticator app and in the factor list.
          example: Demo App
        metadata:
          type: object
          description: Your keys and values, as you sent them.
          maxProperties: 10
          additionalProperties:
            type: string
            maxLength: 500
          example:
            device: iPhone 15
        created_at:
          type: string
          format: date-time
          description: When it was enrolled.
          example: '2026-11-02T08:14:00Z'
        last_used_at:
          type: string
          format: date-time
          nullable: true
          description: Its last successful check, `null` until there is one.
          example: '2026-11-21T09:58:00Z'
      required:
        - factor_id
        - type
        - status
    PhoneApiError:
      type: object
      description: >-
        An error answer. The HTTP status says the class of failure; `code` names
        the reason and `detail` says it in words.
      properties:
        code:
          type: string
          description: Machine-readable reason, as each response documents it.
          example: not_found
        detail:
          type: string
          description: What went wrong, in one sentence a user can act on.
          example: No factor with this id in your application.
      required:
        - detail
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: header
      name: x-api-key
      description: >-
        Your application's API key, from Developers -> API keys in the Business
        Console. The primary key has full access. A named key can be scoped:
        none, read or write per resource, limited to some workflows or to
        approved sessions, to a list of IP addresses, and to an expiry date. 401
        means the key is wrong, revoked or expired; 403 means no key was sent,
        the key has no access to this resource or action, or the request came
        from an address outside its IP list; 404 on a session route means the
        session is outside the key's workflows or statuses. A key without media
        access receives image, video and PDF URLs as null, and a key without
        sessions write receives session links and tokens as null. See
        https://docs.didit.me/console/api-keys.

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.