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

Translation

Catalog translation, review queue, glossary.

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

POST/v1/translate/backfill

Translate the catalog (or estimate cost with dry_run)

يحتاج إلى مفتاح أو جلسة في لوحة التحكم

المعاملات

الاسمالموضعالنوعإلزاميالوصف
Idempotency-Keyheaderstring | nullلاUnique per logical write (8-255 chars). Retries with the same key are safe. · pattern ^[A-Za-z0-9_\-:.]{8,255}$

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

الاسمالنوعإلزاميالوصف
target_localestringلاdefault "ar" · pattern ^[a-z]{2}$
fields"name" | "description" | "category" | "attribute_name" | "attribute_value"[]لا
scope"all" | "missing" | "stale"لاdefault "missing"
product_idsstring[] | nullلا
review_top_nintegerلاAlso send the top N products to the review queue.default 0 · min 0 · max 5000
dry_runbooleanلاOnly estimate count and cost.default false

الردود

GET/v1/translate/status

Translate Status

يحتاج إلى مفتاح أو جلسة في لوحة التحكم

المعاملات

الاسمالموضعالنوعإلزاميالوصف
target_localequerystringلاA tenant locale, e.g. ar. · default "ar" · pattern ^[a-z]{2}$

الردود

GET/v1/translate/review

Review queue (with source, translation and quality checks)

يحتاج إلى مفتاح أو جلسة في لوحة التحكم

المعاملات

الاسمالموضعالنوعإلزاميالوصف
statusquery"pending" | "machine" | "review" | "approved" | "rejected" | "human_edited" | "stale"لاdefault "review"
cursorquerystring | nullلاmax length 200
limitqueryintegerلاdefault 50 · min 1 · max 200

الردود

POST/v1/translate/review/bulk

Translate Review Bulk

يحتاج إلى مفتاح أو جلسة في لوحة التحكم

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

الاسمالنوعإلزاميالوصف
idsstring[]نعم
action"approve" | "reject"نعم

الردود

POST/v1/translate/review/{translation_id}

Approve, reject or edit one translation (edit = human_edited, never overwritten)

يحتاج إلى مفتاح أو جلسة في لوحة التحكم

المعاملات

الاسمالموضعالنوعإلزاميالوصف
translation_idpathstringنعم

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

الاسمالنوعإلزاميالوصف
action"approve" | "reject" | "edit"نعم
textstring | nullلاRequired for edit; marks it human_edited.max length 20000

الردود

GET/v1/translate/export

Export approved translations as CSV or SQL (for stores without write-back)

يحتاج إلى مفتاح أو جلسة في لوحة التحكم

المعاملات

الاسمالموضعالنوعإلزاميالوصف
formatquery"csv" | "sql_opencart" | "json"لاdefault "csv"
target_localequerystringلاA tenant locale, e.g. ar. · default "ar" · pattern ^[a-z]{2}$

الردود

  • 200Successful Responsestring
GET/v1/translate/approved

Approved translations to write into the store (store modules poll this)

يحتاج إلى مفتاح أو جلسة في لوحة التحكم

For modules without a pull API (OpenCart, WooCommerce, Magento). Secret key. Returns rows approved or human-edited since the cursor, oldest first. After writing them, call POST /v1/translate/ack.

المعاملات

الاسمالموضعالنوعإلزاميالوصف
localequerystringنعمA tenant locale, e.g. ar. · pattern ^[a-z]{2}$
sincequerystring | nullلاnext_cursor from the last call · max length 200
limitqueryintegerلاdefault 200 · min 1 · max 500

الردود

POST/v1/translate/ack

Mark translations as written into the store (sets written_back_at)

يحتاج إلى مفتاح أو جلسة في لوحة التحكم

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

الاسمالنوعإلزاميالوصف
idsstring[]نعم

الردود

GET/v1/translate/glossary

Glossary List

يحتاج إلى مفتاح أو جلسة في لوحة التحكم

المعاملات

الاسمالموضعالنوعإلزاميالوصف
cursorquerystring | nullلاmax length 200
limitqueryintegerلاdefault 200 · min 1 · max 200

الردود

POST/v1/translate/glossary

Glossary Create

يحتاج إلى مفتاح أو جلسة في لوحة التحكم

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

الاسمالنوعإلزاميالوصف
source_localestringنعمpattern ^[a-z]{2}$
target_localestringنعمpattern ^[a-z]{2}$
source_termstringنعمmax length 300
target_termstring | nullلاmax length 300
do_not_translatebooleanلاdefault false
case_sensitivebooleanلاdefault false
notestring | nullلاmax length 1000

الردود

PUT/v1/translate/glossary/{term_id}

Glossary Update

يحتاج إلى مفتاح أو جلسة في لوحة التحكم

المعاملات

الاسمالموضعالنوعإلزاميالوصف
term_idpathstringنعم

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

الاسمالنوعإلزاميالوصف
source_localestringنعمpattern ^[a-z]{2}$
target_localestringنعمpattern ^[a-z]{2}$
source_termstringنعمmax length 300
target_termstring | nullلاmax length 300
do_not_translatebooleanلاdefault false
case_sensitivebooleanلاdefault false
notestring | nullلاmax length 1000

الردود

DELETE/v1/translate/glossary/{term_id}

Glossary Delete

يحتاج إلى مفتاح أو جلسة في لوحة التحكم

المعاملات

الاسمالموضعالنوعإلزاميالوصف
term_idpathstringنعم

الردود

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

BackfillRequest

الاسمالنوعإلزاميالوصف
target_localestringلاdefault "ar" · pattern ^[a-z]{2}$
fields"name" | "description" | "category" | "attribute_name" | "attribute_value"[]لا
scope"all" | "missing" | "stale"لاdefault "missing"
product_idsstring[] | nullلا
review_top_nintegerلاAlso send the top N products to the review queue.default 0 · min 0 · max 5000
dry_runbooleanلاOnly estimate count and cost.default false

BackfillEstimate

الاسمالنوعإلزاميالوصف
productsintegerنعم
fieldsintegerنعم
estimated_cost_usdstringنعم
jobJob | nullلا

Job

A row of the shared `jobs` table. Poll GET /v1/jobs/{id} until status is terminal.

الاسمالنوعإلزاميالوصف
idstringنعم
kind"reindex" | "import" | "sync" | "translate_backfill" | "translate_writeback" | "export" | "data_export" | "data_delete" | "embed" | "synonym_mining"نعم
status"queued" | "running" | "succeeded" | "failed" | "canceled"نعم
progressnumberلاdefault 0 · min 0 · max 1
created_atstring (date-time)نعم
started_atstring (date-time) | nullلا
finished_atstring (date-time) | nullلا
resultobject | nullلا
errorstring | nullلا

TranslationStatusOut

الاسمالنوعإلزاميالوصف
target_localestringنعم
total_fieldsintegerنعم
by_statusmap<string, integer>نعم
human_editedintegerنعم
cost_month_usdstringنعم
watch_enabledbooleanنعم
running_jobJob | nullلا

Page_TranslationItem_

الاسمالنوعإلزاميالوصف
dataTranslationItem[]نعم
next_cursorstring | nullلا
totalinteger | nullلاPresent when cheap to count.

TranslationItem

الاسمالنوعإلزاميالوصف
idstringنعم
product_idstringنعم
field"name" | "description" | "category" | "attribute_name" | "attribute_value"نعم
field_keystringلا
source_localestringنعم
target_localestringنعم
source_textstringنعم
translated_textstring | nullنعم
ai_translatedbooleanنعم
status"pending" | "machine" | "review" | "approved" | "rejected" | "human_edited" | "stale"نعم
quality_scorenumber | nullلا
quality_notesobjectلاe.g. brand/model/spec kept checks
updated_atstring (date-time)نعم

BulkReview

الاسمالنوعإلزاميالوصف
idsstring[]نعم
action"approve" | "reject"نعم

BulkReviewResult

الاسمالنوعإلزاميالوصف
updatedintegerنعم
skippedintegerنعم

ReviewDecision

الاسمالنوعإلزاميالوصف
action"approve" | "reject" | "edit"نعم
textstring | nullلاRequired for edit; marks it human_edited.max length 20000

TranslationWritePage

الاسمالنوعإلزاميالوصف
dataTranslationWriteItem[]نعم
next_cursorstring | nullلاPass back as ?since= next time (store it).

TranslationWriteItem

An approved translation for a store module to write into the store (ADR 0012, write-back).

الاسمالنوعإلزاميالوصف
idstringنعمSend it back in POST /v1/translate/ack after writing.
product_idstringنعم
field"name" | "description" | "category"نعم
field_keystringلاCategory id for field=category.
localestringنعم
textstringنعم
source_hashstringنعم
status"approved" | "human_edited"نعم
updated_atstring (date-time)نعم

TranslationAck

الاسمالنوعإلزاميالوصف
idsstring[]نعم

TranslationAckResult

الاسمالنوعإلزاميالوصف
updatedintegerنعم

Page_GlossaryTermOut_

الاسمالنوعإلزاميالوصف
dataGlossaryTermOut[]نعم
next_cursorstring | nullلا
totalinteger | nullلاPresent when cheap to count.

GlossaryTermOut

الاسمالنوعإلزاميالوصف
source_localestringنعمpattern ^[a-z]{2}$
target_localestringنعمpattern ^[a-z]{2}$
source_termstringنعمmax length 300
target_termstring | nullلاmax length 300
do_not_translatebooleanلاdefault false
case_sensitivebooleanلاdefault false
notestring | nullلاmax length 1000
idstringنعم
created_atstring (date-time)نعم

GlossaryTermIn

الاسمالنوعإلزاميالوصف
source_localestringنعمpattern ^[a-z]{2}$
target_localestringنعمpattern ^[a-z]{2}$
source_termstringنعمmax length 300
target_termstring | nullلاmax length 300
do_not_translatebooleanلاdefault false
case_sensitivebooleanلاdefault false
notestring | nullلاmax length 1000

Deleted

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