PUT | /members/{EmployeeGuid}/investmentprofile/risk |
---|
Imports System
Imports System.Collections
Imports System.Collections.Generic
Imports System.Runtime.Serialization
Imports ServiceStack
Imports ServiceStack.DataAnnotations
Imports AlbaApi.ServiceModel
Imports AlbaApi.Model
Imports TasSyd.Model.Core
Namespace Global
Namespace AlbaApi.Model
Public Partial Class InvestmentRiskProfileResponse
Public Sub New()
QuestionnaireAnswers = New QuestionnaireAnswers(){}
End Sub
Public Overridable Property Risk As RiskModel
Public Overridable Property Product As RecommendedProducts
Public Overridable Property RecommendedProductGraph As RecommendedProductGraph
Public Overridable Property QuestionnaireAnswers As QuestionnaireAnswers()
End Class
Public Partial Class MatrixNoRisk
Public Overridable Property MinimumAllocationInStocks As String
Public Overridable Property MaximumAllocationinStocks As String
End Class
Public Partial Class QuestionnaireAnswers
Public Overridable Property QuestionNumber As Integer
Public Overridable Property OptionNumber As Integer
End Class
Public Partial Class RecommendedProductGraph
Public Sub New()
BarGraphData = New List(Of Dictionary(Of String,String))
End Sub
Public Overridable Property BarGraphData As List(Of Dictionary(Of String,String))
Public Overridable Property PieGraphInfo As MatrixNoRisk
End Class
Public Partial Class RecommendedProducts
Public Overridable Property RecommendedProduct As RecommendedProductType
Public Overridable Property ChosenProduct As RecommendedProductType
End Class
Public Partial Class RecommendedProductType
Public Sub New()
InvestmentProducts = New List(Of InvestmentProduct)
End Sub
Public Overridable Property Product As String
Public Overridable Property InvestmentProduct As String
Public Overridable Property Score As Nullable(Of Double)
Public Overridable Property ProductType As Integer
Public Overridable Property InvestmentProducts As List(Of InvestmentProduct)
End Class
Public Partial Class RecommendedRisk
Public Overridable Property RiskName As String
Public Overridable Property RiskValue As Nullable(Of Integer)
Public Overridable Property RiskId As String
End Class
Public Partial Class RiskModel
Public Overridable Property RecommendedRisk As RecommendedRisk
Public Overridable Property ChosenRisk As RecommendedRisk
End Class
End Namespace
Namespace AlbaApi.ServiceModel
Public Partial Class InvestmentRiskProfileRiskRequest
Public Overridable Property EmployeeGuid As Guid
Public Overridable Property RiskId As String
End Class
End Namespace
Namespace TasSyd.Model.Core
Public Partial Class InvestmentProduct
Public Sub New()
Allocs = New List(Of InvestmentProductAllocationsSpec)
AllocationsDictionary = New Dictionary(Of Integer, Dictionary(Of String,Double))
End Sub
Public Overridable Property Code As String
Public Overridable Property Name As String
Public Overridable Property Group As String
Public Overridable Property IsAssetClassFund As Boolean
Public Overridable Property Allocs As List(Of InvestmentProductAllocationsSpec)
Public Overridable Property Order As Integer
Public Overridable Property AllocationsDictionary As Dictionary(Of Integer, Dictionary(Of String,Double))
End Class
Public Partial Class InvestmentProductAllocationsSpec
Public Sub New()
Allocs = New Dictionary(Of String, Double)
End Sub
Public Overridable Property FromAge As Integer
Public Overridable Property Term As Nullable(Of Integer)
Public Overridable Property Allocs As Dictionary(Of String, Double)
Public Overridable Property TotalAlloc As Double
End Class
End Namespace
End Namespace
VB.NET InvestmentRiskProfileRiskRequest 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.
PUT /members/{EmployeeGuid}/investmentprofile/risk HTTP/1.1
Host: hcbtas-q-albamfs-api.azurewebsites.net
Accept: application/xml
Content-Type: application/xml
Content-Length: length
<InvestmentRiskProfileRiskRequest xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/AlbaApi.ServiceModel">
<EmployeeGuid>00000000-0000-0000-0000-000000000000</EmployeeGuid>
<RiskId>String</RiskId>
</InvestmentRiskProfileRiskRequest>
HTTP/1.1 200 OK Content-Type: application/xml Content-Length: length <InvestmentRiskProfileResponse xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/AlbaApi.Model"> <Product> <ChosenProduct> <InvestmentProduct>String</InvestmentProduct> <InvestmentProducts> <InvestmentProduct> <RiskId>String</RiskId> <RiskName>String</RiskName> </InvestmentProduct> </InvestmentProducts> <Product>String</Product> <ProductType>0</ProductType> <Score>0</Score> </ChosenProduct> <RecommendedProduct> <InvestmentProduct>String</InvestmentProduct> <InvestmentProducts> <InvestmentProduct> <RiskId>String</RiskId> <RiskName>String</RiskName> </InvestmentProduct> </InvestmentProducts> <Product>String</Product> <ProductType>0</ProductType> <Score>0</Score> </RecommendedProduct> </Product> <QuestionnaireAnswers> <QuestionnaireAnswers> <OptionNumber>0</OptionNumber> <QuestionNumber>0</QuestionNumber> </QuestionnaireAnswers> </QuestionnaireAnswers> <RecommendedProductGraph> <BarGraphData xmlns:d3p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays"> <d3p1:ArrayOfKeyValueOfstringstring> <d3p1:KeyValueOfstringstring> <d3p1:Key>String</d3p1:Key> <d3p1:Value>String</d3p1:Value> </d3p1:KeyValueOfstringstring> </d3p1:ArrayOfKeyValueOfstringstring> </BarGraphData> <PieGraphInfo> <MaximumAllocationinStocks>String</MaximumAllocationinStocks> <MinimumAllocationInStocks>String</MinimumAllocationInStocks> </PieGraphInfo> </RecommendedProductGraph> <Risk> <ChosenRisk> <RiskId>String</RiskId> <RiskName>String</RiskName> <RiskValue>0</RiskValue> </ChosenRisk> <RecommendedRisk> <RiskId>String</RiskId> <RiskName>String</RiskName> <RiskValue>0</RiskValue> </RecommendedRisk> </Risk> </InvestmentRiskProfileResponse>