# Shopware 6 API Call

**URL:** <https://forum.synesty.com/t/shopware-6-api-call/2873>\
**Category:** Fragen und Antworten\
**Created:** [1. Juni 2022 um 07:11 UTC](https://forum.synesty.com/t/shopware-6-api-call/2873 "2022-06-01T07:11:02Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![ramin-ww](https://forum.synesty.com/letter_avatar_proxy/v4/letter/r/91b2a8/32.png) [@ramin-ww](https://forum.synesty.com/u/ramin-ww)\
**Post date:** [1. Juni 2022 um 07:11 UTC](https://forum.synesty.com/t/shopware-6-api-call/2873/1 "2022-06-01T07:11:02Z")

</div>

Hallo Zusammen,

ich versuche, unabhängig von den Shopware Steps, einen simplen API Call gegen eine Shopware 6 Umgebung abzusetzen. Speziell geht es um einen GET Call, um die product-manufacturer zurückzubekommen, die dann in einen Spreadsheet geschrieben werden sollen.

Es scheitert aber schon am Step API Call den ich vorher aus einer Postman Collection importiert habe. Als Fehler bekomme ich 415 Unsupported Media Type zurück.

Viele Grüße  
Ramin

---

<div class="post-metadata">

**Author:** ![synesty-Lukas](https://forum.synesty.com/user_avatar/forum.synesty.com/synesty-lukas/32/114_2.png) [@synesty-Lukas](https://forum.synesty.com/u/synesty-Lukas)\
**Post date:** [1. Juni 2022 um 12:43 UTC](https://forum.synesty.com/t/shopware-6-api-call/2873/2 "2022-06-01T12:43:03Z")

</div>

Hallo @ramin-ww,

du kannst mal gern die REST-Route hier posten die du verwendest und auch den Request Body, falls einen gibt.

Viele Grüße  
Lukas

---

<div class="post-metadata">

**Author:** ![ramin-ww](https://forum.synesty.com/letter_avatar_proxy/v4/letter/r/91b2a8/32.png) [@ramin-ww](https://forum.synesty.com/u/ramin-ww)\
**Post date:** [1. Juni 2022 um 14:20 UTC](https://forum.synesty.com/t/shopware-6-api-call/2873/3 "2022-06-01T14:20:48Z")

</div>

REST-Route ist /api/product-manufacturer/ und body ist leer

Das hier ist der API Call

```auto
{
  "executorflowuniqename" : "",
  "description" : "",
  "name" : "APICall",
  "rank" : 10,
  "active" : true,
  "permaId" : 2,
  "stepprovider" : "APICall@com.asolida.delivor.plugin.steps.httpurldownloadimpl",
  "stepproviderversion" : "1.0",
  "stepProperty" : [ {
    "value" : "Shopware-STAGE",
    "key" : "account",
    "type" : "IN",
    "datatype" : "ACCOUNT",
    "contextkey" : null
  }, {
    "value" : "",
    "key" : "bodyContentType",
    "type" : "IN",
    "datatype" : "STRING",
    "contextkey" : null
  }, {
    "value" : "10",
    "key" : "callLimit",
    "type" : "IN",
    "datatype" : "STRING",
    "contextkey" : null
  }, {
    "value" : "",
    "key" : "errorStatusCodes",
    "type" : "IN",
    "datatype" : "STRING",
    "contextkey" : null
  }, {
    "value" : "",
    "key" : "fileParameterName",
    "type" : "IN",
    "datatype" : "STRING",
    "contextkey" : null
  }, {
    "value" : "",
    "key" : "fileToUpload",
    "type" : "IN",
    "datatype" : "FILE",
    "contextkey" : null
  }, {
    "value" : "",
    "key" : "headerContentType",
    "type" : "IN",
    "datatype" : "STRING",
    "contextkey" : null
  }, {
    "value" : "/api/product-manufacturer/",
    "key" : "host",
    "type" : "IN",
    "datatype" : "STRING",
    "contextkey" : null
  }, {
    "value" : "GET",
    "key" : "method",
    "type" : "IN",
    "datatype" : "STRING",
    "contextkey" : null
  }, {
    "value" : "",
    "key" : "parsingTemplate",
    "type" : "IN",
    "datatype" : "STRING",
    "contextkey" : null
  }, {
    "value" : "",
    "key" : "password",
    "type" : "IN",
    "datatype" : "STRING",
    "contextkey" : null
  }, {
    "value" : "",
    "key" : "rateLimitPerSecond",
    "type" : "IN",
    "datatype" : "STRING",
    "contextkey" : null
  }, {
    "value" : "",
    "key" : "requestBody",
    "type" : "IN",
    "datatype" : "STRING",
    "contextkey" : null
  }, {
    "value" : "Content-Type=application/json\r\nAuthorization=Bearer <#list output@APICall_3.getRows() as row>${row.get(\"access_token\")!}</#list>",
    "key" : "requestHeaders",
    "type" : "IN",
    "datatype" : "STRING",
    "contextkey" : null
  }, {
    "value" : "json",
    "key" : "responseFormat",
    "type" : "IN",
    "datatype" : "STRING",
    "contextkey" : null
  }, {
    "value" : "UTF-8",
    "key" : "sourcefileCharset",
    "type" : "IN",
    "datatype" : "STRING",
    "contextkey" : null
  }, {
    "value" : "false",
    "key" : "sslCertificates",
    "type" : "IN",
    "datatype" : "STRING",
    "contextkey" : null
  }, {
    "value" : "60",
    "key" : "timeoutInSeconds",
    "type" : "IN",
    "datatype" : "STRING",
    "contextkey" : null
  }, {
    "value" : "",
    "key" : "username",
    "type" : "IN",
    "datatype" : "STRING",
    "contextkey" : null
  } ],
  "steptype" : "DEFAULT",
  "uiColor" : null
}

```

---

<div class="post-metadata">

**Author:** ![synesty-Torsten](https://forum.synesty.com/user_avatar/forum.synesty.com/synesty-torsten/32/114_2.png) [@synesty-Torsten](https://forum.synesty.com/u/synesty-Torsten)\
**Post date:** [2. Juni 2022 um 09:20 UTC](https://forum.synesty.com/t/shopware-6-api-call/2873/4 "2022-06-02T09:20:26Z")

</div>

Hallo Ramin,

ich glaube dieser Fehler kommt bei Shopware 6, wenn der Request Header „Accept“ nicht gesetzt ist. Kannst du bitte mal probieren im Feld `requestHeaders` des APICall Steps noch ein

`Accept=application/json` oder `Accept=application/vnd.api+json`

hinzuzufügen (je nachdem in welchem Format du die Response erhalten willst, siehe [Request & Response Structure | Admin API](https://shopware.stoplight.io/docs/admin-api/ZG9jOjEyMzAzNDU1-request-and-response-structure#response-format))

 ![image](https://forum.synesty.com/uploads/default/original/2X/3/36adf41252eb702e480ea6cd41f085bc2134c375.png)

![image](https://forum.synesty.com/uploads/default/original/2X/1/1df7e8869c97b802d90866d6573b54ec3096ab61.png)

Viele Grüße  
Torsten

---

<div class="post-metadata">

**Author:** ![ramin-ww](https://forum.synesty.com/letter_avatar_proxy/v4/letter/r/91b2a8/32.png) [@ramin-ww](https://forum.synesty.com/u/ramin-ww)\
**Post date:** [2. Juni 2022 um 09:36 UTC](https://forum.synesty.com/t/shopware-6-api-call/2873/5 "2022-06-02T09:36:22Z")

</div>

> [@synesty-Torsten](#):
>
> Accept=application/json

Hallo Torsten,

Tatsache, funktioniert. Danke!!

Viele Grüße  
Ramin
