code: import stripe
  stripe.api_key = "sk_test_your_key"
  
  stripe.Plan.create(
    amount=1200,
    currency="usd",
    interval="month",
    product="prod_MApBpixJvIPdF1",
  )
  '''Response {
    "id": "price_1LSTX02eZvKYlo2CrKMGl6Dy",
    "object": "plan",
    "active": true,
    "aggregate_usage": null,
    "amount": 1200,
    "amount_decimal": "1200",
    "billing_scheme": "per_unit",
    "created": 1659479142,
    "currency": "usd",
    "interval": "month",
    "interval_count": 1,
    "livemode": false,
    "metadata": {},
    "nickname": null,
    "product": "prod_MApBpixJvIPdF1",
    "tiers_mode": null,
    "transform_usage": null,
    "trial_period_days": null,
    "usage_type": "licensed"
  }'''
nl: Create a planYou can now model subscriptions more flexibly using the Prices API. It replaces the Plans API and is backwards compatible to simplify your migration.Parameters amount Required unless billing_scheme=tiered A positive integer in cents (or 0 for a free plan) representing how much to charge on a recurring basis. currency required Three-letter ISO currency code, in lowercase. Must be a supported currency. interval required Specifies billing frequency. Either day, week, month or year. product required The product whose pricing the created plan will represent. This can either be the ID of an existing product, or a dictionary containing fields used to create a service product.Show child parameters active optional Whether the plan is currently available for new subscriptions. Defaults to true. metadata optional dictionary Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to metadata. nickname optional A brief description of the plan, hidden from customers.More parametersExpand all  id optional   tiers Required if billing_scheme=tiered   tiers_mode Required if billing_scheme=tiered   aggregate_usage optional   amount_decimal optional   billing_scheme optional   interval_count optional   transform_usage optional dictionary   trial_period_days optional   usage_type optional ReturnsReturns the plan object