| Requires the role: | TenantReader |
| GET | /api/patching/updates/{Id} | Returns a single update by its id | |
|---|---|---|---|
| GET | /patching/updates/{Id} | Returns a single update by its id |
Imports System
Imports System.IO
Imports System.Collections
Imports System.Collections.Generic
Imports System.Runtime.Serialization
Imports ServiceStack
Imports ServiceStack.DataAnnotations
Imports CoreService.ServiceModel.Dtos.Patching.Crud
Imports CoreService.ServiceModel.Dtos.Patching.Responses
Namespace Global
Namespace CoreService.ServiceModel.Dtos.Patching.Crud
'''<Summary>
'''Returns a single update by its id
'''</Summary>
<Api(Description:="Returns a single update by its id")>
<ApiResponse(Description:="Success", IsDefaultResponse:=true, ResponseType:=GetType(UpdateDto), StatusCode:=200)>
Public Partial Class GetUpdate
Implements IBaseRequest
Implements IHasId
Implements IHasTenantName
Implements IGet
'''<Summary>
'''The primary key of every config item
'''</Summary>
<ApiMember(DataType:="string", Description:="The primary key of every config item", Format:="guid", IsRequired:=true, ParameterType:="path")>
Public Overridable Property Id As Guid Implements IHasId.Id
<ApiMember(DataType:="string", IsRequired:=true, ParameterType:="header")>
<Validate(Validator:="NotEmpty")>
Public Overridable Property TenantName As String Implements IHasTenantName.TenantName
End Class
End Namespace
Namespace CoreService.ServiceModel.Dtos.Patching.Responses
Public Partial Class UpdateDto
Public Overridable Property Id As Guid
Public Overridable Property Name As String
'''<Summary>
'''The severity of the vulnerability this update fixes (e.g. Critical, Important, Moderate, etc.)
'''</Summary>
Public Overridable Property Severity As String
'''<Summary>
'''The time the update was first published
'''</Summary>
Public Overridable Property Published As Date
'''<Summary>
'''Update classification/type (e.g. Critical Update, Definition Update, Security Update, etc.)
'''</Summary>
Public Overridable Property Classifications As List(Of String)
'''<Summary>
'''Whether the update needs a reboot or not
'''</Summary>
Public Overridable Property IsRebootRequired As Boolean
'''<Summary>
'''In case of windows this is the KB id
'''</Summary>
Public Overridable Property ExtId As String
'''<Summary>
'''In case of linux this is the update package version
'''</Summary>
Public Overridable Property Version As String
End Class
End Namespace
End Namespace
To override the Content-type in your clients, use the HTTP Accept Header, append the .json suffix or ?format=json
To embed the response in a jsonp callback, append ?callback=myCallback
The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.
GET /api/patching/updates/{Id} HTTP/1.1
Host: core.starburst.svc
Accept: application/json
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: length
{"id":"00000000-0000-0000-0000-000000000000","name":"String","severity":"String","published":"0001-01-01T00:00:00.0000000Z","classifications":["String"],"isRebootRequired":false,"extId":"String","version":"String"}