@abdullah, den Body der Request siehst du oben.
Der Header sieht wie folgt aus:
Authorization: Bearer Platzhaltertoken
Accept: application/json
Content-Type: application/json
User-Agent: Testing1
Folgendes wird nun als Fehler angezeigt:
{
"errors": [
{
"code": "0",
"status": "500",
"title": "Internal Server Error",
"detail": "Shopware\\Core\\Framework\\DataAbstractionLayer\\Write\\DataStack\\KeyValuePair::__construct(): Argument #1 ($key) must be of type string, int given, called in /xxxxxx/vendor/shopware/core/Framework/DataAbstractionLayer/Write/DataStack/DataStack.php on line 47",
"meta": {
"trace": [
{
"file": "/xxxxxxx/vendor/shopware/core/Framework/DataAbstractionLayer/Write/DataStack/DataStack.php",
"line": 47,
"function": "__construct",
"class": "Shopware\\Core\\Framework\\DataAbstractionLayer\\Write\\DataStack\\KeyValuePair",
"type": "->"
},
{
"file": "/xxxxxxxx/vendor/shopware/core/Framework/DataAbstractionLayer/Write/WriteCommandExtractor.php",
"line": 303,
"function": "__construct",
"class": "Shopware\\Core\\Framework\\DataAbstractionLayer\\Write\\DataStack\\DataStack",
"type": "->"
},
{
"file": "/xxxxxxxx/vendor/shopware/core/Framework/DataAbstractionLayer/Write/WriteCommandExtractor.php",
"line": 209,
"function": "map",
"class": "Shopware\\Core\\Framework\\DataAbstractionLayer\\Write\\WriteCommandExtractor",
"type": "->"
},
{
"file": "/xxxxxxxxx/vendor/shopware/core/Framework/DataAbstractionLayer/FieldSerializer/ManyToOneAssociationFieldSerializer.php",
"line": 115,
"function": "extract",
"class": "Shopware\\Core\\Framework\\DataAbstractionLayer\\Write\\WriteCommandExtractor",
"type": "->"
},
{
"file": "/xxxxxxxx/vendor/shopware/core/Framework/DataAbstractionLayer/Write/WriteCommandExtractor.php",
"line": 318,
"function": "encode",
"class": "Shopware\\Core\\Framework\\DataAbstractionLayer\\FieldSerializer\\ManyToOneAssociationFieldSerializer",
"type": "->"
},
{
"file": "/xxxxxxxx/vendor/shopware/core/Framework/DataAbstractionLayer/Write/WriteCommandExtractor.php",
"line": 209,
"function": "map",
"class": "Shopware\\Core\\Framework\\DataAbstractionLayer\\Write\\WriteCommandExtractor",
"type": "->"
},
{
"file": "/xxxxxxxxx/vendor/shopware/core/Framework/DataAbstractionLayer/Write/EntityWriter.php",
"line": 195,
"function": "extract",
"class": "Shopware\\Core\\Framework\\DataAbstractionLayer\\Write\\WriteCommandExtractor",
"type": "->"
},
{
"file": "/xxxxxxxxx/vendor/shopware/core/Framework/DataAbstractionLayer/Write/EntityWriter.php",
"line": 140,
"function": "write",
"class": "Shopware\\Core\\Framework\\DataAbstractionLayer\\Write\\EntityWriter",
"type": "->"
},
{
"file": "/xxxxxxxxxx/vendor/shopware/core/Framework/DataAbstractionLayer/VersionManager.php",
"line": 118,
"function": "insert",
"class": "Shopware\\Core\\Framework\\DataAbstractionLayer\\Write\\EntityWriter",
"type": "->"
},
{
"file": "/xxxxxxxxxx/vendor/shopware/core/Framework/DataAbstractionLayer/EntityRepository.php",
"line": 154,
"function": "insert",
"class": "Shopware\\Core\\Framework\\DataAbstractionLayer\\VersionManager",
"type": "->"
},
{
"file": "/xxxxxxxxxx/vendor/shopware/core/Framework/Api/Controller/ApiController.php",
"line": 916,
"function": "create",
"class": "Shopware\\Core\\Framework\\DataAbstractionLayer\\EntityRepository",
"type": "->"
},
{
"file": "/xxxxxxxxxxxx/vendor/shopware/core/Framework/Context.php",
"line": 207,
"function": "Shopware\\Core\\Framework\\Api\\Controller\\{closure}",
"class": "Shopware\\Core\\Framework\\Api\\Controller\\ApiController",
"type": "->"
},
{
"file": "/vxxxxxxxxxxx/vendor/shopware/core/Framework/Api/Controller/ApiController.php",
"line": 934,
"function": "scope",
"class": "Shopware\\Core\\Framework\\Context",
"type": "->"
},
{
"file": "/xxxxxxx/vendor/shopware/core/Framework/Api/Controller/ApiController.php",
"line": 778,
"function": "executeWriteOperation",
"class": "Shopware\\Core\\Framework\\Api\\Controller\\ApiController",
"type": "->"
},
{
"file": "/xxxxxxx/vendor/shopware/core/Framework/Api/Controller/ApiController.php",
"line": 454,
"function": "write",
"class": "Shopware\\Core\\Framework\\Api\\Controller\\ApiController",
"type": "->"
},
{
"file": "/xxxxxx/vendor/symfony/http-kernel/HttpKernel.php",
"line": 152,
"function": "create",
"class": "Shopware\\Core\\Framework\\Api\\Controller\\ApiController",
"type": "->"
},
{
"file": "/xxxx/vendor/symfony/http-kernel/HttpKernel.php",
"line": 74,
"function": "handleRaw",
"class": "Symfony\\Component\\HttpKernel\\HttpKernel",
"type": "->"
},
{
"file": "/xxxx/vendor/symfony/http-kernel/Kernel.php",
"line": 202,
"function": "handle",
"class": "Symfony\\Component\\HttpKernel\\HttpKernel",
"type": "->"
},
{
"file": "/xxxx/vendor/symfony/http-kernel/HttpCache/SubRequestHandler.php",
"line": 86,
"function": "handle",
"class": "Symfony\\Component\\HttpKernel\\Kernel",
"type": "->"
},
{
"file": "/xxx/vendor/symfony/http-kernel/HttpCache/HttpCache.php",
"line": 479,
"function": "handle",
"class": "Symfony\\Component\\HttpKernel\\HttpCache\\SubRequestHandler",
"type": "::"
},
{
"file": "/xxxxxx/vendor/symfony/http-kernel/HttpCache/HttpCache.php",
"line": 269,
"function": "forward",
"class": "Symfony\\Component\\HttpKernel\\HttpCache\\HttpCache",
"type": "->"
},
{
"file": "/xxxxxxx/vendor/symfony/http-kernel/HttpCache/HttpCache.php",
"line": 285,
"function": "pass",
"class": "Symfony\\Component\\HttpKernel\\HttpCache\\HttpCache",
"type": "->"
},
{
"file": "/xxxxxxx/vendor/symfony/http-kernel/HttpCache/HttpCache.php",
"line": 213,
"function": "invalidate",
"class": "Symfony\\Component\\HttpKernel\\HttpCache\\HttpCache",
"type": "->"
},
{
"file": "/xxxxxx/vendor/shopware/core/HttpKernel.php",
"line": 153,
"function": "handle",
"class": "Symfony\\Component\\HttpKernel\\HttpCache\\HttpCache",
"type": "->"
},
{
"file": "/xxxxxx/vendor/shopware/core/HttpKernel.php",
"line": 79,
"function": "doHandle",
"class": "Shopware\\Core\\HttpKernel",
"type": "->"
},
{
"file": "/xxxxx/public/index.php",
"line": 74,
"function": "handle",
"class": "Shopware\\Core\\HttpKernel",
"type": "->"
}
],
"file": "xxx/vendor/shopware/core/Framework/DataAbstractionLayer/Write/DataStack/KeyValuePair.php",
"line": 22
}
}
]
}
Cache habe ich geleert beim umstellen auf dev.
Danke!