Update subscription plan - Plans - Mercado Pago Developers
Update a subscription plan

PUT

/preapproval_plan/{id}
Renew the data of a plan. Indicate the plan ID and send the body with the information you want to update.
Request's parameters
id

REQUIRED

string
Localization: pathSubscription plan identifier
auto_recurring
object
Localization: bodyConfiguration data for recurrence.
back_url
string
Localization: bodySuccessful return URL. Use this setting to redirect your customers to your site after our checkout.
payment_methods_allowed
object
Localization: bodyPayment methods enabled at checkout.
Response parameters
id
string
Localization: bodyUnique subscription plan identifier.
application_id
number
Localization: bodyUnique ID that identifies your application/integration. One of the keys in the pair that make up the credentials that identify an application/integration in your account.
collector_id
number
Localization: bodyUnique ID that identifies your user as a seller. This ID matches your User ID in our ecosystem.
reason
string
Localization: bodyIt is a short description that the subscriber will see during the checkout process and in the notifications.
Request
curl
curl -X PUT \
    'https://api.mercadopago.com/preapproval_plan/{id}' \
    -H 'Authorization: Bearer YOUR_ACCESS_TOKEN' \
    -H 'Content-Type: application/json' \
    -d '{
  "reason": "Yoga classes",
  "auto_recurring": {
    "frequency": 1,
    "frequency_type": "months",
    "repetitions": 12,
    "billing_day": 10,
    "billing_day_proportional": true,
    "free_trial": {
      "frequency": 1,
      "frequency_type": "months"
    },
    "transaction_amount": 10,
    "currency_id": "ARS"
  },
  "payment_methods_allowed": {
    "payment_types": [
      {}
    ],
    "payment_methods": [
      {}
    ]
  },
  "back_url": "https://www.yoursite.com"
}'
Answer
json
{
  "id": "2c938084726fca480172750000000000",
  "application_id": 1234567812345678,
  "collector_id": 100200300,
  "reason": "Yoga classes",
  "auto_recurring": {
    "frequency": 1,
    "frequency_type": "months",
    "repetitions": 12,
    "billing_day": 10,
    "billing_day_proportional": true,
    "free_trial": {
      "frequency": 7,
      "frequency_type": "months",
      "first_invoice_offset": 7
    },
    "transaction_amount": 10,
    "currency_id": "ARS"
  },
  "payment_methods_allowed": {
    "payment_types": [
      {}
    ],
    "payment_methods": [
      {}
    ]
  },
  "back_url": "https://www.mercadopago.com.ar",
  "external_reference": "23546246234",
  "init_point": "https://www.mercadopago.com.ar/subscriptions/checkout?preapproval_plan_id=2c938084726fca480172750000000000",
  "date_created": "2022-01-01T11:12:25.892-04:00",
  "last_modified": "2022-01-01T11:12:25.892-04:00",
  "status": "active"
}
Errors
400bad_request
400400--Bad-Request--Check the parameters of the body
401bad_request
401401--Unauthorized--Unauthorized access to resource
404bad_request
404404--Not-found--The template with id {id} does not exist
500bad_request
500500--Error--Internal server error