MercadoPago icon

MercadoPago

Consume MercadoPago API

Payment → Create Payment Link

AI-generated

Summary

Create a MercadoPago checkout payment link by specifying product items and optional parameters, returning the payment preference details.

Inputs

  • Items (required) — A collection of one or more items, each requiring a title, quantity (≥1), and unit price (>0); optional fields include ID, description, picture URL, category ID, and currency code.
  • Additional Fields — Optional settings including external reference (up to 64 alphanumeric/hyphen/underscore chars), notification URL (HTTPS), binary mode flag, statement descriptor (up to 13 chars), expiration dates (ISO 8601 format with timezone; 'from' must be before or equal to 'to'), auto return setting ('none','approved','all'), and related back URLs (success, pending, failure) with HTTPS or deeplink schemes.
  • Simplify — Boolean to control whether the returned data is a simplified payment link summary or the full raw API response.

Output shape

a single object representing the created payment preference

If 'Simplify' is true, returns a concise object with key fields such as preference ID, init points, external reference, creation and expiration dates, and expiration flag; otherwise returns the complete API response object.

Examples

Example 1: Create a payment link for items with title, quantity, and price, optionally setting return URLs and notifications.

Provide at least one item with valid title, positive quantity and unit price. Optionally set external reference, notification URL, and customize return URLs for success, pending, or failure. Enable simplify to receive a streamlined response.

Links

Discussion