ASP.NET VETtrak API web services
ContentsIndexHome
PreviousUpNext
VT_API.GetTraineesAndEmployeesForEmployer Method

Get all Trainees and Employees for an Employer. 

Returns an Authenticated Basic Client List containing all of the trainees and employees for the employer, according to an Active Contract Flag (parameter bActive) and an Active Employee Status (parameter iActiveStatus) passed as parameters. 

Each Trainee or Employee is represented by a TClie. The collection of Trainees and Employees is represented by a List of TClie

A token is passed for authentication. If the authentication fails, or other errors occur, no trainees or employees are returned. The result of the authentication is represented by a TAuthenticate object. 

An Employer Identifier is passed as a parameter. Valid Employer Identifiers are string representations of integers which match employers in the database. 

Valid Parameter Values: 

For bActive:

  • TRUE = Active Contracts Only,
  • FALSE = All Contracts - both Active & Inactive.
 

For iActiveStatus:

  • 0 = Active & Inactive Trainees,
  • 1 = Active Trainees Only,
  • 2 = Inactive Trainees Only.

C#
[WebMethod(Description = "Gets a list of trainees (optionally with only active contracts) and employees (active and/or inactive) for the employer with the specified ID")]
public TAuthClieList GetTraineesAndEmployeesForEmployer(string sToken, string sEmpl_Identifier, bool bActive, int iActiveStatus);
Parameters 
Description 
string sToken 
String Token. 
string sEmpl_Identifier 
String Employer Identifier. 
bool bActive 
Boolean Active Status of Training Contract.
  • True returns only active contracts.
  • False returns all contracts. 
int iActiveStatus 
Integer Active Status of Employee,
  • 0 returns Active & Inactive Trainees.
  • 1 returns Active Trainees Only.
  • 2 returns Inactive Trainees Only. 

TAuthClieList : an authenticated list of basic clients.

 

Does not include data relating to trainees or employees who decline to have their details published. 

This function has security level "Protected", and can only be accessed by users that have explicitly been granted permission to the API.

Copyright (c) VETtrak 2022. All rights reserved.