انتقل إلى المحتوى الرئيسي

بوابة المطور ECOSIRE

قم ببناء عمليات تكامل قوية مع REST API الشامل الخاص بنا. أكثر من 818 نقطة نهاية، ومواصفات OpenAPI الكاملة، وTypeScript SDK.

818+
نقاط نهاية API
57
وحدات
REST
الهندسة المعمارية
11
اللغات المدعومة
API

بداية سريعة

ابدأ العمل باستخدام ECOSIRE API خلال دقائق

1

مصادقة

استخدم OAuth2 عبر مفاتيح Authentik أو API للحصول على رمز حامل JWT للوصول إلى API.

POST /api/auth/login
2

قم بإجراء مكالمتك الأولى

استخدم الرمز المميز لحامله في رأس التفويض للاتصال بأي نقطة نهاية لواجهة برمجة التطبيقات.

# قائمة كافة جهات الاتصال
curl -H "Authorization: Bearer $TOKEN" \
https://api.ecosire.com/api/contacts
3

استدعِ نقطة نهاية عامة

كتالوج التطبيقات مفتوح: بلا مفتاح وبلا أي شيء لتثبيته. يعمل أي عميل HTTP.

const res = await fetch(
"https://api.ecosire.com/api/apps/platforms"
);
const platforms = await res.json();
57 Modules

وحدات واجهة برمجة التطبيقات

استكشف 57 وحدة تغطي كل جانب من جوانب عمليات المؤسسة

الأساسية

AuthUsersContactsProductsOrdersProjectsSettings

المالية

AccountingSalesPurchaseBillingInvoicing

العمليات

InventoryManufacturingPOSRentalPlanning

الموارد البشرية

EmployeesRecruitmentTime OffAttendanceExpensesPayrollAppraisals

التسويق والنمو

Email MarketingEventsMarketing AutomationAnalyticsAffiliatesLoyalty

الذكاء الاصطناعي والأتمتة

ECOSIRE AISelf-Evolving EngineContent GenerationSEO Scanner
Security

المصادقة

طريقتان للمصادقة لتناسب احتياجات التكامل الخاصة بك

ملفات تعريف الارتباط HttpOnly

مصادقة آمنة تعتمد على ملفات تعريف الارتباط لتطبيقات المتصفح. لا يتم عرض الرموز المميزة أبدًا لجافا سكريبت.

  • تلقائي مع تطبيق الويب
  • HttpOnly، Secure، SameSite=Lax
  • تناوب رمز التحديث لمدة 7 أيام

رمز حامل

استخدم الرموز المميزة لحامل JWT لعمليات التكامل من خادم إلى خادم وعملاء API.

// Authorization header
Authorization: Bearer <your_jwt_token>
// Or via HttpOnly cookie
Cookie: ecosire_auth=<token>
Interactive

API Playground

Try any endpoint directly from your browser. Select an endpoint, fill in parameters, and send live requests to the ECOSIRE API.

ECOSIRE API Playground
POST/auth/login

Login with email and password

Code Snippet
curl -X POST \ \
  "https://api.ecosire.com/api/auth/login" \ \
  -H "Content-Type: application/json" \
  -d '{   "email": "user@example.com",   "password": "secret" }'
HTTP

أمثلة برمجية عبر HTTP

لا شيء لتثبيته. استدعِ الواجهة البرمجية بعميل HTTP المضمّن في لغتك، فكل طلب أدناه يعمل على الواجهة البرمجية الحية.

أمثلة برمجية

الكتالوج والتراخيص وأدوات الوكلاء — بلغات curl وTypeScript وPython وPHP وRuby

1. عرض المنصات

كل منصة في كتالوج التطبيقات، مع عدد التطبيقات المدرجة فيها وعدد التطبيقات الجاهزة للتثبيت اليوم. لا حاجة إلى مفتاح.

curl -s "https://api.ecosire.com/api/apps/platforms" \
  -H "User-Agent: my-integration/1.0"

# 200 OK — no key needed
# [
#   { "platform": "odoo", "slug": "odoo", "label": "Odoo",
#     "appCount": <apps listed>, "sellableCount": <ready to install today> },
#   ...
# ]
Webhooks

Webhook Events

ECOSIRE sends real-time webhook events to your server when key actions occur — payments, subscriptions, license activations, and more.

Webhook Event Tester

Explore all 8 webhook events, generate cURL commands, and verify HMAC signatures.

Checkout Completed

checkout.session.completed

Fired when a customer completes payment in a Stripe Checkout Session.

Trigger: Customer pays for a product in the storefront. Auto-grants licenses and creates order.

Example JSON payload delivered to your webhook endpoint for checkout.session.completed.

json
{
  "id": "evt_1ABCxyz",
  "object": "event",
  "type": "checkout.session.completed",
  "created": 1711000000,
  "data": {
    "object": {
      "id": "cs_live_abc123",
      "object": "checkout.session",
      "customer_email": "customer@company.com",
      "amount_total": 24900,
      "currency": "usd",
      "mode": "payment",
      "payment_status": "paid",
      "metadata": {
        "userId": "usr_01HXYZ",
        "productIds": "[\"prd_01HODOOCRM\"]"
      }
    }
  }
}

All Webhook Events

Event
checkout.session.completed
invoice.paid
customer.subscription.deleted
customer.subscription.updated
charge.refunded
payment_intent.payment_failed
license.validated
license.activated

Verify webhook signatures in production

Always verify the stripe-signature header for Stripe events using your STRIPE_WEBHOOK_SECRET. For license events, verify the X-License-Signature header using ECOSIRE_LICENSE_SECRET. Unverified events should be rejected with 401.

Reference

Error Codes

All API errors follow RFC 7807 (Problem Details for HTTP APIs). Every error includes a machine-readable code and human-readable message.

StatusMeaning
200OK
201Created
204No Content
400Bad Request
401Unauthorized
403Forbidden
404Not Found
409Conflict
422Unprocessable
429Too Many Requests
500Server Error
Error Response Shape
{
  "statusCode": 422,
  "error": "Unprocessable Entity",
  "message": "Validation failed",
  "details": [
    { "field": "email", "message": "Invalid email address" },
    { "field": "password", "message": "Must be at least 8 characters" }
  ]
}
Rate Limits

حدود المعدل

حدود الاستخدام العادل لضمان استقرار واجهة برمجة التطبيقات (API) لجميع المستخدمين

نقطة النهايةحد السعر
POST /support5/min
POST /crm/capture10/min
POST /ecosire-ai/ask20/min
POST /licenses/validate30/min
POST /licenses/activate10/min
POST /newsletter/subscribe5/min
Authenticated endpoints100/min

Rate Limit Response Headers

X-RateLimit-LimitMaximum requests allowed in the window
X-RateLimit-RemainingRequests remaining in the current window
X-RateLimit-ResetUnix timestamp when the window resets
Retry-AfterSeconds to wait before retrying (on 429)
API Keys

API Key Management

Create and manage API keys from your dashboard. Each key can be scoped to specific permissions and rotated independently.

Create API Keys

Generate new API keys from Dashboard → Settings → API Keys. Each key has a name, optional expiry date, and role scope.

Scoped Permissions

Keys can be scoped to read-only, read-write, or admin. Admin keys can manage other keys and access all endpoints.

Key Rotation

Rotate keys at any time without downtime. The old key remains valid for 24 hours after rotation for a smooth transition.

Usage Analytics

View per-key request counts, error rates, and last-used timestamps from the API Keys dashboard page.

Environment Keys

Maintain separate keys for development, staging, and production. Production keys log all requests for audit purposes.

Webhook Secrets

Webhook endpoints also use a separate ECOSIRE_LICENSE_SECRET for HMAC-SHA256 signature verification on license events.

Using an API Key

# Pass the key as a Bearer token in the Authorization header
curl https://api.ecosire.com/api/contacts \
  -H "Authorization: Bearer ecos_live_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"

# Or use HttpOnly cookies (browser-based auth — set automatically on login)
# Cookie: ecosire_auth=<jwt_token>
FAQ

الأسئلة المتداولة

الأسئلة الشائعة حول ECOSIRE API

كيف يمكنني الحصول على الوصول إلى API؟

قم بالتسجيل للحصول على حساب ECOSIRE وانتقل إلى Dashboard > API Keys لإنشاء بيانات اعتماد API الخاصة بك. الوصول إلى واجهة برمجة التطبيقات (API) متاح في جميع الخطط.

هل هناك طبقة مجانية؟

نعم، تتضمن جميع حسابات ECOSIRE إمكانية الوصول إلى واجهة برمجة التطبيقات (API). تختلف حدود الأسعار حسب الخطة. تدعم الطبقة المجانية ما يصل إلى 1000 استدعاء لواجهة برمجة التطبيقات يوميًا.

ما هي طرق المصادقة المدعومة؟

نحن ندعم OAuth2 عبر Authentik (موصى به لتطبيقات الويب)، والرموز المميزة لحامل JWT (من خادم إلى خادم)، ومفاتيح API (من أجل عمليات تكامل بسيطة).

هل لديك دعم webhook؟

نعم، يدعم ECOSIRE خطافات الويب لإشعارات الأحداث في الوقت الفعلي. قم بتكوين نقاط نهاية خطاف الويب في لوحة المعلومات > الإعدادات > خطافات الويب.

ما هي اتفاقية مستوى الخدمة لوقت تشغيل واجهة برمجة التطبيقات (API)؟

نحن لا ننشر نسبة مئوية لوقت التشغيل، بل ننشر النظام الذي يقف خلفه. تعمل واجهة برمجة التطبيقات كعنقود متعدد النسخ مع فحوص سلامة، وتُنشر الإصدارات بإعادة تحميل دون توقف بدل إعادة التشغيل، وحالة الخدمة المباشرة وسجل الحوادث متاحان على status.ecosire.com. أما التزامات الاستجابة للحوادث فتُحدَّد في اتفاقية الدعم الخاصة بك، لا في رقم تسويقي.

جاهز للبناء؟

احصل على مفتاح API الخاص بك وابدأ في إنشاء عمليات التكامل في دقائق.