Latenode

Automatically Enroll Teachable Users For New SamCart Orders

This template receives a SamCart paid-order webhook, maps product to a Teachable course in JavaScript, and enrolls the buyer.

Teachable can create the user first if they are new. Connect Teachable. Put the Teachable API key on the Teachable connection. Paste the Latenode webhook URL into the SamCart webhook for successful purchases.

Updated Sep 16, 2026Est. run: 10sEst. cost: $0.0006
How Latenode estimates time and cost

Latenode bills workflow runtime in CPU seconds. The first 10,000 CPU seconds are free each month, then usage follows pay-as-you-go CPU-second pricing. Plug-and-Play (PnP) AI nodes are billed separately—each PnP token is $1 USD, charged pay-as-you-go at vendor cost plus a small processing fee, with no API keys required.

Full pricing — how CPU seconds work →

Workflow preview

What this template does

  • Moves a SamCart purchase into a Teachable course as soon as payment succeeds
  • Takes the order on a webhook
  • Maps product to course in JavaScript
  • Keeps the Teachable API key on the Teachable connection

How it works

1
Trigger

Catch the paid order

A webhook receives the SamCart payload when a purchase succeeds.

2
Logic

Map buyer and course

JavaScript reads email, name, and product, then picks the Teachable course id for that product.

3
Action

Enroll in Teachable

Teachable creates the user if needed and enrolls them in that course.

Setup guide

1

Add a webhook trigger

Add a webhook trigger and copy its URL. In SamCart, send successful purchase webhooks to this URL.

2

Connect Teachable

Add a Teachable connection and paste your Teachable API key there.

3

Map product to course

In JavaScript, map SamCart product or SKU to a Teachable course id. Create the Teachable user if they are new, then enroll them in that course. Place a test order and confirm the student is in the course.

Requirements

A SamCart product that can POST a purchase webhook
A Teachable school and API key stored on the Teachable connection
A Teachable course id for each product you sell

FAQ

Common questions about this template

Each run uses credits on your Latenode plan. We charge for processing time (1 credit = 30 seconds). Your actual cost depends on your plan and how long the run takes. See pricing plans for plans and how credits work.