ai

POST /v1/ai/site-builds/{siteBuildId}/plugin-plan

Which plugins this generated site needs, and a custom one if it needs that.

جميع نقاط نهاية ai

المصادقة

أرسل مفتاح واجهة برمجة التطبيقات (API key) كرمز حامل (bearer token). يجب أن يحمل المفتاح إذن sites.create؛ والمفتاح الذي لا يملكه يُرفض بالرمز 403 وليس 404.

لا يقبل هذا الطرف أي معرف للمؤسسة. يحدد مفتاحك بالفعل المؤسسة التي ينتمي إليها، وتكون الاستجابة محصورة في نطاقها.

جربه الآن

استبدل أي شيء بين أقواس زاوية بقيمك الخاصة، والعنصر النائب للمفتاح بمفتاح من لوحة تحكمك.

curl -X POST https://api.zinndigital.com/v1/ai/site-builds/{siteBuildId}/plugin-plan \
  -H "Authorization: Bearer zdk_live_…"

هل سجلت الدخول؟ تقوم وحدة تحكم واجهة برمجة التطبيقات في لوحة التحكم الخاصة بك بربط معرف مؤسستك الحقيقي ومفتاحك الخاص، وتنفذ الطلب مقابل واجهة برمجة التطبيقات المباشرة لتتمكن من رؤية الاستجابة الفعلية. افتح هذه النهاية الطرفية في وحدة تحكم API

التفاصيل

Chooses plugins for the generated site from a curated set, and writes one small WordPress plugin when the site needs behaviour no listed plugin provides. Generated PHP is **scanned before it is packaged**, not before it is installed: dynamic execution, shell access, remote includes, direct filesystem writes, unescaped request data and hand-built SQL are refused outright, and a plugin that fails never becomes an archive at all. When that happens the reason appears in `notes` — a scan that silently dropped its subject would be indistinguishable from a scan that found nothing. Slugs the model proposes that are not in the curated set are dropped and **counted** in `rejected` rather than passed through. The generated plugin's source is deliberately not returned. It is real PHP that has passed the scan; handing it to a client invites an edited copy to be posted back on a path that believes it was scanned. Ask for it at publish time with `include_generated_plugin`, and it is regenerated and re-scanned there. Spends AI credit and is metered under the `site_builder` surface, on the one AI meter. Requires `sites.create`.

المعلمات

الاسمالنوعمطلوبما هو هذا
siteBuildId (path)Uuidنعم

الاستجابة

الاسمالنوعمطلوبما هو هذا
planSiteMakerPluginPlanنعم
catalogueobject[]نعمThe curated set the model may choose from, and nothing else.

الأخطاء التي يمكن أن تُرجعها نقطة النهاية هذه

401 · 403 · 404 · 422 · 429