{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/braintree/json-schema/braintree-payment-method-update-request-schema.json",
  "title": "PaymentMethodUpdateRequest",
  "description": "Request body for updating an existing vaulted payment method.",
  "x-generated": "2026-11-04",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/braintree-payment-methods-api-openapi.yml#/components/schemas/PaymentMethodUpdateRequest",
  "type": "object",
  "properties": {
    "payment_method_nonce": {
      "type": "string",
      "description": "A new one-time nonce to replace the underlying payment details while preserving the existing token."
    },
    "billing_address": {
      "$ref": "#/$defs/Address"
    },
    "options": {
      "type": "object",
      "description": "Options for the payment method update.",
      "properties": {
        "make_default": {
          "type": "boolean",
          "description": "If true, this payment method becomes the customer's default."
        },
        "update_existing_token": {
          "type": "string",
          "description": "Token of an existing payment method to update rather than creating a new one."
        }
      }
    }
  },
  "$defs": {
    "Address": {
      "type": "object",
      "description": "A billing or shipping address associated with a transaction or customer.",
      "properties": {
        "first_name": {
          "type": "string",
          "description": "First name of the address holder.",
          "maxLength": 255
        },
        "last_name": {
          "type": "string",
          "description": "Last name of the address holder.",
          "maxLength": 255
        },
        "company": {
          "type": "string",
          "description": "Company or organization name at this address.",
          "maxLength": 255
        },
        "street_address": {
          "type": "string",
          "description": "Primary street address line.",
          "maxLength": 255
        },
        "extended_address": {
          "type": "string",
          "description": "Secondary address line such as apartment or suite number.",
          "maxLength": 255
        },
        "locality": {
          "type": "string",
          "description": "City or locality of the address.",
          "maxLength": 255
        },
        "region": {
          "type": "string",
          "description": "State, province, or region code of the address.",
          "maxLength": 255
        },
        "postal_code": {
          "type": "string",
          "description": "Postal or ZIP code of the address.",
          "maxLength": 9
        },
        "country_code_alpha2": {
          "type": "string",
          "description": "Two-letter ISO 3166-1 alpha-2 country code.",
          "pattern": "^[A-Z]{2}$"
        }
      }
    }
  }
}