Retrieving Updated Media's Metadata GET V2
The DynaMed/DynaMedex API GET /v2/content/media endpoint returns metadata for media published within a specified date range. The updatedAt timestamp is not necessarily related to editors updating the media with new information. It may represent the last time the media was reprocessed for delivery.
Basic Retrieving of Media Metadata
To Get Media Metadata (example):
Gather the following information for the request:
- An access token. Please see Using the Client Credentials Grant for further information.
- The publication type. The publication type can be an image, video or algorithm.
- The dates to retrieve (optional).
- The size and link type of the media.
- The nextPageToken if getting the next page of items. Please note that the nextPageToken changes in each response.
Request
GET https://apis.ebsco.com/medsapi-dynamed/v2/content/media?pubType=image&updatedSince=2022-09-14&updatedBefore=2023-05-09&imageSize=smallThe request above is for media that has been republished between September 14, 2022 and May 9, 2023.
Response
{
"_metadata": {
"nextPageToken": "eyJwdWJUeXBlIjp7IlMiOiJpbWFnZSJ9LCJ2ZXJzaW9uIjp7IlMiOiIxI2VuIn0sInVwZGF0ZWRBdCI6eyJTIjoiMTcyODAzMTIyNjkyMyJ9LCJhbiI6eyJTIjoiaTE1NjgxMzU5NjU0MjcifX0="
"totalItems": 1,
"links": [
{
"rel": "self",
"href": "https://apis.ebsco.com/medsapi-dynamed/v2/content/media?pubType=image&updatedSince=2022-09-14T18:21:54.345Z&updatedBefore=2023-05-09&imageSize=small"
},
{
"rel": "next",
"href": "https://apis.ebsco.com/medsapi-dynamed/v2/content/media?pubType=image&updatedSince=2022-09-14T18:21:54.345Z&updatedBefore=2023-05-09&imageSize=small"&nextPageToken=eyJwdWJUeXBlIjp7IlMiOiJpbWFnZSJ9LCJ2ZXJzaW9uIjp7IlMiOiIxI2VuIn0sInVwZGF0ZWRBdCI6eyJTIjoiMTcyODAzMTIyNjkyMyJ9LCJhbiI6eyJTIjoiaTE1NjgxMzU5NjU0MjcifX0=
},
]
},
"items": [
{
"id": "t232776",
"slug": "/drug-monograph/linezolid",
"createdAt": "2021-12-17T22:50:42.511Z",
"updatedAt": "2023-05-09T23:59:27.147Z",
"title": "Linezolid",
"description": "this topic provides overviews of mechanisms of action, spectrum of activity..."
"pubType": {
"id": "drug"
}
},
...
]
} Query Parameters
- page - The next page of items to return. Does not need to be specified on the first request.
- updatedSince - An ISO 8601 date. An example date is 2021-12-17T22:50:42.511Z or 2021-12-17 . Time does not need to be specified and will be assumed as midnight on the day requests. Articles starting at that date will be returned.
- updatedBefore - An ISO 8601 date. Time does not need to be specified and will be assumed as midnight on the day requests. Articles ending on that date will be returned.
The updatedAt parameter indicates the last time the page was published. If neither updatedSince nor updatedBefore are provided, all updates are returned. If no updatedBefore is supplied, then all dates from the updateSince until today's date are returned. If no updatedSince is provided, then all dates up to the updatedBefore are returned.
Paging
Up to 100 items may be returned in a request. To get the next page of items, include the pageToken. Each page has 100 items.
Access to Multimedia Assets
Article responses may include references to multimedia assets within the multimedia section of the response payload.
Each Multimedia Entry Can Include the Following Metadata
- Title – The name or caption associated with the media asset.
- Copyright – Copyright attribution information.
- Media URL – A link to the associated image or video asset.
Media URL Behavior
- The media URL provides access to a full-resolution image or video.
- The URL is temporary and valid for 24 hours from the time the article response is generated.
- Clients must not cache the URL.
Access and Refresh
- If access to the media asset is required after the 24-hour validity period, the client must re-request the article through the API to obtain a new media URL.
- No additional authentication is required to retrieve the media asset once the URL has been issued.
Specifying Image and Video Image Sizes
Links to images of varying sizes may be returned in the article response. To specify the image size, add one or more imageSize query parameters to the call. small (200w), medium (500w) and large (1000w) image sizes are supported. Also, the full image size is supported and is the default if no image size was specified. A still image of the video (aka thumbnail or poster) can also be returned with the video. To specify the size for the poster, add one or more posterSize parameters to the call. Small, medium, large and full sized images of the video will be returned. To distinguish the video and video link in the response, a type parameter is added and is set to "poster".
| Parameter Name | Description |
|---|---|
| secure | Set to true to return secure https URLs for media links. Default is true. |
| imageSize | Returns the requested size. |
| posterSize | Returns the requested size(s) for poster of the video links: small, medium, large or full. |
| convertSvg | Return images and algorithms that are originally in svg format as png format. |
Error Response Codes
The DynaMed retrieving media metadata endpoint can return one of the error response codes.
Updated about 15 hours ago
