@iotile/iotile-cloud
Version:
A typescript library for interfacing with the IOTile Cloud API
34 lines (33 loc) • 946 B
TypeScript
import { Membership } from './membership';
import { ServerInformation } from './server-information';
export declare class User {
slug: string;
tagline: string;
username: string;
name: string;
isStaff: boolean;
email: string;
avatarUrl?: string;
creationDate: Date;
token: string;
id: string;
private orgRoles;
constructor(data?: any, token?: string);
toJson(): any;
static Unserialize(obj: {
[key: string]: any;
}): {
user: User;
server: ServerInformation | undefined;
};
getFullName(): string;
getUsername(): string;
getAvatar(): string;
setOrgRoles(roles: {
[key: string]: Membership;
}): void;
canReadProperties(orgSlug: string): boolean;
canModifyDevice(orgSlug: string): boolean;
canModifyStreamVariables(orgSlug: string): boolean;
canResetDevice(orgSlug: string): boolean;
}