Hi,
i would like to create a Sales Channel over the API of Shopware 6.
For that i send the following POST request to the /api/sales-channel Endpoint:
{
"typeId": "8a243080f92e4c719546314b577cf82b",
"languageId": "2fbb5fe2e29a4d70aa5854ce7ce3e20b",
"customerGroupId": "cfbd5018d38d41d8adca10d94fc8bdd6",
"currencyId": "b7d2554b0ce847cd82f3ac9bd1c0dfca",
"paymentMethodId": "79e557a3fe4646e9a0f9ceb45b2f5a7e",
"countryId": "5dbe147703354d8692101a7cd4a2a6c8",
"homeEnabled": true,
"name": "Test Storefront",
"shippingMethodId": "38456c729c3c4718abe2f7ab998b2527",
"navigationCategoryId": "912c1bee85e547df9b5ade07aba0daa4",
"accessKey": "******************************",
"languages": [{"localeId": "3f9a85a234dd40c5b201afe4eb1e388d", "name": "English"}],
"hreflangActive": false
}
If I send this request i get the following Error Message:
{
"errors": [
{
"code": "SYSTEM__NO_GIVEN_DEFAULT_LANGUAGE_ID",
"status": "400",
"detail": "The sales channel with id \"bc284a7fceb949bca92756aaa962da1b\" does not have a default sales channel language id in the language list.",
"template": "The sales channel with id \"{{ salesChannelId }}\" does not have a default sales channel language id in the language list.",
"meta": {
"parameters": {
"{{ salesChannelId }}": "bc284a7fceb949bca92756aaa962da1b"
}
},
"source": {
"pointer": "/"
}
}
]
}
Can somebody please help and tell me how to fix this problem?
Thank you!