Class ByIdMediaApiController
Namespace: Umbraco.Cms.Api.Delivery.Controllers
Assembly: Umbraco.Cms.Api.Delivery.dll
Syntax
public class ByIdMediaApiController : MediaApiControllerBase
Constructors
View SourceByIdMediaApiController(IPublishedSnapshotAccessor, IApiMediaWithCropsResponseBuilder)
Declaration
public ByIdMediaApiController(IPublishedSnapshotAccessor publishedSnapshotAccessor, IApiMediaWithCropsResponseBuilder apiMediaWithCropsResponseBuilder)
Parameters
Type | Name | Description |
---|---|---|
IPublishedSnapshotAccessor | publishedSnapshotAccessor | |
IApiMediaWithCropsResponseBuilder | apiMediaWithCropsResponseBuilder |
Methods
View SourceById(Guid)
Gets a media item by id.
Declaration
public async Task<IActionResult> ById(Guid id)
Parameters
Type | Name | Description |
---|---|---|
Guid | id | The unique identifier of the media item. |
Returns
Type | Description |
---|---|
Task<IActionResult> | The media item or not found result. |