code: import stripe
  stripe.api_key = "sk_test_your_key"
  
  stripe.SetupIntent.confirm(
    "seti_1EuLW12eZvKYlo2CSSF0PlLO",
    payment_method="pm_card_visa",
  )
  '''Response {
    "id": "seti_1ErTsG2eZvKYlo2CKaT8MITz",
    "object": "setup_intent",
    "application": null,
    "cancellation_reason": null,
    "client_secret": "seti_1ErTsG2eZvKYlo2CKaT8MITz_secret_FMCGzsO6znQcfgrMqJM3sHPDoZlhmZr",
    "created": 1562004308,
    "customer": null,
    "description": null,
    "flow_directions": null,
    "last_setup_error": null,
    "latest_attempt": "setatt_1ErTsH2eZvKYlo2CI7ukcoF7",
    "livemode": false,
    "mandate": null,
    "metadata": {
      "order_id": "6735"
    },
    "next_action": null,
    "on_behalf_of": null,
    "payment_method": "pm_1ErTsG2eZvKYlo2CH0DNen59",
    "payment_method_options": {},
    "payment_method_types": [
      "card"
    ],
    "redaction": null,
    "single_use_mandate": null,
    "status": "succeeded",
    "usage": "off_session"
  }'''
nl: Confirm a SetupIntentConfirm that your customer intends to set up the current or
  provided payment method. For example, you would confirm a SetupIntent
  when a customer hits the “Save” button on a payment method management
  page on your website.
  If the selected payment method does not require any additional
  steps from the customer, the SetupIntent will transition to the
  succeeded status.
  Otherwise, it will transition to the requires_action status and
  suggest additional actions via next_action. If setup fails,
  the SetupIntent will transition to the
  requires_payment_method status.Parameters payment_method optional ID of the payment method (a PaymentMethod, Card, or saved Source object) to attach to this SetupIntent.More parametersExpand all  mandate_data optional dictionary   payment_method_data optional dictionary   payment_method_options optional dictionary secret key only   return_url optional ReturnsReturns the resulting SetupIntent after all possible transitions are applied