Utwórz powiązanie produktu z integracją
POST
/api/product-links/v2/product-links
const url = 'https://twoja-instancja-pim-api.enterprise.sellrocket.pl/api/product-links/v2/product-links';const options = { method: 'POST', headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'}, body: '{"productId":1,"externalProductId":"example","externalVariantId":"example","externalConnectionId":"example","connectionId":1}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://twoja-instancja-pim-api.enterprise.sellrocket.pl/api/product-links/v2/product-links \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --data '{ "productId": 1, "externalProductId": "example", "externalVariantId": "example", "externalConnectionId": "example", "connectionId": 1 }'Łączy produkt z katalogu z produktem lub ofertą w zewnętrznej integracji (np. sklepie, marketplace). Odpowiada powiązaniom produktów (links) w BaseLinker.
Autoryzacja
Dział zatytułowany „Autoryzacja”Treść żądania
Dział zatytułowany „Treść żądania”object
productId
integer format: int64
externalProductId
string
externalVariantId
string
externalConnectionId
string
connectionId
integer format: int64
Examplegenerated
{ "productId": 1, "externalProductId": "example", "externalVariantId": "example", "externalConnectionId": "example", "connectionId": 1}object
productId
integer format: int64
externalProductId
string
externalVariantId
string
externalConnectionId
string
connectionId
integer format: int64
Examplegenerated
{ "productId": 1, "externalProductId": "example", "externalVariantId": "example", "externalConnectionId": "example", "connectionId": 1}object
productId
integer format: int64
externalProductId
string
externalVariantId
string
externalConnectionId
string
connectionId
integer format: int64
Examplegenerated
{ "productId": 1, "externalProductId": "example", "externalVariantId": "example", "externalConnectionId": "example", "connectionId": 1}Odpowiedzi
Dział zatytułowany „Odpowiedzi”Created
object
id
integer format: int64
productId
integer format: int64
externalProductId
string
externalVariantId
string
externalConnectionId
string
connectionId
integer format: int64
object
id
integer format: int64
productId
integer format: int64
externalProductId
string
externalVariantId
string
externalConnectionId
string
connectionId
integer format: int64
Examplegenerated
{ "id": 1, "productId": 1, "externalProductId": "example", "externalVariantId": "example", "externalConnectionId": "example", "connectionId": 1}object
id
integer format: int64
productId
integer format: int64
externalProductId
string
externalVariantId
string
externalConnectionId
string
connectionId
integer format: int64
Examplegenerated
{ "id": 1, "productId": 1, "externalProductId": "example", "externalVariantId": "example", "externalConnectionId": "example", "connectionId": 1}Client Error
object
message
string
object
message
string
Examplegenerated
{ "message": "example"}object
message
string
Examplegenerated
{ "message": "example"}Server Error

