Betting.WebApi

<back to all web services

AddLocationDevice

Requires Authentication
The following routes are available for this service:
POST/cmd/locations/devices/add
"use strict";
/** @typedef {number} */
export var DeviceType;
(function (DeviceType) {
    DeviceType[DeviceType["ClerkServicedKiosk"] = 0] = "ClerkServicedKiosk"
    DeviceType[DeviceType["PersonalOnline"] = 1] = "PersonalOnline"
    DeviceType[DeviceType["SelfServiceKiosk"] = 2] = "SelfServiceKiosk"
    DeviceType[DeviceType["Unknown"] = -1] = "Unknown"
})(DeviceType || (DeviceType = {}));
export class Device {
    /** @param {{id?:string,name?:string,isActive?:boolean,type?:DeviceType,integrationsData?:RecordDictionary<string, string>}} [init] */
    constructor(init) { Object.assign(this, init) }
    /** @type {string} */
    id;
    /** @type {string} */
    name;
    /** @type {boolean} */
    isActive;
    /** @type {DeviceType} */
    type;
    /** @type {RecordDictionary<string, string>} */
    integrationsData;
}
export class AddLocationDevice {
    /** @param {{id?:string,device?:Device}} [init] */
    constructor(init) { Object.assign(this, init) }
    /** @type {string} */
    id;
    /** @type {Device} */
    device;
}
class Dictionary {}
/** @typedef TKey {any} */
/** @typedef  TVal {any} */
export class RecordDictionary extends Dictionary {
    constructor(init) { super(init); Object.assign(this, init) }
}

JavaScript AddLocationDevice 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 /cmd/locations/devices/add HTTP/1.1 
Host: api.sbbet.ath.cx 
Accept: text/jsv
Content-Type: text/jsv
Content-Length: length

{
	id: String,
	device: 
	{
		id: String,
		name: String,
		isActive: False,
		type: 0,
		integrationsData: 
		{
			String: String
		}
	}
}
HTTP/1.1 200 OK
Content-Type: text/jsv
Content-Length: length

{
	errorCode: String,
	message: String,
	stackTrace: String,
	errors: 
	[
		{
			errorCode: String,
			fieldName: String,
			message: String,
			meta: 
			{
				String: String
			}
		}
	],
	meta: 
	{
		String: String
	}
}