Server

<back to all web services

GetDeviceConsumptionList

Deviceconsumptions
Requires Authentication
The following routes are available for this service:
GET/api/v1/deviceconsumptions

export enum DeviceReadingKind
{
    ZA = 'ZA',
    HA = 'HA',
    MO = 'MO',
    EB = 'EB',
    AB = 'AB',
}

// @DataContract
export class DeviceConsumption
{
    // @DataMember
    public guid: string;

    // @DataMember
    public deviceReading?: number;

    // @DataMember
    public deviceReadingDate?: string;

    // @DataMember
    public deviceReadingKind: DeviceReadingKind;

    // @DataMember
    public changeDate?: string;

    // @DataMember
    public note: string;

    // @DataMember
    public ampouleColour: string;

    // @DataMember
    public deviceGuid: string;

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

export class GetDeviceConsumptionListResponse
{
    public deviceConsumptionList: DeviceConsumption[];
    public responseStatus: ResponseStatus;

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

export class GetDeviceConsumptionList implements IHasBearerToken
{
    // @ApiMember(IsRequired=true, ParameterType="query")
    public bearerToken: string;

    /** @description Optional! Follow the format : /api/v1/deviceconsumptions?filter[DeviceGuid]=* */
    // @DataMember(Name="filter[DeviceGuid]")
    // @ApiMember(Description="Optional! Follow the format : /api/v1/deviceconsumptions?filter[DeviceGuid]=*", ParameterType="query")
    public filter_DeviceGuid_: string;

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

TypeScript GetDeviceConsumptionList 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.

GET /api/v1/deviceconsumptions HTTP/1.1 
Host: develop-servdesk.eras-online.de 
Accept: text/jsv
HTTP/1.1 200 OK
Content-Type: text/jsv
Content-Length: length

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