Image Description Image Description

No Results

  • Support
Logo Logo v1.0
  • Basics
  • Getting started
  • Get authenticating user
  • Products
  • Create a Product
  • Update a Product
  • Delete a Product
  • Coupons
  • Create a Coupon
  • Update a Coupon
  • Delete a Coupon
  • List Coupons
  • License Keys
  • Verify a License Key
  • Redeem a License Key
  • Refund a License Key
  • Subscriptions
  • Verify a Subscription
  • Webhooks
  • Basics
  • Subscribe
  • Unsubscribe
  • Webhook Events
  • New sale
  • New lead
  • New affiliate sign-up
  • New subscription
  • Subscription cancellation

Create a Product

Endpoint

POST /products/create

Required parameters

  • title - VARCHAR(500) - The title of your product
  • url - VARCHAR(100) - The vanity URL for your product. Must be unique and contain alphanumeric, underscore, hyphen, or dot characters only.
  • currency - VARCHAR(3) - The lower-cased 3-letter ISO currency code for your product
  • price - DECIMAL - The base price of your product
  • pricing_model - VARCHAR(20) - The pricing model for your product, values can be:
    1. one-time - This is for one-time payments.
    2. subscription - This is for recurring payments.
    3. delayed - This is for delayed payments using credit card pre-authorization.
  • display - VARCHAR(11) - The display for your product, values can be:
    1. featured - Product appears as a large splash image/carousel at the top of your storefront.
    2. listed - Product appears as a listing in a grid.
    3. unlisted - Product does not appear in storefront but is still accessible to anyone with its link.
    4. unpublished - Product is not accessible to the public whatsoever.

Optional parameters

  • subtitle - VARCHAR(500) - The subtitle of your product, which appears below the title
  • description - TEXT - The description for your product, which should be in HTML format.
  • summary - TEXT - The "What You'll Get" section for your product, which should be in HTML format. This appears on the product page to show buyers what they'll receive.
  • interval - VARCHAR(5) - The interval for your subscription product.
    Required if pricing_model is set to subscription.
    Values can be:
    1. day - The subscriber will be charged every interval_count day(s).
    2. week - The subscriber will be charged every interval_count week(s).
    3. month - The subscriber will be charged every interval_count month(s).
    4. year - The subscriber will be charged every interval_count year(s).
  • interval_count - INT - How often to charge the subscriber based on interval_count.
    Required if pricing_model is set to subscription.
  • trial_period_days - INT - Number of days of free trial before the subscriber is charged.
    Applicable only if pricing_model is set to subscription.
  • collect_address_and_phone - BOOLEAN - Whether to collect buyer's address and phone number at checkout. Defaults to False.
  • shipping_fee - DECIMAL - If this is a shipped product, this is the shipping fee for the product.
  • shipping_type - VARCHAR(12) - The shipping fee type for your product. Values can be:
    1. flat - The shipping fee will be fixed regardless of the quantity of this product added to the cart.
    2. per_quantity - The shipping fee will be additive/cumulative and added per quantity of this product added to the cart.
  • categories - ARRAY - List of categories under which to put this product. If a given category doesn't exist, it will be created.
  • tags - ARRAY - List of tags to apply to this product. If a given tag doesn't exist, it will be created.
  • productimages - ARRAY - List of URLs of images for this product. Make sure your URLs are publicly accessible.
  • productfiles - ARRAY - List of URLs of files for this product. Make sure your URLs are publicly accessible.
  • download_email_subject - VARCHAR(100) - Subject line for the download email sent to buyers when files are included. Defaults to "You received a product!" if not provided.
  • download_email_body - TEXT - Body content for the download email sent to buyers when files are included. Should be in HTML format. Supports merge fields like . Include to place download links at a specific location, otherwise they're appended at the end. Defaults to "Here are your one-time download links:" if not provided.
  • success_url - VARCHAR(2500) - URL to redirect buyers to after successful payment. Can be a custom thank you page or exclusive link. Include https:// if external. Leave blank for default success page.
  • success_email_subject - VARCHAR(100) - Subject line for the success email sent to buyers after purchase. This is separate from the download email. Leave blank to disable success emails.
  • success_email_body - TEXT - Body content for the success email sent to buyers after purchase. Should be in HTML format. Supports merge fields like , , , etc. Leave blank to disable success emails.
  • gated_page_url - VARCHAR(100) - The URL slug for the gated page that buyers can access after purchase. Must be unique per brand and cannot clash with product URLs, page URLs, or funnel page URLs. Leave blank if you don't want to provide a gated page.
  • gated_page_body - TEXT - The body content for the gated page. Should be in HTML format. This is displayed on the gated page that buyers can access after purchase. Leave blank if you don't want to provide a gated page.
  • is_licensed - BOOLEAN - Whether to generate unique license keys for each purchase. Useful for software products. Defaults to false.
  • redemption_instructions - TEXT - Instructions for redeeming license keys. Included in the download email alongside license keys when is_licensed is true. Should be in HTML format. Leave blank if not applicable.
  • exclude_from_automations - BOOLEAN - Whether to exclude this product from workflow automations (e.g., Zapier, Pabbly Connect, webhooks). Email service provider integrations are unaffected. Defaults to false.

Example request

  
    curl https://api.zylvie.com/products/create \
      -h "Authorization: Bearer e97f0aafe4884bc380c81fdb2347dc55" \
      -h "Content-Type: application/json" \
      -d "title=Beautiful Product A" \
      -d "url=beautiful-product-a" \
      -d "currency=usd" \
      -d "price=19.99" \
      -d "pricing_model=subscription" \
      -d "display=listed" \
      -d "subtitle=The most beautiful product in the world, you won't need any other!" \
      -d "description=<p>This is the best product ever.</p><p>Check out more <a href='#'>here</a>!</p>"
      -d "summary=<p>What you'll get:</p><ol><li>A good product</li><li>A generous refund policy</li><li>The best customer service in the world</li>" \
      -d "interval=month" \
      -d "interval_count=1" \
      -d "trial_period_days=" \
      -d "collect_address_and_phone=false" \
      -d "shipping_fee=2" \
      -d "shipping_type=per_quantity" \
      -d "categories[]=Online Courses" \
      -d "categories[]=Digital Downloads" \
      -d "categories[]=Business Resources" \
      -d "tags[]=passive-income" \
      -d "tags[]=entrepreneur" \
      -d "tags[]=marketing" \
      -d "tags[]=business-strategy" \
      -d "productimages[]=https://cdn.example.com/products/phone-blue-angle.jpg" \
      -d "productimages[]=https://cdn.example.com/products/phone-front-view.jpg" \
      -d "productimages[]=https://cdn.example.com/products/phone-features.jpg" \
      -d "productfiles[]=https://downloads.example.com/manuals/phone-user-guide.pdf" \
      -d "productfiles[]=https://downloads.example.com/specs/phone-technical-specs.pdf" \
      -d "productfiles[]=https://downloads.example.com/warranty/phone-warranty-card.pdf" \
      -d "download_email_subject=You received a product!" \
      -d "download_email_body=<p>Hi ,</p><p>Here are your one-time download links:</p><p></p>" \
      -d "success_url=" \
      -d "success_email_subject=Welcome to Beautiful Product A!" \
      -d "success_email_body=<p>Hi ,</p><p>Thank you for your purchase!</p>" \
      -d "gated_page_url=members-area" \
      -d "gated_page_body=<p>Welcome to your exclusive members area!</p>" \
      -d "is_licensed=false" \
      -d "redemption_instructions=" \
      -d "exclude_from_automations=false"
  

Example response

  
    {
      "id": "6v8Obm2M", //Product ID
      "created": 1690952000, //UTC timestamp
      "title": "Beautiful Product A",
      "url": "beautiful-product-a",
      "currency": "usd",
      "price": 19.99,
      "pricing_model": "subscription",
      "display": "listed",
      "subtitle": "The most beautiful product in the world, you won't need any other!",
      "description": "<p>This is the best product ever.</p><p>Check out more <a href='#'>here</a>!</p>",
      "summary": "<p>What you'll get:</p><ol><li>A good product</li><li>A generous refund policy</li><li>The best customer service in the world</li>",
      "interval": "month",
      "interval_count": 1,
      "trial_period_days": null,
      "collect_address_and_phone": false,
      "shipping_fee": 2,
      "shipping_type": "per_quantity",
      "categories": [
        "Online Courses",
        "Digital Downloads",
        "Business Resources"
      ],
      "tags": [
        "passive-income",
        "entrepreneur",
        "marketing",
        "business-strategy"
      ],
      "productimages": [
        "https://cdn.example.com/products/phone-blue-angle.jpg",
        "https://cdn.example.com/products/phone-front-view.jpg",
        "https://cdn.example.com/products/phone-features.jpg"
      ],
      "productfiles": [
        "https://downloads.example.com/manuals/phone-user-guide.pdf",
        "https://downloads.example.com/specs/phone-technical-specs.pdf",
        "https://downloads.example.com/warranty/phone-warranty-card.pdf"
      ],
      "download_email_subject": "You received a product!",
      "download_email_body": "<p>Hi ,</p><p>Here are your one-time download links:</p><p></p>",
      "success_url": null,
      "success_email_subject": "Welcome to Beautiful Product A!",
      "success_email_body": "<p>Hi ,</p><p>Thank you for your purchase!</p>",
      "gated_page_url": "members-area",
      "gated_page_body": "<p>Welcome to your exclusive members area!</p>",
      "is_licensed": false,
      "redemption_instructions": null,
      "exclude_from_automations": false
    }