All Verbs | /admin/app | ||
---|---|---|---|
All Verbs | /admin/app/{Country} | ||
All Verbs | /admin/app/{Country}/{Lang} |
import java.math.*
import java.util.*
import net.servicestack.client.*
import com.google.gson.annotations.*
import com.google.gson.reflect.*
open class AdminAppReq
{
var country:String? = null
var lang:String? = null
}
open class AdminAppData
{
var siteStructure:HashMap<String,SiteSection> = HashMap<String,SiteSection>()
var sectionElements:HashMap<String,ArrayList<String>> = HashMap<String,ArrayList<String>>()
var listRelationships:HashMap<String,String> = HashMap<String,String>()
var listItems:ArrayList<ListItem> = ArrayList<ListItem>()
var countries:HashMap<String,Country> = HashMap<String,Country>()
var content:ArrayList<Content> = ArrayList<Content>()
var user:User? = null
var scriptTrackerRecords:ArrayList<ScriptTracker> = ArrayList<ScriptTracker>()
var configurations:ArrayList<Configuration> = ArrayList<Configuration>()
}
open class SiteSection
{
var route:String? = null
@SerializedName("public") var Public:Boolean? = null
var parent:String? = null
var roles:Int? = null
var hideFrom:ArrayList<String> = ArrayList<String>()
var order:Int? = null
}
open class ListItem : Entity()
{
var listId:String? = null
var country:String? = null
var relatedId:String? = null
var code:String? = null
var custom:String? = null
}
open class Entity : IEntity
{
var id:String? = null
}
open class Country
{
var name:String? = null
var languages:HashMap<String,String> = HashMap<String,String>()
}
open class Content : Entity()
{
var section:String? = null
var itemId:String? = null
var itemCode:String? = null
var country:String? = null
var lang:String? = null
var app:String? = null
var companyId:String? = null
var company:String? = null
var elements:HashMap<String,String> = HashMap<String,String>()
}
open class User
{
var roles:Roles? = null
}
@Flags()
enum class Roles(val value:Int)
{
@SerializedName("0") None(0),
@SerializedName("1") Employee(1),
@SerializedName("2") Member(2),
@SerializedName("4") Employer(4),
@SerializedName("8") Broker(8),
@SerializedName("16") Developer(16),
@SerializedName("32") SysAdmin(32),
}
open class ScriptTracker : Entity()
{
var sprint:String? = null
var country:String? = null
var language:String? = null
var section:String? = null
var itemCode:String? = null
var element:String? = null
var value:String? = null
var isFromMerge:Boolean? = null
}
open class Configuration : Entity()
{
var category:String? = null
var countries:HashMap<String,Country> = HashMap<String,Country>()
var listItems:ArrayList<ListItem> = ArrayList<ListItem>()
var listRelationships:HashMap<String,String> = HashMap<String,String>()
var sectionElements:HashMap<String,ArrayList<String>> = HashMap<String,ArrayList<String>>()
var siteStructure:HashMap<String,SiteSection> = HashMap<String,SiteSection>()
var version:Int? = null
var createdBy:String? = null
var dateCreated:Date? = null
var updatedBy:String? = null
var dateUpdated:Date? = null
}
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 /admin/app HTTP/1.1
Host: hcbtas-q-albamfs-api.azurewebsites.net
Accept: application/xml
Content-Type: application/xml
Content-Length: length
<AdminAppReq xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/AlbaApi.ServiceModel">
<Country>String</Country>
<Lang>String</Lang>
</AdminAppReq>
HTTP/1.1 200 OK Content-Type: application/xml Content-Length: length <AdminAppData xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/AlbaApi.Application.DTOs"> <Configurations xmlns:d2p1="http://schemas.datacontract.org/2004/07/AlbaApi.Model" i:nil="true" /> <Content xmlns:d2p1="http://schemas.datacontract.org/2004/07/TasSyd.Model"> <d2p1:Content> <Id xmlns="http://schemas.datacontract.org/2004/07/TasSyd.Model.Base">String</Id> <d2p1:App>String</d2p1:App> <d2p1:Company>String</d2p1:Company> <d2p1:CompanyId>String</d2p1:CompanyId> <d2p1:Country>String</d2p1:Country> <d2p1:Elements xmlns:d4p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays"> <d4p1:KeyValueOfstringstring> <d4p1:Key>String</d4p1:Key> <d4p1:Value>String</d4p1:Value> </d4p1:KeyValueOfstringstring> </d2p1:Elements> <d2p1:ItemCode>String</d2p1:ItemCode> <d2p1:ItemId>String</d2p1:ItemId> <d2p1:Lang>String</d2p1:Lang> <d2p1:Section>String</d2p1:Section> </d2p1:Content> </Content> <Countries xmlns:d2p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays"> <d2p1:KeyValueOfstringCountryFNLs6TVB> <d2p1:Key>String</d2p1:Key> <d2p1:Value xmlns:d4p1="http://schemas.datacontract.org/2004/07/AlbaApi.Model"> <d4p1:Languages> <d2p1:KeyValueOfstringstring> <d2p1:Key>String</d2p1:Key> <d2p1:Value>String</d2p1:Value> </d2p1:KeyValueOfstringstring> </d4p1:Languages> <d4p1:Name>String</d4p1:Name> </d2p1:Value> </d2p1:KeyValueOfstringCountryFNLs6TVB> </Countries> <ListItems xmlns:d2p1="http://schemas.datacontract.org/2004/07/AlbaApi.Model"> <d2p1:ListItem> <Id xmlns="http://schemas.datacontract.org/2004/07/TasSyd.Model.Base">String</Id> <d2p1:Code>String</d2p1:Code> <d2p1:Country>String</d2p1:Country> <d2p1:Custom>String</d2p1:Custom> <d2p1:ListId>String</d2p1:ListId> <d2p1:RelatedId>String</d2p1:RelatedId> </d2p1:ListItem> </ListItems> <ListRelationships xmlns:d2p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays"> <d2p1:KeyValueOfstringstring> <d2p1:Key>String</d2p1:Key> <d2p1:Value>String</d2p1:Value> </d2p1:KeyValueOfstringstring> </ListRelationships> <ScriptTrackerRecords xmlns:d2p1="http://schemas.datacontract.org/2004/07/AlbaApi.Model"> <d2p1:ScriptTracker> <Id xmlns="http://schemas.datacontract.org/2004/07/TasSyd.Model.Base">String</Id> <d2p1:Country>String</d2p1:Country> <d2p1:Element>String</d2p1:Element> <d2p1:IsFromMerge>false</d2p1:IsFromMerge> <d2p1:ItemCode>String</d2p1:ItemCode> <d2p1:Language>String</d2p1:Language> <d2p1:Section>String</d2p1:Section> <d2p1:Sprint>String</d2p1:Sprint> <d2p1:Value>String</d2p1:Value> </d2p1:ScriptTracker> </ScriptTrackerRecords> <SectionElements xmlns:d2p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays"> <d2p1:KeyValueOfstringArrayOfstringty7Ep6D1> <d2p1:Key>String</d2p1:Key> <d2p1:Value> <d2p1:string>String</d2p1:string> </d2p1:Value> </d2p1:KeyValueOfstringArrayOfstringty7Ep6D1> </SectionElements> <SiteStructure xmlns:d2p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays"> <d2p1:KeyValueOfstringSiteSectionFNLs6TVB> <d2p1:Key>String</d2p1:Key> <d2p1:Value xmlns:d4p1="http://schemas.datacontract.org/2004/07/AlbaApi.Model"> <d4p1:HideFrom> <d2p1:string>String</d2p1:string> </d4p1:HideFrom> <d4p1:Order>0</d4p1:Order> <d4p1:Parent>String</d4p1:Parent> <d4p1:Public>false</d4p1:Public> <d4p1:Roles>0</d4p1:Roles> <d4p1:Route>String</d4p1:Route> </d2p1:Value> </d2p1:KeyValueOfstringSiteSectionFNLs6TVB> </SiteStructure> <User xmlns:d2p1="http://schemas.datacontract.org/2004/07/AlbaApi.Model"> <d2p1:Roles>None</d2p1:Roles> </User> </AdminAppData>