CRADמפתחים
עברית

API לניהול העסק

נהלו תהליכים נתמכים של לקוחות, תורים, שירותים, צוות, יומנים ודוחות ב־CRAD מתוך הממשק שלכם.

לפני שימוש חי — בדקו יכולות פרוסות, הרשאות ומוכנות של החיבור שלכם.

בדקו את היכולות הפרוסות, הרשאות המפתח ומוכנות העסק בסביבה שלכם. דוגמאות HTTP נלכדו בבדיקות מבודדות; הסימון local-unreleased שלהן אינו אומר שה־API אינו פועל, ואינו מאשר את החיבור שלכם. במסלול הלקוח מאמתים טלפון בתבנית WhatsApp שהעסק הגדיר; SMS אינו נתמך. רישום בידי אדמין מורשה הוא פעולה נפרדת ללא קוד.

לפני הבקשה הראשונה

  1. מקבלים סביבת בדיקה

    מפתח API אחד עם הרשאות מפורשות להזמנות ולניהול העסק. כתובת ה־API מובנית ב־SDK ומזהי החיבור מתקבלים מהמפתח.

  2. בוחרים פעולה

    ב־API Reference מוצגים הנתיב, ההרשאות, הפרמטרים, גוף הבקשה והתשובות.

  3. מחברים לממשק שלכם

    משתמשים בלקוח HTTP של האתר. לפעולות לקוח מאמתים טלפון ב־WhatsApp; רישום בידי אדמין מורשה אינו דורש קוד. מפתח ה־API נשמר רק בשרת; אותו מפתח משמש לניהול ולחיבור הלקוחות לפי הרשאותיו.

הבקשה הראשונה

שמרו בשרת מפתח API אחד בשם CRAD_API_KEY. כתובת ה־API קבועה; הקריאה מחזירה את מזהי האתר והחיבור ואת ההרשאות שלהם.

פרטי הפעולה והתשובה
קריאה בלבד · cURL
curl --request GET \
  "https://api.crad.ai/v1/management" \
  --header "Authorization: Bearer ${CRAD_API_KEY}" \
  --header "Accept: application/json"
מחברים אדמין קיים? בדקו את מפתח ה־API

הריצו בשרת שלכם עם אותו מפתח API. הקריאה מציגה את הרשאות החיבור ואינה יוצרת לקוח או תור. אין צורך באימות טלפון או בחיבור WhatsApp עבור בדיקה זו.

קריאה בלבד · cURL
curl --request GET \
  "https://api.crad.ai/v1/management" \
  --header "Authorization: Bearer ${CRAD_API_KEY}" \
  --header "Accept: application/json"
פרטי הפעולה והתשובה

חיבור מהיר ונכון, שלב אחר שלב

מה לטעון פעם אחת, מה לבדוק בזמן אמת ואיך לסנכרן ל־DB של האתר בלי ליצור מקור הזמנות נוסף.

למדריך היישום היעיל

בקשה, אישור הקליניקה ועדכון ללקוחה

בעסק שמצריך אישור, ההזמנה מתקבלת כבקשה ממתינה. האתר ו־CRAD מאשרים או דוחים את אותה בקשה; מועד חלופי נקבע רק אחרי הסכמת הלקוחה ובדיקת זמינות חוזרת. שינוי וביטול לפי מדיניות העסק, ותזכורות לפי ההגדרה שלו.

למדריך בקשות ואישור תורים

סדר הפעולות להזמנת תור

מפת ניווט בחוזה הקיים. עדיין אינה דוגמת אינטגרציה שנבדקה מקצה לקצה.

View the 8-step HTTP workflow
  1. Discover the business

    Read published services, providers, timezone and capabilities. Let the customer choose a treatment, including an unpriced consultation option when the business publishes one. Display its fixed price, range or price-decided-at-visit explanation; never infer a service from catalogue order or its name. A bounded authorized display snapshot can make the treatment list fast; it is not a booking authority. Respect bookingEnabled: false before offering a booking.

    Retrieve catalog
  2. Create a visitor session

    Send the approved integrationId and keep the returned customer bearer in memory. Prepare this once the integration is known, without blocking treatment rendering on unrelated reads. Never expose a machine credential in browser code.

    Create a visitor session
  3. Quote and choose a time

    Use the selected service and provider to get a current quote, then request availability for the selected day in the business timezone. Display the returned times: a business can use treatment-duration spacing that restarts after scheduled breaks. Do not build a fixed 15-minute list or derive starts from duration alone. Treatment and time can be selected before phone verification. Do not preload slots for every date in a month or let an obsolete response restore an old selection. A displayed time is not reserved.

    Create a quoteFind available times
  4. Verify the phone

    Request a code only after an explicit customer action. Persist the challenge request UUID; retry uncertainty using that UUID and the original session. Use sessionToken and the expiry timestamps from the successful verify response for subsequent calls. Current phone proof is required for Customer API intents and commits; website login or a local projection does not replace it. Do not send another code automatically after reload. The business must configure a supported WhatsApp authentication template for the chosen language. Confirm verification readiness in the approved environment; documentation publication does not enable sending.

    Request a WhatsApp verification codeVerify a phone number
  5. Prepare and review the booking

    Save a request UUID before sending the booking intent, and use it as Idempotency-Key. Submit the quote, slot, customer details and explicit communication preference. Show the returned authoritative fixed price, optional priceRangeMinor estimate or price-decided-at-visit explanation. Exact price stays null for a range or unknown price; a range minimum is not a fixed charge. Do not replace a null quote with zero or a catalogue fallback. Changed terms require fresh confirmation.

    Prepare a booking
  6. Submit the saved intent

    After the customer reviews the request, send intentId to create the booking. Idempotency-Key must be the operationId returned with that exact intent, not the earlier request UUID. Render the receipt status: pending means the request was received and awaits clinic approval; confirmed means the appointment was confirmed. An accepted request is separate from WhatsApp delivery.

    Submit a booking request
  7. Recover an uncertain result

    After reload, obtain fresh same-phone proof and recover the saved request, intent or operation. Recovery must not auto-confirm. A not_found result does not prove an in-flight request cannot commit; keep the original locator until reconciliation or authoritative abandonment.

    Recover an intent requestRetrieve operation result
  8. Manage the accepted request or booking

    Refresh the booking and allowedActions. A contact_business policy directs customer cancellation/rescheduling to the saved business contact. Where self-service is allowed, prepare a change intent, review its terms and commit using its returned operation identity. An offered alternative requires the customer’s separate acceptance.

    Retrieve a bookingPrepare a booking change

מדריכים

מה קיים בחוזה

יכולתמצב
הזמנה ללקוחקטלוג, זמינות, אימות, יצירה, שינוי וביטול תור
נתוני החיבורלקוחות ותורים של החיבור, שינויים והיסטוריה לפי הרשאות
ניהול שעות וימיםשעות וחסימות לפי משאב עסק או נותנת שירות; קריאות נפרדות וחובה לבדוק השפעה לפני שינוי
רישום לקוח מהאדמין שלכםיצירה או קישור לפי שם וטלפון, בהרשאה נפרדת, ללא קוד אימות וללא מתן הסכמה להודעות
ניהול וסנכרון לקוחות העסקחיפוש, שם ושפה, חסימה וסנכרון כלל הלקוחות; הערות ושדות נוספים דורשים אישור נפרד
יומן העסקקריאה, יצירה, שינוי וביטול תורים בהרשאות יומן נפרדות ובדיקת השפעה
כללי הזמנהאזור זמן, משך ברירת מחדל וזמן מינימלי להזמנה ולביטול. טווח משותף לאתר ול־WhatsApp: ‏14/30/60/90 ימים לפי אזור הזמן של העסק, ברירת מחדל 14. השינויים נבדקים מראש ושומרים על התורים הקיימים.
משך תור וירושת הגדרותברירת מחדל לעסק והגדרה נפרדת לנותן שירות; עדכון תורים עתידיים דורש סקירת השפעה והרשאה נוספת
תיקון טלפון בידי מנהלתיקון לאותו לקוח בהרשאה נפרדת; קשרי זהות או שליחות פתוחות עשויים לדרוש טיפול קודם
שירותים ותוכן האתרניהול קטלוג, בחירת שירותים להצגה, פרטי קשר ציבוריים ותמונות; הרשאות נפרדות, ללא הפעלה אוטומטית של הזמנות
נותני שירותקריאה, עריכה וסנכרון נותנים קיימים שהורשו לחיבור ושיוך שירותים; יצירת חשבון כניסה לנותן קיים דורשת הרשאה נפרדת ואינה שולחת הזמנה
שיחות והודעותקריאת שיחות, מעבר לטיפול אנושי ושליחת טקסט, מדיה או תבנית; לפי הרשאות נפרדות, מצב החיבור וכללי השליחה של WhatsApp
סיכומי פעילותספירת תורים להיום, לשבוע ולמחר לפי אזור הזמן של העסק, בהרשאה נפרדת לכל העסק; ללא פרטי לקוחות או סכומים כספיים
דוח תפעולי חודשיחודש מלא, סטטוסים ופילוח לפי ימים, שירותים ונותנים, עם ערך טיפולים שהושלמו לפי מטבע; הרשאת reports:read לכל העסק. אין זה דוח תשלומים או תקבולים
המשך להגדרות הבעליםקישורים להגדרות האתר, החיבור, המכשיר ו־WhatsApp; נדרשים כניסת הבעלים ובדיקה עדכנית. פתיחת קישור אינה משנה הגדרות או מאשרת הרשאות
מחוץ לחוזה הנוכחייצירה ומחיקה של רשומות נותני שירות, שליחת הזמנות לצוות, שינוי סיסמאות קיימות ודוחות תשלומים או הנהלת חשבונות
לכל פעולות ה־API

איפה נשמרים הנתונים?

CRAD מנהלת את אנשי הקשר והתורים. האתר יכול לשמור עותק של הנתונים שהורשה לקבל; החשבונות וההערות הפרטיות שלו נשארים אצלו. סנכרון כלל לקוחות העסק דורש מפתח ניהול והרשאה מפורשת, בנפרד מנתוני לקוחות החיבור.

תיאום סביבת API ב־WhatsApp

תיפתח טיוטת פנייה לצוות CRAD. אפשר לערוך אותה לפני השליחה; אל תצרפו מפתחות גישה.