| POST | /api/riskstore/eventset/ingest | Ingest EventSet Request | Ingest EventSet Request |
|---|
import Foundation
import ServiceStack
public class IngestEventSetRequest : IPost, Codable
{
public var eventSet:EventSet
required public init(){}
}
public class EventSet : Codable
{
public var eventSetId:Int
public var processingStatus:ProcessingStatus
public var sourceModelSystem:String
public var sourceEventSetId:String
public var modelId:String
public var perspectiveId:Int
public var simulationCount:Int
public var programCalculationId:String
public var Description:String
public var limit:Double
public var reinstatements:Int
public var eventSourceType:String
public var eventSetOriginId:String
public var eventSetOriginName:String
public var eventSetOriginType:String
public var sourceEventSetLossContainer:String
public var sourceEventSetLossPath:String
public var resolution:String
public var resultsHash:String
public var expectedLossAggregate:Double
public var expectedLossOccurrence:Double
public var probabilityOfAttachment:Double
public var probabilityOfExhaustion:Double
public var approvedDateTimeUtc:Date
public var approvedBy:String
public var eventSourceId:Int
public var validFromUtc:Date
public var validToUtc:Date
public var container:String
public var blobName:String
public var updatedDateUtc:Date
public var isArchived:Bool
public var archivedLossDataBlobPath:String
public var archivedLossDataHash:String
public var eventSetTelemetry:EventSetTelemetry
required public init(){}
}
public enum ProcessingStatus : Int, Codable
{
case New = 0
case Processing = 1
case Failed = 10
case Successful = 20
}
public class EventSetTelemetry : Codable
{
public var eventSetId:Int
public var startedDateTimeUtc:Date?
public var endedDateTimeUct:Date?
public var eventLossCount:Int
required public init(){}
}
Swift IngestEventSetRequest DTOs
To override the Content-type in your clients, use the HTTP Accept Header, append the .xml suffix or ?format=xml
The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.
POST /api/riskstore/eventset/ingest HTTP/1.1
Host: riskstoreng-dev.nephila.com
Accept: application/xml
Content-Type: application/xml
Content-Length: length
<IngestEventSetRequest xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/Nephila.RiskStore.ServiceModel.Requests">
<EventSet xmlns:d2p1="http://schemas.datacontract.org/2004/07/Nephila.RiskStore.ServiceModel.Types">
<d2p1:ApprovedBy>String</d2p1:ApprovedBy>
<d2p1:ApprovedDateTimeUtc>0001-01-01T00:00:00</d2p1:ApprovedDateTimeUtc>
<d2p1:ArchivedLossDataBlobPath>String</d2p1:ArchivedLossDataBlobPath>
<d2p1:ArchivedLossDataHash>String</d2p1:ArchivedLossDataHash>
<d2p1:BlobName>String</d2p1:BlobName>
<d2p1:Container>String</d2p1:Container>
<d2p1:Description>String</d2p1:Description>
<d2p1:EventSetId>0</d2p1:EventSetId>
<d2p1:EventSetOriginId>String</d2p1:EventSetOriginId>
<d2p1:EventSetOriginName>String</d2p1:EventSetOriginName>
<d2p1:EventSetOriginType>String</d2p1:EventSetOriginType>
<d2p1:EventSetTelemetry>
<d2p1:EndedDateTimeUct>0001-01-01T00:00:00</d2p1:EndedDateTimeUct>
<d2p1:EventLossCount>0</d2p1:EventLossCount>
<d2p1:EventSetId>0</d2p1:EventSetId>
<d2p1:StartedDateTimeUtc>0001-01-01T00:00:00</d2p1:StartedDateTimeUtc>
</d2p1:EventSetTelemetry>
<d2p1:EventSourceId>0</d2p1:EventSourceId>
<d2p1:EventSourceType>String</d2p1:EventSourceType>
<d2p1:ExpectedLossAggregate>0</d2p1:ExpectedLossAggregate>
<d2p1:ExpectedLossOccurrence>0</d2p1:ExpectedLossOccurrence>
<d2p1:IsArchived>false</d2p1:IsArchived>
<d2p1:Limit>0</d2p1:Limit>
<d2p1:ModelId>String</d2p1:ModelId>
<d2p1:PerspectiveId>0</d2p1:PerspectiveId>
<d2p1:ProbabilityOfAttachment>0</d2p1:ProbabilityOfAttachment>
<d2p1:ProbabilityOfExhaustion>0</d2p1:ProbabilityOfExhaustion>
<d2p1:ProcessingStatus>New</d2p1:ProcessingStatus>
<d2p1:ProgramCalculationId>String</d2p1:ProgramCalculationId>
<d2p1:Reinstatements>0</d2p1:Reinstatements>
<d2p1:Resolution>String</d2p1:Resolution>
<d2p1:ResultsHash>String</d2p1:ResultsHash>
<d2p1:SimulationCount>0</d2p1:SimulationCount>
<d2p1:SourceEventSetId>String</d2p1:SourceEventSetId>
<d2p1:SourceEventSetLossContainer>String</d2p1:SourceEventSetLossContainer>
<d2p1:SourceEventSetLossPath>String</d2p1:SourceEventSetLossPath>
<d2p1:SourceModelSystem>String</d2p1:SourceModelSystem>
<d2p1:UpdatedDateUtc>0001-01-01T00:00:00</d2p1:UpdatedDateUtc>
<d2p1:ValidFromUtc>0001-01-01T00:00:00</d2p1:ValidFromUtc>
<d2p1:ValidToUtc>0001-01-01T00:00:00</d2p1:ValidToUtc>
</EventSet>
</IngestEventSetRequest>