AlbaApi

<back to all web services

InvestmentRiskProfileSaveRequest

The following routes are available for this service:
POST/members/{EmployeeGuid}/investmentprofile
namespace AlbaApi.ServiceModel

open System
open System.Collections
open System.Collections.Generic
open System.Runtime.Serialization
open ServiceStack
open ServiceStack.DataAnnotations

    [<AllowNullLiteral>]
    type RecommendedRisk() = 
        member val RiskName:String = null with get,set
        member val RiskValue:Nullable<Int32> = new Nullable<Int32>() with get,set
        member val RiskId:String = null with get,set

    [<AllowNullLiteral>]
    type RiskModel() = 
        member val RecommendedRisk:RecommendedRisk = null with get,set
        member val ChosenRisk:RecommendedRisk = null with get,set

    [<AllowNullLiteral>]
    type InvestmentProductAllocationsSpec() = 
        member val FromAge:Int32 = new Int32() with get,set
        member val Term:Nullable<Int32> = new Nullable<Int32>() with get,set
        member val Allocs:Dictionary<String, Double> = new Dictionary<String, Double>() with get,set
        member val TotalAlloc:Double = new Double() with get,set

    [<AllowNullLiteral>]
    type InvestmentProduct() = 
        member val Code:String = null with get,set
        member val Name:String = null with get,set
        member val Group:String = null with get,set
        member val IsAssetClassFund:Boolean = new Boolean() with get,set
        member val Allocs:ResizeArray<InvestmentProductAllocationsSpec> = new ResizeArray<InvestmentProductAllocationsSpec>() with get,set
        member val Order:Int32 = new Int32() with get,set
        member val AllocationsDictionary:Dictionary<Int32, Dictionary<String,Double>> = new Dictionary<Int32, Dictionary<String,Double>>() with get,set

    [<AllowNullLiteral>]
    type RecommendedProductType() = 
        member val Product:String = null with get,set
        member val InvestmentProduct:String = null with get,set
        member val Score:Nullable<Double> = new Nullable<Double>() with get,set
        member val ProductType:Int32 = new Int32() with get,set
        member val InvestmentProducts:ResizeArray<InvestmentProduct> = new ResizeArray<InvestmentProduct>() with get,set

    [<AllowNullLiteral>]
    type RecommendedProducts() = 
        member val RecommendedProduct:RecommendedProductType = null with get,set
        member val ChosenProduct:RecommendedProductType = null with get,set

    [<AllowNullLiteral>]
    type MatrixNoRisk() = 
        member val MinimumAllocationInStocks:String = null with get,set
        member val MaximumAllocationinStocks:String = null with get,set

    [<AllowNullLiteral>]
    type RecommendedProductGraph() = 
        member val BarGraphData:ResizeArray<Dictionary<String,String>> = new ResizeArray<Dictionary<String,String>>() with get,set
        member val PieGraphInfo:MatrixNoRisk = null with get,set

    [<AllowNullLiteral>]
    type InvestmentRiskProfileSaveResponse() = 
        member val Risk:RiskModel = null with get,set
        member val Product:RecommendedProducts = null with get,set
        member val RecommendedProductGraph:RecommendedProductGraph = null with get,set

    [<AllowNullLiteral>]
    type InvestmentRiskProfileSaveRequest() = 
        member val EmployeeGuid:Guid = new Guid() with get,set
        member val Answers:QuestionnaireAnswers[] = [||] with get,set

    [<AllowNullLiteral>]
    type QuestionnaireAnswers() = 
        member val QuestionNumber:Int32 = new Int32() with get,set
        member val OptionNumber:Int32 = new Int32() with get,set

F# InvestmentRiskProfileSaveRequest DTOs

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

HTTP + JSON

The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.

POST /members/{EmployeeGuid}/investmentprofile HTTP/1.1 
Host: hcbtas-q-albamfs-api.azurewebsites.net 
Accept: application/json
Content-Type: application/json
Content-Length: length

{"employeeGuid":"00000000000000000000000000000000","answers":[{"questionNumber":0,"optionNumber":0}]}
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: length

{"risk":{"recommendedRisk":{"riskName":"String","riskValue":0,"riskId":"String"},"chosenRisk":{"riskName":"String","riskValue":0,"riskId":"String"}},"product":{"recommendedProduct":{"product":"String","investmentProduct":"String","score":0,"productType":0,"investmentProducts":[{"riskId":"String","riskName":"String"}]},"chosenProduct":{"product":"String","investmentProduct":"String","score":0,"productType":0,"investmentProducts":[{"riskId":"String","riskName":"String"}]}},"recommendedProductGraph":{"barGraphData":[{"String":"String"}],"pieGraphInfo":{"minimumAllocationInStocks":"String","maximumAllocationinStocks":"String"}}}