hosting
GET /v1/sites/{siteId}/ide-assist/credit
What the site's web editor shows beside its assistant.
توثيقِ شناخت
یہ اینڈ پوائنٹ عوامی ہے۔ یہ کوئی اسناد اور کوئی تنظیم نہیں لیتا — یہ وہ ہے جسے ہماری اپنی مارکیٹنگ سائٹ اور AI کے جواب دینے والے انجن پڑھتے ہیں۔
یہ اینڈ پوائنٹ کوئی آرگنائزیشن آئی ڈی نہیں لیتا۔ آپ کی کلید پہلے ہی اس آرگنائزیشن کی شناخت کرتی ہے جس سے یہ تعلق رکھتی ہے، اور اس کا جواب اسی کے مطابق محدود ہوتا ہے۔
آزمائیں
کوئی بھی چیز جو زاویہ دار قوسین میں ہو اسے اپنی اقدار سے بدلیں، اور کلیدی پلیس ہولڈر کو اپنے ڈیش بورڈ کی کسی کلید سے بدلیں۔
curl -X GET https://api.zinndigital.com/v1/sites/{siteId}/ide-assist/creditلاگ ان ہیں؟ آپ کے ڈیش بورڈ میں موجود API کنسول آپ کی حقیقی تنظیم کی آئی ڈی اور آپ کی اپنی کلید خود بخود پُر کر دیتا ہے، اور لائیو API پر درخواست چلاتا ہے تاکہ آپ اصل ردعمل دیکھ سکیں۔ اس اینڈ پوائنٹ کو API کنسول میں کھولیں
تفصیلات
The AI balance for the organisation that owns this site, and where its owner tops it up. The editor paints this when the assistant panel opens; every chat turn carries the same object back afterwards, so the number the customer sees is the one after their own question rather than one call behind it. spendable_micros is the figure to render, not balance_micros. They differ by whatever is left of today's included allowance, and an organisation with a zero balance and an unspent allowance can still ask the assistant anything it likes. This never refuses for lack of credit: the customer who has run out is precisely the one who needs this screen and its top_up_url.
پیرامیٹرز
| نام | قسم | لازمی | یہ کیا ہے |
|---|---|---|---|
siteId (path) | Uuid | ہاں | Site ID (UUIDv7). |
جواب
| نام | قسم | لازمی | یہ کیا ہے |
|---|---|---|---|
available | boolean | ہاں | False when the meter could not be read. A third state on purpose: we could not look is not you have nothing, and collapsing them puts a top-up prompt in front of an account… |
currency | string | نہیں | ISO 4217, for the amounts below. |
balance_micros | integer | نہیں | Purchased credit held, in USD micros. ⛔ Not what they can spend — see spendable_micros. |
spendable_micros | integer | نہیں | Everything that can pay for the next call: the balance PLUS what is left of today's included allowance. This is the number the editor renders. |
included_remaining_micros | integer | نہیں | What is left of today's included allowance, in USD micros. |
is_low | boolean | نہیں | Whether what is spendable is low enough to say so. Computed by the meter rather than by each screen, because a second implementation of "low" is a second answer and the screen's… |
is_empty | boolean | نہیں | Nothing can fund the next call — no credit and no allowance left. |
on_byo | boolean | نہیں | The organisation holds a live key for every provider we route to, so credit genuinely cannot be spent. The editor shows no top-up affordance here: selling credit to somebody whose… |
top_up_url | string | نہیں | Where this customer adds credit, resolved from their own brand — a reseller's customer is never sent to a hostname that is not their reseller's. Empty when on_byo is true,… |
وہ خرابیان جو یہ اینڈ پوائنٹ واپس کر سکتا ہے
404