PUT v1/Media/{mediaKey}
Update a Media record.
Roles Allowed
admin, editor
Request Information
URI Parameters
Name | Description | Type | Additional information |
---|---|---|---|
mediaKey | integer |
Required |
Body Parameters
MediaUpdateName | Description | Type | Additional information |
---|---|---|---|
MediaTypeId |
The MediaType must be a valid ElementType. To get a list of valid element types, see /Article/ElementTypes. |
integer |
None. |
Credit | string |
None. |
|
Caption | string |
None. |
|
TextDescription | string |
None. |
|
Notes | string |
None. |
|
IsReviewed | boolean |
None. |
Request Formats
application/json, text/json
Sample:
{ "MediaTypeId": 1, "Credit": "sample string 2", "Caption": "sample string 3", "TextDescription": "sample string 4", "Notes": "sample string 5", "IsReviewed": true }
application/xml, text/xml
Sample:
<MediaUpdate xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/Bondi.Models.V3.ApiDto"> <Caption>sample string 3</Caption> <Credit>sample string 2</Credit> <IsReviewed>true</IsReviewed> <Notes>sample string 5</Notes> <TextDescription>sample string 4</TextDescription> <MediaTypeId>1</MediaTypeId> </MediaUpdate>
application/x-www-form-urlencoded
Sample:
Sample not available.
Response Information
Resource Description
HTTP 200 with Updated Media if found, HTTP 404 otherwise, HTTP 409 if validation fails
MediaForArticleName | Description | Type | Additional information |
---|---|---|---|
MediaKey |
A unique identifier for the Media |
integer |
None. |
MediaFile |
The filename for this Media in BLOB storage |
string |
None. |
Updated |
The last time this media was updated |
date |
None. |
UpdatedBy |
The last user who updated the media |
string |
None. |
ElementType |
The ElementType that is assigned to the Media |
ElementType |
None. |
MediaReferences |
A collection of specific places on specific pages where this media appears |
Collection of MediaReference |
None. |
Credit | string |
None. |
|
Caption | string |
None. |
|
TextDescription | string |
None. |
|
Notes | string |
None. |
|
IsReviewed | boolean |
None. |
Response Formats
application/json, text/json
Sample:
{ "MediaKey": 1, "MediaFile": "sample string 2", "Updated": "2024-11-03T02:46:03.0510301+00:00", "UpdatedBy": "sample string 4", "ElementType": { "ElementTypeId": 1, "ElementTypeValue": "sample string 2" }, "MediaReferences": [ { "MediaReferenceKey": 1.0, "PageLocation": { "PageLocationKey": 1, "PageKey": 2, "ULX": 3, "ULY": 4, "LRX": 5, "LRY": 6, "Width": 7, "Height": 8 }, "PageRef": "sample string 2", "RefId": "sample string 3", "RefOrder": 4 }, { "MediaReferenceKey": 1.0, "PageLocation": { "PageLocationKey": 1, "PageKey": 2, "ULX": 3, "ULY": 4, "LRX": 5, "LRY": 6, "Width": 7, "Height": 8 }, "PageRef": "sample string 2", "RefId": "sample string 3", "RefOrder": 4 } ], "Credit": "sample string 5", "Caption": "sample string 6", "TextDescription": "sample string 7", "Notes": "sample string 8", "IsReviewed": true }
application/xml, text/xml
Sample:
<MediaForArticle xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/Bondi.Models.V3.ApiDto"> <Caption>sample string 6</Caption> <Credit>sample string 5</Credit> <IsReviewed>true</IsReviewed> <Notes>sample string 8</Notes> <TextDescription>sample string 7</TextDescription> <ElementType> <ElementTypeId>1</ElementTypeId> <ElementTypeValue>sample string 2</ElementTypeValue> </ElementType> <MediaFile>sample string 2</MediaFile> <MediaKey>1</MediaKey> <MediaReferences> <MediaReference> <MediaReferenceKey>1</MediaReferenceKey> <PageLocation> <Height>8</Height> <LRX>5</LRX> <LRY>6</LRY> <PageKey>2</PageKey> <PageLocationKey>1</PageLocationKey> <ULX>3</ULX> <ULY>4</ULY> <Width>7</Width> </PageLocation> <PageRef>sample string 2</PageRef> <RefId>sample string 3</RefId> <RefOrder>4</RefOrder> </MediaReference> <MediaReference> <MediaReferenceKey>1</MediaReferenceKey> <PageLocation> <Height>8</Height> <LRX>5</LRX> <LRY>6</LRY> <PageKey>2</PageKey> <PageLocationKey>1</PageLocationKey> <ULX>3</ULX> <ULY>4</ULY> <Width>7</Width> </PageLocation> <PageRef>sample string 2</PageRef> <RefId>sample string 3</RefId> <RefOrder>4</RefOrder> </MediaReference> </MediaReferences> <Updated>2024-11-03T02:46:03.0510301+00:00</Updated> <UpdatedBy>sample string 4</UpdatedBy> </MediaForArticle>