AlbaApi

<back to all web services

UpdateConfigReq

The following routes are available for this service:
POST/config/update

export class Entity implements IEntity
{
    public id?: string;

    public constructor(init?: Partial<Entity>) { (Object as any).assign(this, init); }
}

export class Country
{
    public name?: string;
    public languages?: { [index: string]: string; };

    public constructor(init?: Partial<Country>) { (Object as any).assign(this, init); }
}

export class ListItem extends Entity
{
    public listId?: string;
    public country?: string;
    public relatedId?: string;
    public code?: string;
    public custom?: string;

    public constructor(init?: Partial<ListItem>) { super(init); (Object as any).assign(this, init); }
}

export class SiteSection
{
    public route?: string;
    public public?: boolean;
    public parent?: string;
    public roles?: number;
    public hideFrom?: string[];
    public order?: number;

    public constructor(init?: Partial<SiteSection>) { (Object as any).assign(this, init); }
}

export class Configuration extends Entity
{
    public category?: string;
    public countries?: { [index: string]: Country; };
    public listItems?: ListItem[];
    public listRelationships?: { [index: string]: string; };
    public sectionElements?: { [index: string]: string[]; };
    public siteStructure?: { [index: string]: SiteSection; };
    public version?: number;
    public createdBy?: string;
    public dateCreated?: string;
    public updatedBy?: string;
    public dateUpdated?: string;

    public constructor(init?: Partial<Configuration>) { super(init); (Object as any).assign(this, init); }
}

export class UpdateConfigReq
{
    public category?: string;
    public countries?: { [index: string]: Country; };
    public listItems?: ListItem[];
    public listRelationships?: { [index: string]: string; };
    public sectionElements?: { [index: string]: string[]; };
    public siteStructure?: { [index: string]: SiteSection; };

    public constructor(init?: Partial<UpdateConfigReq>) { (Object as any).assign(this, init); }
}

TypeScript UpdateConfigReq DTOs

To override the Content-type in your clients, use the HTTP Accept Header, append the .jsv suffix or ?format=jsv

HTTP + JSV

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

POST /config/update HTTP/1.1 
Host: hcbtas-q-albamfs-api.azurewebsites.net 
Accept: text/jsv
Content-Type: text/jsv
Content-Length: length

{
	category: String,
	countries: 
	{
		String: 
		{
			name: String,
			languages: 
			{
				String: String
			}
		}
	},
	listItems: 
	[
		{
			listId: String,
			country: String,
			relatedId: String,
			code: String,
			custom: String,
			id: String
		}
	],
	listRelationships: 
	{
		String: String
	},
	sectionElements: 
	{
		String: 
		[
			String
		]
	},
	siteStructure: 
	{
		String: 
		{
			route: String,
			public: False,
			parent: String,
			roles: 0,
			hideFrom: 
			[
				String
			],
			order: 0
		}
	}
}
HTTP/1.1 200 OK
Content-Type: text/jsv
Content-Length: length

{
	category: String,
	countries: 
	{
		String: 
		{
			name: String,
			languages: 
			{
				String: String
			}
		}
	},
	listItems: 
	[
		{
			listId: String,
			country: String,
			relatedId: String,
			code: String,
			custom: String,
			id: String
		}
	],
	listRelationships: 
	{
		String: String
	},
	sectionElements: 
	{
		String: 
		[
			String
		]
	},
	siteStructure: 
	{
		String: 
		{
			route: String,
			public: False,
			parent: String,
			roles: 0,
			hideFrom: 
			[
				String
			],
			order: 0
		}
	},
	version: 0,
	createdBy: String,
	dateCreated: 0001-01-01,
	updatedBy: String,
	dateUpdated: 0001-01-01,
	id: String
}