billing

POST /v1/trials

Start a free trial on a plan.

सभी billing एंडपॉइंट्स

प्रमाणन

एक बीयर टोकन के रूप में एक API कुंजी भेजें। यह एंडपॉइंट विनिर्देश में किसी विशिष्ट अनुमति का उल्लेख नहीं करता है, इसलिए अपनी कुंजी को न्यूनतम आवश्यकता दें और अनुमान लगाने के बजाय प्रतिक्रिया की जाँच करें।

जहां आपकी संगठन आईडी आती है

यह एंडपॉइंट JSON बॉडी में एक फ़ील्ड के रूप में org_id लेता है।

आपकी ऑर्गनाइजेशन आईडी आपके डैशबोर्ड पर एपीआई कीज़ स्क्रीन पर, की के ठीक बगल में मौजूद है। यह आपके द्वारा की जाने वाली हर कॉल में समान आईडी होती है।

इसे आज़माएँ

कोणार्कित ब्रैकेट्स में दी गई किसी भी चीज़ को अपने मानों से बदलें, और की प्लेसहोलर को अपने डैशबोर्ड की एक की से बदलें।

curl -X POST https://api.zinndigital.com/v1/trials \
  -H "Authorization: Bearer zdk_live_…" \
  -H "Content-Type: application/json" \
  -d '{ "plan_code": <string> }'

साइन इन हैं? आपके डैशबोर्ड में मौजूद API कंसोल आपकी वास्तविक संगठन आईडी और आपकी अपनी कुंजी स्वतः भर देता है, और लाइव API के विरुद्ध अनुरोध चलाता है ताकि आप वास्तविक प्रतिक्रिया देख सकें। इस एंडपॉइंट को API कंसोल में खोलें

विवरण

docs/20. **The endpoint the "Start trial" buttons had nowhere to point at.** Three admin trial endpoints existed — list templates, edit a template, staff-extend a trial — and no customer-facing one, so all 47 CTAs on the public pricing page linked to `?intent=register`: *register first*, which is the opposite of what the button says. ⛔ `plan_code`, never a product line. Eligibility is a property of the **plan** (owner ruling 2026-07-29): cloud and VPS live in the same line as plans that do carry a trial, so a line-shaped request could not express "never on billable per-instance compute" at all. One trial per organization, enforced by a database constraint as well as a check — so a double-click races safely and the loser is refused rather than granted a second trial.

अनुरोध बॉडी

नामप्रकारआवश्यकयह क्या है
plan_codestringहाँ
org_idstringनहींRequired only when the caller bills for more than one organization. With exactly one it is unambiguous; with several it is asked for rather than guessed, because starting a rese…
auto_convert_opt_inbooleanनहीं⛔ Defaults to false — the direction that cannot take money nobody agreed to.

प्रतिक्रिया

नामप्रकारआवश्यकयह क्या है
idstringहाँ
org_idstringहाँ
statusstring<active, expired, converted, canceled>हाँ
product_linestringहाँThe line's CODE, not its display name — the dashboard renders the label from its own catalogue, so prose here would be a second, untranslated source of that word on the screen.
max_sitesintegerहाँ
started_atstringहाँ
ends_atstringहाँ
auto_convert_opt_inbooleanनहींWhether the customer agreed **at the start** that this may become a paid subscription when the period ends. Captured per trial rather than read from the template at expiry, so c…
days_remainingintegerनहींWhole days until `ends_at`, rounded UP and floored at zero. Computed on the server on purpose: a client doing `(ends_at - Date.now())` measures the **device** clock, so a laptop…
upgradeTrialUpgradeOfferनहींThe plan this trial invites the customer to buy, priced in their own currency (`X-Zinn-Currency`, falling back to the org default). ⛔ `null` when the template names no target or…

त्रुटियाँ जो यह एंडपॉइंट लौटा सकता है

401 · 403 · 404 · 422