Payment Methods

Update a Payment Method

Change a payment method's expiration date, address, or metadata.

patch/payment_methods/{token}

Request

Path parameters

tokenstring required

Headers

Idempotency-Keystring uuid required

a string to identify your request (we recommend using a generated uuid, but you may use any unique string) see Idempotent Requests

Authorizationstring required

the access_token value returned from the JustiFi oauth/token endpoint (be sure to append Bearer before the token)

Request body

Example request

{
  "card": {
    "address_line1": "123 Fake St",
    "address_line2": "Suite 101",
    "address_city": "Cityville",
    "address_state": "MN",
    "address_country": "US",
    "metadata": {
      "new": "info"
    }
  }
}

Response

Payment method update was successful

OR
OR

Example response

{
  "type": "payment_method",
  "data": {
    "id": "pm_123xyz",
    "signature": "3aGWnUznQ",
    "customer_id": "cust_123abc",
    "account_id": "acc_123",
    "status": "valid",
    "invalid_reason": "INVALID_ACCOUNT_NUMBER",
    "payment_method_import_id": "pmi_123xyz",
    "created_at": "2024-01-01T12:00:00Z",
    "updated_at": "2024-01-01T12:00:00Z",
    "card": {
      "id": "pm_123xyz",
      "name": "Lindsay Whalen",
      "brand": "visa",
      "digital_wallet": "apple_pay",
      "token": "pm_123xyz",
      "month": "5",
      "year": "2042",
      "metadata": {
        "new": "info"
      },
      "address_line1_check": "pass",
      "address_postal_code_check": "pass",
      "bin_details": {
        "type": "Credit",
        "card_brand": "Visa",
        "card_class": "Consumer",
        "country": "United States of America",
        "issuer": "WELLS FARGO BANK, N.A.",
        "funding_source": "Credit"
      }
    }
  }
}

Changes

No recorded changes to this operation across all 1 revision of this API.