Endpoint:
GET https://api.mailjet.com/v1/REST/images
Retrieve metadata for multiple images, including details such as image ID, status, name, and label IDs. This endpoint can be useful for retrieving the URLs of images you would like to use in your templates.
| Name | Type | Description |
|---|---|---|
ID | string | The ID of the image. |
IDs | array of strings | An array of image IDs. |
IsStarred | boolean | Indicates whether the image is marked as a favorite. |
Status | string | Accepted values: "open" or "locked". |
LabelIDs | array of integers | An array of IDs representing labels associated with the image or images. |
Name | string | The name of the image. |
PartialName | string |
curl --request GET \
--url https://api.mailjet.com/v1/rest/images \
--header 'Authorization: Bearer 612d5125131d406081abb9cd2afdc4e3'Status Code 200
| Name | Type | Description |
|---|---|---|
ID | string | The ID of the image. |
Name | string | The name of the image. |
Status | string | Indicates whether the image is open or locked. |
TargetContent | string | Indicates the purpose of the image. Possible values: image, background, video or social. |
ImageSize | integer | The size of the image file in bytes. |
LabelIDs | array of integers | An array of IDs representing labels associated with the image. |
IsStarred | boolean | Indicates whether the image is marked as a favorite. |
ImageURL | string | The URL where the image is stored. |
ThumbnailUrl | string | The URL where the thumbnail is stored. |
CreatedAt | DateTime UTC | The date and time when the image was created. |
UpdatedAt | DateTime UTC | The date and time when the image was last updated. |
ExpiresAt | DateTime UTC | The date and time when the image will expire. |
{
"Count": 2,
"Total": 2,
"Data": [
{
"ID": "07ea8ad6-161a-4bfe-9f38-3311c9e38984",
"OrganisationID": 2,
"Name": "My Image",
"Status": "open",
"TargetContent": "image",
"ImageSize": 425155,
"ThumbnailSize": 0,
"TotalSize": 425155,
"LabelIDs": [],
"IsStarred": false,
"ImageUrl": "https://0abcd.mjt.lu/img2/0abcd/07ea8ad6-161a-4bfe-9f38-3311c9e38984/content",
"ThumbnailUrl": null,
"CreatedAt": "2024-05-06T07:32:41.262245Z",
"UpdatedAt": "2024-05-06T07:32:41.262245Z",
"ExpiresAt": "2024-11-23T00:00:00Z"
},
{
"ID": "83732525-8a61-48b1-86ef-b54cac7aa897",
"OrganisationID": 2,
"Name": "My Other Image",
"Status": "open",
"TargetContent": "image",
"ImageSize": 425155,
"ThumbnailSize": 0,
"TotalSize": 425155,
"LabelIDs": [],
"IsStarred": false,
"ImageUrl": "https://0abcd.mjt.lu/img2/0abcd/83732525-8a61-48b1-86ef-b54cac7aa897/content",
"ThumbnailUrl": null,
"CreatedAt": "2024-04-16T14:29:54.182242Z",
"UpdatedAt": "2024-04-16T14:29:54.182242Z",
"ExpiresAt": "2024-11-03T00:00:00Z"
},
]
}