Skip to content

Latest commit

 

History

History
72 lines (52 loc) · 2.23 KB

dynamics_item_get_picture.md

File metadata and controls

72 lines (52 loc) · 2.23 KB
title description author ms.topic ms.devlang ms.date ms.author ms.reviewer
Get item picture
Gets an item picture in Dynamics 365 Business Central.
SusanneWindfeldPedersen
reference
al
05/31/2024
solsen
solsen

Get item picture

[!INCLUDEapi_v2_note]

Gets the picture of the item in [!INCLUDEprod_short].

HTTP request

Replace the URL prefix for [!INCLUDEprod_short] depending on environment following the guideline. The following example gets the default dimensions of the item entity in the response body.

GET businesscentralPrefix/companies({companyId})/items({itemId})/picture

Request header

Header Value
Authorization Bearer {token}. Required.

Request body

Do not supply a request body for this method.

Response

If successful, this method returns a 200 OK response code and the picture in the response body.

Example

Request

GET https://{businesscentralPrefix}/api/v2.0/companies({companyId})/items({itemId})/picture

Response
Here is an example of the response.

Note

The response object shown here may be truncated for brevity. All of the properties will be returned from an actual call.

{
  "id": "d0e5d5da-795a-4924-b376-13665f794cdd",
  "width": 500,
  "height": 496,
  "contentType": "image\jpeg",
  "content@odata.mediaEditLink": "https:\\api.businesscentral.dynamics-tie.com\v2.0\api\beta\companies(55c438d0-2f5c-44a0-9965-20b4923d0bef)\items(d0e5d5da-795a-4924-b376-13665f794cdd)\picture(d0e5d5da-795a-4924-b376-13665f794cdd)\content",
  "content@odata.mediaReadLink": "https:\\api.businesscentral.dynamics-tie.com\v2.0\api\beta\companies(55c438d0-2f5c-44a0-9965-20b4923d0bef)\items(d0e5d5da-795a-4924-b376-13665f794cdd)\picture(d0e5d5da-795a-4924-b376-13665f794cdd)\content"
}

See also

Tips for working with the APIs

Items
Create item picture
Update item picture
Delete item picture