AlbaApi

<back to all web services

ClientCountryConfigValidateReq

The following routes are available for this service:
POST/clientcountryconfig/validate
import java.math.*
import java.util.*
import net.servicestack.client.*
import com.google.gson.annotations.*
import com.google.gson.reflect.*


open class ClientCountryConfigValidateReq
{
    var config:ClientCountryConfig? = null
}

open class ClientCountryConfig : DatedEntity()
{
    var clientCode:String? = null
    var clientName:String? = null
    var countryCode:String? = null
    var source:DataSourceResult? = null
    var ageRMin:Int? = null
    var ageRMax:Int? = null
    var primarySalary:String? = null
    var annuityConfig:AnnuityConfig? = null
    var assets:ArrayList<AssetConfig> = ArrayList<AssetConfig>()
    var contTables:ArrayList<ContributionTableSpec> = ArrayList<ContributionTableSpec>()
    var investments:ArrayList<InvestmentProduct> = ArrayList<InvestmentProduct>()
    var content:HashMap<String,ArrayList<Content>> = HashMap<String,ArrayList<Content>>()
    var environments:HashMap<String,String> = HashMap<String,String>()
    var customNumericConstraints:HashMap<String,Constraint<BigDecimal>> = HashMap<String,Constraint<BigDecimal>>()
    var assetReturnRates:HashMap<String,ReturnRates> = HashMap<String,ReturnRates>()
    var investmentPropertyRates:Double? = null
    var getAssetClassFundDictionary:HashMap<String,Boolean> = HashMap<String,Boolean>()
    var getTermBasedFundDictionary:HashMap<String,Boolean> = HashMap<String,Boolean>()
    var getAllocationsDictionary:HashMap<String,HashMap<Int,HashMap<String,Double>>> = HashMap<String,HashMap<Int,HashMap<String,Double>>>()
    var assetNameMap:HashMap<String,String> = HashMap<String,String>()
    var assetContNameMap:HashMap<String,HashMap<String,String>> = HashMap<String,HashMap<String,String>>()
    var cacheKey:String? = null
}

open class DatedEntity : Entity(), IDatedEntity
{
    var asAt:Date? = null
}

open class Entity : IEntity
{
    var id:String? = null
}

open class DataSourceResult
{
    var d:DataSource? = null
    var t:Long? = null
}

enum class DataSource
{
    Db,
    Cache,
    Parameter,
    Na,
}

open class AnnuityConfig
{
    var tableNames:ArrayList<LifeTableName> = ArrayList<LifeTableName>()
    var imprFactorTableNames:ArrayList<LifeTableName> = ArrayList<LifeTableName>()
    var reversion:Double? = null
    var guarantee:Double? = null
    var timing:Double? = null
    var allowDiscountPreRet:Boolean? = null
    var scaleQx:Double? = null
    var scaleImpr:Double? = null
    var ageRating:Int? = null
    var spouseAgeRating:Int? = null
    var expense:Double? = null
    var percBalanceSpent:Double? = null
    var amountSpent:Double? = null
    var incomePurchased:Double? = null
    var deferralPeriod:Int? = null
    var indexationName:String? = null
    var drStochastic:String? = null
    var impliedInflationStochasticSeries:String? = null
    var targetTpx:Double? = null
    var priceType:AnnuityPriceType? = null
    var price:Double? = null
}

open class LifeTableName
{
    var name:String? = null
    var gender:Gender? = null
}

enum class Gender
{
    Female,
    Male,
    Other,
}

enum class AnnuityPriceType
{
    Calc,
    Table,
}

open class AssetConfig
{
    var code:String? = null
    var name:String? = null
    var rebalance:Boolean? = null
    var canEditInvestmentChoice:Boolean? = null
    var willSpend:Boolean? = null
    var investments:ArrayList<String> = ArrayList<String>()
    var contributions:ArrayList<ContributionSpec> = ArrayList<ContributionSpec>()
    var isOneOff:Boolean? = null
}

open class ContributionSpec
{
    var code:String? = null
    var name:String? = null
    @SerializedName("type") var Type:ContributionType? = null
    var isEmployeeCont:Boolean? = null
    var table:String? = null
    var ccy:String? = null
    var fromAge:Int? = null
    var toAge:Int? = null
    var indexationType:String? = null
    var salaryType:String? = null
    var isTaxable:Boolean? = null
    var relatedRate:String? = null
    var order:Int? = null
    var editable:Boolean? = null
    var constraints:ArrayList<ContributionConstraint> = ArrayList<ContributionConstraint>()
    var amountType:AmountType? = null
    var isOneOff:Boolean? = null
}

enum class ContributionType
{
    Fixed,
    Time,
    Lookup,
    Match,
}

open class ContributionConstraint
{
    var fromAge:Int? = null
    var toAge:Int? = null
    var min:Double? = null
    var max:Double? = null
    var step:Double? = null
}

enum class AmountType
{
    Any,
    Amount,
    Rate,
}

open class ContributionTableSpec
{
    var code:String? = null
    @SerializedName("type") var Type:ContributionType? = null
    var rates:HashMap<String,Double> = HashMap<String,Double>()
    var rateSpecs:ArrayList<ContributionRateSpec> = ArrayList<ContributionRateSpec>()
    var keyTemplate:String? = null
}

open class ContributionRateSpec
{
    var fromAge:Int? = null
    var toAge:Int? = null
    var fromService:Int? = null
    var toService:Int? = null
    var sourceRate:Double? = null
    var dateFrom:Date? = null
    var dateTo:Date? = null
    var upperLimit:Double? = null
    var rate:Double? = null
    var coreRate:Double? = null
    var lookupKey:String? = null
}

open class InvestmentProduct
{
    var code:String? = null
    var name:String? = null
    var group:String? = null
    var isAssetClassFund:Boolean? = null
    var allocs:ArrayList<InvestmentProductAllocationsSpec> = ArrayList<InvestmentProductAllocationsSpec>()
    var order:Int? = null
    var allocationsDictionary:HashMap<Int,HashMap<String,Double>> = HashMap<Int,HashMap<String,Double>>()
}

open class InvestmentProductAllocationsSpec
{
    var fromAge:Int? = null
    var term:Int? = null
    var allocs:HashMap<String,Double> = HashMap<String,Double>()
    var totalAlloc:Double? = null
}

open class ReturnRates
{
    var earningRates:ArrayList<Double> = ArrayList<Double>()
    var taxRates:ArrayList<Double> = ArrayList<Double>()
}

Kotlin ClientCountryConfigValidateReq 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 /clientcountryconfig/validate HTTP/1.1 
Host: hcbtas-q-albamfs-api.azurewebsites.net 
Accept: application/json
Content-Type: application/json
Content-Length: length

{"config":{"clientCode":"String","clientName":"String","countryCode":"String","source":{"d":"Db","t":0},"ageRMin":0,"ageRMax":0,"primarySalary":"String","annuityConfig":{"tableNames":[{"name":"String","gender":"Female"}],"imprFactorTableNames":[{"name":"String","gender":"Female"}],"reversion":0,"guarantee":0,"timing":0,"allowDiscountPreRet":false,"scaleQx":0,"scaleImpr":0,"ageRating":0,"spouseAgeRating":0,"expense":0,"percBalanceSpent":0,"amountSpent":0,"incomePurchased":0,"deferralPeriod":0,"indexationName":"String","drStochastic":"String","impliedInflationStochasticSeries":"String","targetTpx":0,"priceType":"Calc","price":0},"assets":[{"code":"String","name":"String","rebalance":false,"canEditInvestmentChoice":false,"willSpend":false,"investments":["String"],"contributions":[{"code":"String","name":"String","type":"Fixed","isEmployeeCont":false,"table":"String","ccy":"String","fromAge":0,"toAge":0,"indexationType":"String","salaryType":"String","isTaxable":false,"relatedRate":"String","order":0,"editable":false,"constraints":[{"fromAge":0,"toAge":0,"min":0,"max":0,"step":0}],"amountType":"Any","isOneOff":false}],"isOneOff":false}],"contTables":[{"code":"String","type":"Fixed","rates":{"String":0},"rateSpecs":[{"fromAge":0,"toAge":0,"fromService":0,"toService":0,"sourceRate":0,"dateFrom":"0001-01-01T00:00:00.0000000","dateTo":"0001-01-01T00:00:00.0000000","upperLimit":0,"rate":0,"coreRate":0,"lookupKey":"String"}],"keyTemplate":"age-service-rate"}],"investments":[{"code":"String","name":"String","group":"String","isAssetClassFund":false,"allocs":[{"fromAge":0,"term":0,"allocs":{"String":0},"totalAlloc":0}],"order":0,"allocationsDictionary":{"0":{}}}],"content":{"String":[{"section":"String","itemId":"String","itemCode":"String","country":"String","lang":"String","app":"String","companyId":"String","company":"String","elements":{"String":"String"},"id":"String"}]},"environments":{"String":"String"},"customNumericConstraints":{"String":{"min":0,"max":0,"step":0}},"assetReturnRates":{"String":{"earningRates":[0],"taxRates":[0]}},"investmentPropertyRates":0,"getAssetClassFundDictionary":{"String":false},"getTermBasedFundDictionary":{"String":true},"getAllocationsDictionary":{"String":{"0":{}}},"assetNameMap":{"String":"String"},"assetContNameMap":{"String":{"String":"String"}},"cacheKey":"ClientCountryConfig-String-String","asAt":"0001-01-01T00:00:00.0000000","id":"String"}}
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: length

{"clientCode":"String","clientName":"String","countryCode":"String","source":{"d":"Db","t":0},"ageRMin":0,"ageRMax":0,"primarySalary":"String","annuityConfig":{"tableNames":[{"name":"String","gender":"Female"}],"imprFactorTableNames":[{"name":"String","gender":"Female"}],"reversion":0,"guarantee":0,"timing":0,"allowDiscountPreRet":false,"scaleQx":0,"scaleImpr":0,"ageRating":0,"spouseAgeRating":0,"expense":0,"percBalanceSpent":0,"amountSpent":0,"incomePurchased":0,"deferralPeriod":0,"indexationName":"String","drStochastic":"String","impliedInflationStochasticSeries":"String","targetTpx":0,"priceType":"Calc","price":0},"assets":[{"code":"String","name":"String","rebalance":false,"canEditInvestmentChoice":false,"willSpend":false,"investments":["String"],"contributions":[{"code":"String","name":"String","type":"Fixed","isEmployeeCont":false,"table":"String","ccy":"String","fromAge":0,"toAge":0,"indexationType":"String","salaryType":"String","isTaxable":false,"relatedRate":"String","order":0,"editable":false,"constraints":[{"fromAge":0,"toAge":0,"min":0,"max":0,"step":0}],"amountType":"Any","isOneOff":false}],"isOneOff":false}],"contTables":[{"code":"String","type":"Fixed","rates":{"String":0},"rateSpecs":[{"fromAge":0,"toAge":0,"fromService":0,"toService":0,"sourceRate":0,"dateFrom":"0001-01-01T00:00:00.0000000","dateTo":"0001-01-01T00:00:00.0000000","upperLimit":0,"rate":0,"coreRate":0,"lookupKey":"String"}],"keyTemplate":"age-service-rate"}],"investments":[{"code":"String","name":"String","group":"String","isAssetClassFund":false,"allocs":[{"fromAge":0,"term":0,"allocs":{"String":0},"totalAlloc":0}],"order":0,"allocationsDictionary":{"0":{}}}],"content":{"String":[{"section":"String","itemId":"String","itemCode":"String","country":"String","lang":"String","app":"String","companyId":"String","company":"String","elements":{"String":"String"},"id":"String"}]},"environments":{"String":"String"},"customNumericConstraints":{"String":{"min":0,"max":0,"step":0}},"assetReturnRates":{"String":{"earningRates":[0],"taxRates":[0]}},"investmentPropertyRates":0,"getAssetClassFundDictionary":{"String":false},"getTermBasedFundDictionary":{"String":true},"getAllocationsDictionary":{"String":{"0":{}}},"assetNameMap":{"String":"String"},"assetContNameMap":{"String":{"String":"String"}},"cacheKey":"ClientCountryConfig-String-String","asAt":"0001-01-01T00:00:00.0000000","id":"String"}