CardsController.PostGetFileContent - метод
Загружает содержимое файла с указанными параметрами в виде потока файла
FileStreamResult.
Предпочитаемое имя файла возвращается как заголовок
Content-Disposition в
Response.
Результат запроса API карточек
CardGetFileContentResponse не возвращается, но про наличии
ошибок будет возвращён
PlainValidationResult, сериализованный как typed json,
с кодом ошибки
BadRequest.
Пространство имён: Tessa.Web.ControllersСборка: Tessa.Web (в Tessa.Web.dll) Версия: 3.6.0.23
[HttpPostAttribute("get-file-content")]
[SessionMethodAttribute(UserAccessLevel.Regular)]
[TypedJsonBodyAttribute]
[ConsumesAttribute("application/json", new string[] { ... })]
[ProducesAttribute("application/octet-stream", new string[] { ... })]
[ProducesResponseTypeAttribute(200)]
public Task<IActionResult> PostGetFileContent(
[FromBodyAttribute] CardGetFileContentRequest request,
CancellationToken cancellationToken = default
)
<HttpPostAttribute("get-file-content")>
<SessionMethodAttribute(UserAccessLevel.Regular)>
<TypedJsonBodyAttribute>
<ConsumesAttribute("application/json", New String() { ... })>
<ProducesAttribute("application/octet-stream", New String() { ... })>
<ProducesResponseTypeAttribute(200)>
Public Function PostGetFileContent (
<FromBodyAttribute> request As CardGetFileContentRequest,
Optional cancellationToken As CancellationToken = Nothing
) As Task(Of IActionResult)
public:
[HttpPostAttribute(L"get-file-content")]
[SessionMethodAttribute(UserAccessLevel::Regular)]
[TypedJsonBodyAttribute]
[ConsumesAttribute(L"application/json", __gc new array<String^>^ { ... })]
[ProducesAttribute(L"application/octet-stream", __gc new array<String^>^ { ... })]
[ProducesResponseTypeAttribute(200)]
Task<IActionResult^>^ PostGetFileContent(
[FromBodyAttribute] CardGetFileContentRequest^ request,
CancellationToken cancellationToken = CancellationToken()
)
[<HttpPostAttribute("get-file-content")>]
[<SessionMethodAttribute(UserAccessLevel.Regular)>]
[<TypedJsonBodyAttribute>]
[<ConsumesAttribute("application/json", new string[] { ... })>]
[<ProducesAttribute("application/octet-stream", new string[] { ... })>]
[<ProducesResponseTypeAttribute(200)>]
member PostGetFileContent :
[<FromBodyAttribute>] request : CardGetFileContentRequest *
?cancellationToken : CancellationToken
-> Task<IActionResult>
- request CardGetFileContentRequest
- Запрос на загрузку содержимого файла.
- cancellationToken CancellationToken (Optional)
- Объект, посредством которого можно отменить асинхронную задачу.
Task<IActionResult>
Поток файла
FileStreamResult или результат валидации
PlainValidationResult в случае ошибки
с кодом возврата
BadRequest.