Ana içeriğe geç

createICollectionRow

Koleksiyonda bir kayıt oluşturur.

Açıklama

Bir ICollectionRow nesnesine çözülmekte olan bir Promise döndürür.

IntegrationCollections.createICollectionRow(

marker, body, body.formIdentifier, body.formData, langCode

);

Parametreler şeması

Şema

marker(zorunlu): string
Koleksiyon metin tanımlayıcısı
örnek: "collection1"

body(zorunlu): ICollectionFormObject
Bir kayıt oluşturmak için nesne
örnek:

{
"formIdentifier": "collection-form",
"formData": {
"en_US": [
{
"marker": "collection_marker",
"type": "string",
"value": "Koleksiyon işaretçisi"
}
]
}
}

body.formIdentifier(zorunlu): string
Formun metin tanımlayıcısı (marker).
örnek: "collection-form"

body.formData(zorunlu): Record<string, ICollectionFormData>
Anahtarların form alanı işaretçileri ve değerlerin ICollectionFormData nesnelerinin dizileri olduğu bir nesne.
örnek:

[
{
"marker": "name_1",
"type": "string",
"value": "Değer"
}
]

langCode: string
Dil kodu. Varsayılan: "en_US"
örnek: "en_US"

Örnekler

Minimal örnek

const body = {
"formIdentifier": "collection-form",
"formData": [
{
"marker": "name_1",
"type": "string"
"value": "Değer"
}
]
};

const response = await IntegrationCollections.createICollectionRow(body);

Örnek yanıt

{
"formData": [
{
"marker": "c_marker",
"type": "string",
"value": "Değer"
}
],
"collectionId": 1,
"langCode": "en_US",
"createdDate": "2025-09-30T20:32:44.573Z",
"updatedDate": "2025-09-30T20:32:44.573Z",
"entityType": null,
"entityId": null,
"id": 461
}

Yanıt şeması

Şema: ICollectionRow

id: number
Nesne tanımlayıcısı.
örnek: 1

createdDate: string
Kayıt oluşturulma tarihi.
örnek: "2023-01-01T00:00:00Z"

updatedDate: string
Kayıt son güncelleme tarihi.
örnek: "2023-01-02T00:00:00Z"

collectionId: number | null
Koleksiyon satırı ile ilişkili collectionId.
örnek: "product", "order", "vs."

formData: ICollectionFormData[]
Koleksiyon satırı ile ilişkili form veri nesneleri dizisi.
örnek:

[
{
"marker": "name_1",
"type": "string",
"value": "Değer"
}
]

entityType: string | null
Koleksiyon satırı ile ilişkili varlık türü.
örnek: "product", "order", "vs."

entityId: number | null
Koleksiyon satırı ile ilişkili varlık tanımlayıcısı.
örnek: 12345

attributeSetIdentifier: string | null
Koleksiyon satırına ekli form tarafından kullanılan nitelik setinin tanımlayıcısı veya geçerli değilse null.
örnek: "attributeSet1" veya null

total: string
Toplam sayısı.
örnek: "1"