Create a purchase
documentedCreate a new purchase (track a transaction).
POST /v4/purchasesPurchasesno implementation yet0 runsNo implementation yet. Run it to have the agent write one, or open a pull request with your own.
Seed example (keychains curl)
npx -y keychains@latest curl "https://api.kit.com/v4/purchases" \
-X POST \
-H 'Authorization: Bearer {{OAUTH2_ACCESS_TOKEN}}' \
-H 'Content-Type: application/json' \
-H 'Accept: application/json' \
-d '{"purchase": {"email_address": "{{$email_address}}", "transaction_id": "{{$transaction_id}}", "status": "{{$status}}", "subtotal": {{$subtotal}}, "tax": {{$tax}}, "shipping": {{$shipping}}, "discount": {{$discount}}, "total": {{$total}}, "currency": "{{$currency}}", "transaction_time": "{{$transaction_time}}", "products": [{"name": "{{$product_name}}", "pid": "{{$product_pid}}", "lid": "{{$product_lid}}", "quantity": {{$product_quantity}}, "unit_price": {{$product_unit_price}}, "sku": "{{$product_sku}}"}]}}'"