Field Squared API Services

<back to all web services

TaskType

The following routes are available for this service:
GET, POST, DELETE/{Workspace}/TaskType/{Type}
GET/{Workspace}/TaskType

export class RequiredAsset
{
    public Number: number;
    public Type: string;

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

export class RequiredInventoryType
{
    public Number: number;
    public Type: string;
    public Name: string;
    public IsSerialized: boolean;
    public Description: string;

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

export class RequiredUser
{
    public Number: number;
    public SkillTags: string[];

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

export class AutoCreateDocExpression
{
    public Document: string;
    public Expression: string;
    public MultipleCopies: boolean;

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

export class TaskType
{
    public Workspace: string;
    public Type: string;
    public Icon: string;
    public SkillTags: string[];
    public MinTimeToComplete: number;
    public AvgTimeToComplete: number;
    public MaxTimeToComplete: number;
    public Template: string;
    public DocFilter: boolean;
    public ShowRelatedDocs: boolean;
    public AllowedDocTypes: string[];
    public DefaultPriority?: number;
    public Inactive: boolean;
    public AutoCreateDocuments: string[];
    public PercentCompleteType: string;
    public UseJobTimers: boolean;
    public InheritAssetTeams: boolean;
    public InheritContactTeams: boolean;
    public EditTeams: string[];
    public UseRequired: boolean;
    public AllowOverride: boolean;
    public RequiredAssets: RequiredAsset[];
    public RequiredInventoryTypes: RequiredInventoryType[];
    public RequiredUsers: RequiredUser[];
    public ActiveLaborTypes: { [index: string]: Object; };
    public IndividualUserStatuses: boolean;
    public LockOption: boolean;
    public AutoCreateDocExpressions: AutoCreateDocExpression[];
    public PTO: boolean;

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

TypeScript TaskType DTOs

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

To embed the response in a jsonp callback, append ?callback=myCallback

HTTP + JSON

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

POST /{Workspace}/TaskType/{Type} HTTP/1.1 
Host: dev.fieldsquared.com 
Accept: application/json
Content-Type: application/json
Content-Length: length

{"Workspace":"String","Type":"String","Icon":"String","SkillTags":["String"],"MinTimeToComplete":0,"AvgTimeToComplete":0,"MaxTimeToComplete":0,"Template":"String","DocFilter":false,"ShowRelatedDocs":false,"AllowedDocTypes":["String"],"DefaultPriority":0,"Inactive":false,"AutoCreateDocuments":["String"],"PercentCompleteType":"String","UseJobTimers":false,"InheritAssetTeams":false,"InheritContactTeams":false,"EditTeams":["String"],"UseRequired":false,"AllowOverride":false,"RequiredAssets":[{"Number":0,"Type":"String"}],"RequiredInventoryTypes":[{"Number":0,"Type":"String","Name":"String","IsSerialized":false,"Description":"String"}],"RequiredUsers":[{"Number":0,"SkillTags":["String"]}],"ActiveLaborTypes":{"String":{}},"IndividualUserStatuses":false,"LockOption":false,"AutoCreateDocExpressions":[{"Document":"String","Expression":"String","MultipleCopies":false}],"PTO":false}