# Saleforce return API ### Goal To provide Saleforce with an asynchronous API that modifies the order status to be re-sent in the next loop with an explanation of the error. ### Endpoint `https://europe-west3-majblomman-shop.cloudfunctions.net/api/salesforceresponse` ### Method `POST` ### Content-type `application/json` ### Authorization `Bearer <TOKEN>` ### Data Data is posted as an array in raw JSON, f.ex: ``` [{ "orderNumber": "TEST", "errors": "Test error" }, { "orderNumber": "TEST2", "errors": "Test2 error" }] ``` ### Responses - `200` OK - `400` Validation error, see response for details - `401` Invalid token ### Example cURL ```curl --location --request POST 'https://europe-west3-majblomman-shop.cloudfunctions.net/api/salesforceresponse' \ --header 'Authorization: Bearer <TOKEN>' \ --header 'Content-Type: application/json' \ --data-raw '[{ "orderNumber": "Q72PX5220209", "errors": "Test error" }]' ```