انتقل إلى المحتوى
القائمة
كل مجموعات الواجهة

Store apps

Hosted Shopify, Salla and Zid apps: OAuth install, webhooks, embedded admin.

5 نقاط وصول. أسماء نقاط الوصول وأوصافها مأخوذة من ملف OpenAPI، لذلك تظهر بالإنجليزية.

GET/v1/connectors/{platform}/install

Start the app install: redirect to the platform's OAuth consent page

لا يحتاج إلى مفتاح

المعاملات

الاسمالموضعالنوعإلزاميالوصف
platformpath"shopify" | "salla" | "zid"نعم
shopquerystring | nullلاShopify: <name>.myshopify.com · max length 255

الردود

  • 302Redirect to the platform (install) or to the embedded admin (callback)
GET/v1/connectors/{platform}/oauth/callback

OAuth callback: check state + signature, store tokens, create or link the tenant

لا يحتاج إلى مفتاح

المعاملات

الاسمالموضعالنوعإلزاميالوصف
platformpath"shopify" | "salla" | "zid"نعم

الردود

  • 302Redirect to the platform (install) or to the embedded admin (callback)
POST/v1/connectors/{platform}/webhooks

Platform webhooks: products, app uninstalled, Shopify GDPR topics (signature checked)

لا يحتاج إلى مفتاح

Shopify sends the topic in `X-Shopify-Topic`: products/create|update|delete, app/uninstalled, customers/data_request, customers/redact, shop/redact (mandatory GDPR webhooks). SeekGist stores no shopper personal data, so the customer topics are answered 200 and logged; shop/redact deletes the tenant's data (same job as POST /v1/data/requests kind=delete). Answer within 5 s; do the work in a job.

المعاملات

الاسمالموضعالنوعإلزاميالوصف
platformpath"shopify" | "salla" | "zid"نعم

الردود

POST/v1/connectors/{platform}/session

Embedded admin: exchange the platform session token for a SeekGist session

لا يحتاج إلى مفتاح

Sets the `sg_session` cookie (SameSite=None; Secure, because the admin runs inside the platform's iframe) for the store's tenant, with role owner, valid 1 hour. CSRF works as for the dashboard.

المعاملات

الاسمالموضعالنوعإلزاميالوصف
platformpath"shopify" | "salla" | "zid"نعم

جسم الطلب application/json StoreAppSessionRequest

الاسمالنوعإلزاميالوصف
tokenstringنعمShopify: App Bridge session token (JWT, HS256, signed with the app secret). Salla / Zid: the token their embedded page gives the app.min length 20 · max length 4000

الردود

GET/v1/connectors/{platform}/storefront

Storefront script config: the shop's public key and on/off switch

لا يحتاج إلى مفتاح

Called by the store-app storefront script (theme app extension / app snippet) before it starts the widget. Returns only public data: the public key is meant for browsers and is locked to the shop's origins. Unknown or switched-off shops get `enabled: false`. Cached (`Cache-Control: public, max-age=30`).

المعاملات

الاسمالموضعالنوعإلزاميالوصف
platformpath"shopify" | "salla" | "zid"نعم
shopquerystringنعمShopify: <name>.myshopify.com; Salla / Zid: store id · min length 1 · max length 255

الردود

أشكال البيانات في هذه الصفحة

WebhookAck

الاسمالنوعإلزاميالوصف
okbooleanلاdefault true

StoreAppSessionRequest

Embedded admin: trade the platform's short-lived session token for a SeekGist dashboard session.

الاسمالنوعإلزاميالوصف
tokenstringنعمShopify: App Bridge session token (JWT, HS256, signed with the app secret). Salla / Zid: the token their embedded page gives the app.min length 20 · max length 4000

LoginResult

On success the API sets the `sg_session` cookie (HttpOnly, Secure, SameSite=Lax) and returns the CSRF token, which the web app sends back as `X-CSRF-Token` on every write.

الاسمالنوعإلزاميالوصف
status"ok" | "mfa_required" | "email_sent"نعم
userUserOut | nullلا
csrf_tokenstring | nullلا
weak_passwordbooleanلاPassword sign-in only: the password is on the breached-password list or no longer meets the rules. Sign-in still works; ask the user to change it (POST /v1/auth/password/change).default false

UserOut

الاسمالنوعإلزاميالوصف
idstringنعم
emailstringنعم
namestring | nullنعم
locale"en" | "ar"نعم
email_verifiedbooleanنعم
totp_enabledbooleanنعم
is_superadminbooleanنعم
membershipsMembershipOut[]نعم

MembershipOut

الاسمالنوعإلزاميالوصف
idstringنعم
tenant_idstringنعم
tenant_namestringنعم
tenant_slugstringنعم
role"owner" | "admin" | "editor" | "viewer"نعم

StorefrontConfig

What the store-app storefront script needs to start the widget. `enabled: false` (unknown shop, app uninstalled or switched off in the embedded admin) means: leave the store's own search alone.

الاسمالنوعإلزاميالوصف
enabledbooleanنعم
keystring | nullلاThe store's public key (sg_pub_...), safe in a browser.
localestringلاdefault "en"
suggestbooleanلاdefault true
searchbooleanلاdefault true
assistantbooleanلاdefault false