Tätä artikkelia ei ole vielä käännetty Suomeksi.
Important
Please ensure you are using the time.nepton.com domain. The old tyoaika.tyoteho.fi domain will be retired.
Production API description
https://time.nepton.com/WebService.php?WSDL
Test API description (only available to selected customers)
https://publictesting-time.nepton.com/WebService.php?WSDL
Contents
Authentication
To authenticate a CallerAuthentication element must be supplied in the call. More details on CallerAuthentication is found here.
Username and Password are credentials of a person set up in Nepton. The access rights for the API are the same that they have in Nepton user interface. Guidance for setting up the person is here.
CustomerId can be asked from Nepton customer service.
Web Service Definitions
GetProjectsV2
This is a general-purpose web service for fetching projects/locations by filters. V2 returns projects with ExternalIdentifiers, and allows filtering by them as well
Input parameters:
- CallerAuthentication - authentication object (see structure below)
- FilterByProjectIds(string) - filter results by project ID, accepts a single integer or a comma separated list of integers
- FilterByExternalIdentifiers(string) - filter results by project external identifier, accepts a single identifier of a comma separated list of identifiers
- FilterByProjectName(string) - filter results by project name, accepts use of wildcard "*" for search based requests
- FilterByProjectCode(string) - filter results by project code, accepts use of wildcard "*" for search based requests
- FilterByUserGroupId(int) - filter results by projects attached to user group ID
- FilterByTerminalProjectsOnly(bool) - return only projects that should be shown in the terminal
- FilterByProjectTypeInternalName(string) - return projects by project type (using the internal string ID, not the customer specific name/translation for it e.g. "location", "project_work", "unit" etc)
- FilterActiveProjectsByStartDate(string) and FilterActiveProjectsByEndDate(string) - provide both dates to only return active (non-complete) projects between the provided dates. Format YYYY-MM-DD
- OrderResultsFirstBy(string), OrderResultsSecondBy(string) and OrderResultsThirdBy(string) - allows you to order the results by 3 columns with flat_list return types, supported options are: projectid, left, right, name, code, internaltype
- IncludeDeletedProjects(bool) - return deleted projects in the results, deleted projects cannot be undeleted so this is for informational purposes only
- ReturnFormat(string) - how to format the project results, supported options are: "flat_list" (return a single list that isn't nested)
Return fields:
- ResponseCode
- ResponseString
- ProjectListV2 - a list of ProjectWithExternalIdentifiers elements (see structure below) structured by "ReturnFormat" input parameter
GetProjects
This is an older version of a general-purpose web service for fetching projects/locations by filters. Please consider using GetProjectsV2 instead of this one as this version does not support external project identifiers.
Input parameters:
- CallerAuthentication - authentication object (see structure below)
- FilterByProjectIds(string) - filter results by project ID, accepts a single integer or a comma separated list of integers
- FilterByProjectName(string) - filter results by project name, accepts use of wildcard "*" for search based requests
- FilterByProjectCode(string) - filter results by project code, accepts use of wildcard "*" for search based requests
- FilterByUserGroupId(int) - filter results by projects attached to user group ID
- FilterByTerminalProjectsOnly(bool) - return only projects that should be shown in the terminal
- FilterByProjectTypeInternalName(string) - return projects by project type (using the internal string ID, not the customer specific name/translation for it e.g. "location", "project_work", "unit" etc)
- FilterActiveProjectsByStartDate(string) and FilterActiveProjectsByEndDate(string) - provide both dates to only return active (non-complete) projects between the provided dates. Format YYYY-MM-DD
- OrderResultsFirstBy(string), OrderResultsSecondBy(string) and OrderResultsThirdBy(string) - allows you to order the results by 3 columns with flat_list return types, supported options are: projectid, left, right, name, code, internaltype
- IncludeDeletedProjects(bool) - return deleted projects in the results, deleted projects cannot be undeleted so this is for informational purposes only
- ReturnFormat(string) - how to format the project results, supported options are: "flat_list" (return a single list that isn't nested)
Return fields:
- ResponseCode
- ResponseString
- ProjectList - a list of Project elements (see structure below) structured by "ReturnFormat" input parameter
InsertProjects
This is a general purpose web service for inserting projects/locations. If multiple projects are inserted they should be put into one request.
Input parameters:
- CallerAuthentication - authentication object (see structure below)
- ProjectList - list of project elements (see structure below)
Return fields:
- ResponseCode
- ResponseString
- ProjectInsertResultList - A list of results for whether each project was inserted successfully or not
UpdateProjects
This is a general purpose web service for batch updating projects/locations. The "Id" field is mandatory for each Project being updated and is the only valid identifier. All other parameters are optional, do not pass the parameter if you do not want the field to be updated, setting a parameter to null will save the field as null.
Input parameters:
- CallerAuthentication - authentication object (see structure below)
- ProjectList - list of project elements (see structure below)
Return fields:
- ResponseCode
- ResponseString
- ProjectUpdateResultList - A list of results for whether each project was updated successfully or not
EnsureProjectsExist
This is a general purpose methdod for batch updating/inserting projects/locations. Name is mandatory and TypeInternalName is mandatory with new projects. All other parameters are optional, do not pass the parameter if you do not want the field to be updated, setting a parameter to null will save the field as null.
Both Id and Code can be used as project identifier.
Input parameters:
- CallerAuthentication - authentication object (see structure below)
- ProjectList - list of project elements (see structure below)
Return fields:
- ResponseCode
- ResponseString
- EnsureProjectsExistResultList - A list of results for whether each project already existed, was created especially, or if there was any errors
EnsureProjectsExistV2
This function supports identifying the project by identifier type and updating project contents. More detailed description is here.
SetVisibleProjectsForUserV2
This is a general purpose method for batch updating project visibility on user level.
Internal Id, ProjectCode, and an external ProjectIdentifier can be used as the project identifier.
Input parameters:
- CallerAuthentication - authentication object (see structure below)
- SetVisibleProjectsForUserListV2 - list of project2user visibility elements
Return fields:
- ResponseCode
- ResponseString
- SetVisibleProjectsForUserResultListV2 - list of results of whether setting the visibility per user per project was successful. Per row codes 1000 (ok, project was attached), 1004 (project not found) or 1003 (user not found) is supplied.
GetActivities
General purpose web service for fetching work registrations, absences, holidays, travel invoices, planned shifts or any other activity/event details. Returns a list of Activity elements.
Does not return activities belonging to removed persons.
Input parameters:
- CallerAuthentication - authentication object (see structure below)
- FilterByUserIds - Optional comma separated list of Worktime User ID's to filter results by (preferred method of fetching activities by user!)
- FilterByUserNames – Optional, comma separated list of usernames to filter results by (slower than using UserId's)
- FilterByActivityTypeIds – Optional, comma separated list of Worktime activity type ID's to filter results by (Available activity type ids can be found using the GetActivityTypes function)
- FilterPeriodBeginDateTime - Optional, filter by events marked to the calendar after this date time (YYYY-MM-DD HH:MM:SS)
- FilterPeriodEndDateTime - Optional, filter by events marked to the calendar before this date time (YYYY-MM-DD HH:MM:SS)
- FilterModifiedBeginDateTime - Optional, filter by events created/modified after this date time (YYYY-MM-DD HH:MM:SS)
- FilterModifiedEndDateTime - Optional, filter by events created/modified after this date time (YYYY-MM-DD HH:MM:SS)
- IncludeDeleted - Optional, include deleted activities in results. Boolean, defaults to false
- OrderResultsFirstBy - Optional, you can sort results by up to three parameters. Supported params are activityid|activitybegindatetime|activityenddatetime|userid|activitytypeid. If no params are provided results default to ordering by userid ASC, activitybegindatetime ASC, activityenddatetime ASC respectively
- OrderResultsSecondBy - Used in conjunction OrderResultsFirstBy, see above
- OrderResultsThirdBy - Used in conjunction OrderResultsFirstBy+OrderResultsSecondBy, see above
Return fields:
- ResponseCode
- ResponseString
- ActivityList - List of Activity objects, see structure below
BeginActivity
Begins the specified activity for the user specified in CallerAuthentication object
- CallerAuthentication - authentication object (see structure below)
- ActivityTypeId - int, The Type of activity (Available activity type ids can be found using the GetActivityTypes function)
- BeginDateTime - Optional, datetime (ISO8601 compatible datetime format e.g. YYYY-MM-DDTHH:MM:SS. Timezone information not currently supported, EET/EEST used.)
- EndDateTime - Optional, datetime (ISO8601 compatible datetime format e.g. YYYY-MM-DDTHH:MM:SS. Timezone information not currently supported, EET/EEST used.)
- Comment - string, optional
- OvertimeBasePartTargetedTo - string, optional (one of following: "annualabsence", "balance", "bank", "flexiblehours", "flexibleworkhours", "levellingperiodhours", "overtimebalance", "salary", "uncompensated" or "worktimeshorteningleave". Omitting field or giving an incorrect value will use default settings.)
- OvertimeIncrementPartTargetedTo - string, optional (one of following: "annualabsence", "balance", "bank", "flexiblehours", "flexibleworkhours", "levellingperiodhours", "overtimebalance", "salary", "uncompensated" or "worktimeshorteningleave". Omitting field or giving an incorrect value will use default settings.)
- RelatedProjects - related projects and durations as a list of ActivityToProjectRelation elements, see structure below
- WorkIncrements - list of related WorkIncrement elements, see structure below
Return fields:
- ResponseCode
- ResponseString
- UserId - The ID for the user the activity was created for
- Locale - The language currently set for the user
- StartedActivity - The Activity object (see structure below)
- AccrualList - A list of Accrual objects (see structure below)
EndActivity
Ends the specified activity
- CallerAuthentication - authentication object (see structure below)
- ActivityId – int, The id of the activity to be ended
- EndDateTime - Optional, datetime (ISO8601 compatible datetime format e.g. YYYY-MM-DDTHH:MM:SS. Timezone information not currently supported, EET/EEST used.)
- Comment - string, optional
- OvertimeBasePartTargetedTo - string, optional (one of following: "annualabsence", "balance", "bank", "flexiblehours", "flexibleworkhours", "levellingperiodhours", "overtimebalance", "salary", "uncompensated" or "worktimeshorteningleave". Omitting field or giving an incorrect value will use default settings.)
- OvertimeIncrementPartTargetedTo - string, optional (one of following: "annualabsence", "balance", "bank", "flexiblehours", "flexibleworkhours", "levellingperiodhours", "overtimebalance", "salary", "uncompensated" or "worktimeshorteningleave". Omitting field or giving an incorrect value will use default settings.)
- RelatedProjects - related projects and durations as a list of ActivityToProjectRelation elements, see structure below
- WorkIncrements - list of related WorkIncrement elements, see structure below
Return fields:
- ResponseCode
- ResponseString
- UserId - The ID for the user the activity was Ended for
- Locale - The language currently set for the user
- StartedActivity - The Activity object (see structure below)
- AccrualList - A list of Accrual objects (see structure below)
InsertActivities
General purpose web service for inserting work registrations, absences, holidays, travel invoices or any other activity/event details.
- CallerAuthentication - authentication object (see here)
- ActivityList - List of activities to insert
- Activity - One or more instances (see here)
Return fields:
- ResponseCode
- ResponseString
- ActivityList - List of ActivityInserted elements that show the status of the insert
UpdateActivities
Update specified activities identified by their IDs. Returns the IDs and their save status.
This should be used when batch updating activities.
- CallerAuthentication - authentication object (see below)
- ActivityList - List of activities to insert
- Activity - Activity (UpdateActivities)
Return fields:
- ResponseCode
- ResponseString
- ActivityList - List of ActivityInserted elements that show the status of the update
GetActivityTypes
General purpose web service for fetching activity type (event type) details for a customer. Returns a list of ActivityType elements (see common elements below). For fetching activity types suitable for a specific user please see the TerminalLogin web service method
Input parameters:
- CallerAuthentication - authentication object (see structure below)
- FilterByIds - Not yet supported
- FilterByActivityTypeCategoryIds - Not yet supported
- IncludeDeleted(boolean) - Optional, defaults to false
Return fields:
- ResponseCode
- ResponseString
- ActivityTypeList - list of ActivityType elements
GetAccrualValuesForUser
Fetches a user's accrual values for a specified date. The accruals returned are those that are set up to be calculated for the user.
Some of the accruals are set up as default for every customer. These include 'saldo','flexitime','bank'. Customers can also have custom accruals set up. The name of these accrual can be seen by the query results if they are in use. All of the accruals are returned by the call. In addition to the accrual value the method also return the accrual change for that day.
Input parameters:
- CallerAuthentication - authentication object (see structure below)
- UserPersonnelNumber - employee/personnel number of the user you wish to get the accrual values for
- SalaryDate - date when the accrual amounts should be returned in the format YYYY-MM-DD e.g. "2016-12-31". Note: this will return the accrual values as known to the system at the end of any shifts belonging to that day
Return fields:
- ResponseCode
- ResponseString
- AccrualList - list of Accrual elements, see structure below
RunIntegrationRulesetV2
RunIntegrationRuleset
Run rulesets to export salary information, events, projects or HR data from Nepton. Calling this method triggers the run of the integration and returns the contents in the 'output' field.
Rulesets are defined in Worktime -> Administration -> Working community settings -> External Services. Export format needs to be set in the ruleset settings.
Input parameters:
- CallerAuthentication - authentication object (see structure below)
- IntegrationRulesetName - the name of the ruleset that is run
- FilterPeriodBeginDate - start date of the period you wish to export data
- FilterPeriodEndDate - end date of the period you wish to export data
Return fields:
- ResponseCode
- ResponseString
- Output - Contains the integration/export data in the format specified by the export format setting
TerminalLogin
Fetches values set and available for user. These can be used to acknowledge supported values while adding activities for the user.
Input parameters:
- CallerAuthentication - authentication object (see structure below)
Return fields:
- ResponseCode
- ResponseString
- UserId - int
- CustomerId - int
- Username - string
- Firstname - string
- Lastname - string
- Locale - string
- ProjectList - a list of Project elements for the user, see structure below
- ProjectsToContinue - a list of ActivityToProjectRelation elements, see WSDL for more information
- OnGoingActivity - Activity element of ongoing activity, see structure below
- ProjectMandatory - boolean
- WorkIncrementsForUser - a list of WorkIncrementName elements which provides supplements available for the user, see structure below
- DiningIncrements - element contains ActivityId and WorkIncrement for dining activity, see WSDL
- DefaultOvertimeBaseTargetedTo - string (one of following: "annualabsence", "balance", "bank", "flexiblehours", "flexibleworkhours", "levellingperiodhours", "overtimebalance", "salary", "uncompensated" or "worktimeshorteningleave". Omitting field or giving an incorrect value will use default settings.)
- DefaultOvertimeIncrementTargetedTo - string (one of following: "annualabsence", "balance", "bank", "flexiblehours", "flexibleworkhours", "levellingperiodhours", "overtimebalance", "salary", "uncompensated" or "worktimeshorteningleave". Omitting field or giving an incorrect value will use default settings.)
- ActivityTypes - list of ActivityType elements for the user, see structure below
- AccrualList - list of Accrual elements for the user, see structure below
- CurrentDateTimeUTC - datetime
Common elements
CallerAuthentication
User authentication element, only one form of authentication needs to be passed.
- CustomerId (integer) - This is a numeric value identifying the working community. You need to contact Nepton to get a value for it.
- Username (string) - This is the username of the dedicated integration user.
- Password (string) - This is the password of the dedicated integration user.
- Other fields listed in the API description are for internal use only.
ProjectWithExternalIdentifiers (GetProjectsV2)
Project details element under ProjectListV2 element in GetProjectsV2 response.
- ExistingProjectIdentifier - Not in use within GetProjectsV2 response
- Id (integer) - The internal identifier of the project within Nepton
- ExternalIdentifier - List of ProjectIdentifier elements:
- Identifier (string) - The external identifier for the project (identifier on external system)
- IdentifierType (string) - Text "ExternalIdentifier" indicating that the identifier is an external identifier
- Name (string) - The name of the project
- Deleted (boolean) - Indicates whether the project been deleted
- Active (boolean) - Indicates whether the project is currently active
- Code (string) - Project code (Note: this is non-unique so it cannot be relied on as an identifier)
- TypeInternalName (string) - project type (the internal string ID, not the customer specific name/translation for it e.g. "location", "project_work", "unit" etc)
- Description (string) - project description
- StartDate (string) - project start date (YYYY-MM-DD)
- EndDate (string) - project end date
- ParentProjectId (integer) - internal ID of the parent project. Nil for root nodes
- ParentProjectCode - project code of the parent project. Nil for root nodes
- ParentProjectIdentifier - Not in use within GetProjectsV2 response
- Left - left counter of the nested set, read only
- Right - right counter of the nested set, read only
- ChildProjects - Child projects - list of projects as ProjectWithExternalIdentifiers elements for which this project is the parent project
Project
Project details element. Fields are optional unless otherwise stated.
- Id(int) - Internal ID, use for fetching/updating
- Name(string) - mandatory project name
- Deleted(bool) - has the project been deleted
- Code(string) - project code (note: this is now non-unique so cannot be relied on as an identifier)
- TypeInternalName(string) - project type (the internal string ID, not the customer specific name/translation for it e.g. "location", "project_work", "unit" etc)
- Description(string) - project description
- StartDate(string) - project start date (YYYY-MM-DD)
- EndDate(string) - project end date
- ParentProjectId - internal ID of the parent project. Use Either ParentProjectId or ParentProjectCode. Nil for root nodes
- ParentProjectCode - code of the parent project. Use Either ParentProjectId or ParentProjectCode. Nil for root nodes
- Left - left counter of the nested set, read only
- Right - right counter of the nested set, read only
SetVisibleProjectForUser
Project2user visibility element. One project identification and user identification element is required.
- ProjectId(int) - Nepton's internal project ID (unique)
- ProjectCode(string) - Project code (note: project codes are not necessarily unique)
- ProjectIdentifier(Object)
- Identifier(string) If used, this should be a unique ID
- IdentifierType(string) use 'ExternalIdentifier' for ID's external to Nepton
- UserId(int) - Internal user ID
- Username(string) - Username
- PersonnelNumber(string) - Personnel number
- ProjectVisible(bool) - Whether project should be visible or not, required field
Activity (GetActivities)
Activity/Event element. Fields are optional unless otherwise stated.
- Id - int, main Worktime activity ID, read only
- UserId - int, Worktime user ID
- UserFirstName - string, read only
- UserLastName - string, read only
- UserUsername - string, read only
- UserSocialSecurityNumber - string, read only
- ActivityTypeId - int (Available activity types and their id can be found using the GetActivityTypes function)
- ActivityTypeName - string, read only
- ActivityTypeCategoryId - int, read only
- ActivityTypeCategoryName - string, read only
- RelatedActivityId - int, deprecated
- ApproverUserId - int
- ApproverFirstName - string, read only
- ApproverLastName - string, read only
- BeginDateTime - Mandatory, datetime (ISO8601 compatible datetime format e.g. YYYY-MM-DDTHH:MM:SS. Timezone information not currently supported, EET/EEST used.)
- EndDateTime - Optional, datetime (ISO8601 compatible datetime format e.g. YYYY-MM-DDTHH:MM:SS. Timezone information not currently supported, EET/EEST used.)
- ModifiedDateTime - string, read only
- ModifiedByUserId - int, read only
- ModifiedFromIp - string, read only
- Comment - string, optional
- IsClockedEvent - boolean
- IsCreatedWithPinCode - boolean
- OvertimeBasePartTargetedTo - string (one of following: "annualabsence", "balance", "bank", "flexiblehours", "flexibleworkhours", "levellingperiodhours", "overtimebalance", "salary", "uncompensated" or "worktimeshorteningleave". Omitting field or giving an incorrect value will use default settings.)
- OvertimeIncrementPartTargetedTo - string (one of following: "annualabsence", "balance", "bank", "flexiblehours", "flexibleworkhours", "levellingperiodhours", "overtimebalance", "salary", "uncompensated" or "worktimeshorteningleave". Omitting field or giving an incorrect value will use default settings.)
- RelatedProjects - related projects and durations as a list of ActivityToProjectRelation elements, see structure below
- WorkIncrements - list of related WorkIncrement elements, see structure below
- PlannedWorkCalculationUnit - string
- PlannedWorkColor - string
- PlannedWorkUseForWorkDayLengthCalculations - boolean
- PlannedWorkCanBeCancelledUntil - string
- PlannedWorkWorkTimeLimitOffsetStartInMins - int
- PlannedWorkWorkTimeLimitOffsetEndInMins - int
- PlannedWorkActivityGroupPublicInfo - string
- ActivityDetails - activity details, see structure below
- IsDeleted - boolean
Activity (InsertActivities)
Activity/Event element. Fields are optional unless otherwise stated. Person who is receiving the activity is identified by only one of the following:
UserId, UserName, UserSocialSecurityNumber, UserPersonnelNumber
- UserId - int
- UserUsername - string
- UserSocialSecurityNumber - string
- UserPersonnelNumber - string
- ActivityTypeId - int (if not given, assumes type Id 1, work. Available activity type ids can be found using the GetActivityTypes function)
- BeginDateTime - Mandatory, string (YYYY-MM-DD HH:MM:SS)
- EndDateTime - string (YYYY-MM-DD HH:MM:SS)
- ApproverUserId - int, Worktime user ID
- ApproverUsername - string
- ApproverUserSocialSecurityNumber - string
- ApproverUserPersonnelNumber - string
- Comment - string
- IsClockedEvent - boolean (defaults to false)
- IsCreatedWithPinCode - boolean (defaults to false)
- OvertimeBasePartTargetedTo - string (one of following: "annualabsence", "balance", "bank", "flexiblehours", "flexibleworkhours", "levellingperiodhours", "overtimebalance", "salary", "uncompensated" or "worktimeshorteningleave". Omitting field or giving an incorrect value will use default settings.)
- OvertimeIncrementPartTargetedTo - string (one of following: "annualabsence", "balance", "bank", "flexiblehours", "flexibleworkhours", "levellingperiodhours", "overtimebalance", "salary", "uncompensated" or "worktimeshorteningleave". Omitting field or giving an incorrect value will use default settings.)
- RelatedProjects - related projects and durations as a list of ActivityToProjectRelation elements, see structure below
- WorkIncrements - list of related WorkIncrement elements, see structure below
- ActivityDetails - activity details for activities of specific categories, see structure below
ActivityInserted
Element showing the status of activity update or insert.
- Id - int, activity ID
- Success - boolean
- ErrorMessage - string
ActivityType
- Id - int, main Worktime activity type ID, read only
- Name - string, translated name, read only
- ActivityTypeCategoryId - int, read only
- IsDeleted - boolean
ActivityDetails
- AbsenceDetails - Absence details element, see structure below
- PlannedWorkDetails - Planned work details, see structure below
- SickLeaveDetails - Sick leave details element, see structure below
ActivityToProjectRelation
This element provides information about time allocated for a certain project within an activity.
- Id (integer) - the project internal identifier. Use this as the FilterByProjectIds parameter for GetProjectsV2 service call to get more details about the project (e.g. the external identifier of the project)
- Duration - activity duration in minutes for this project
- Name - the name of the project
- Code - the internal code for the project
AbsenceDetails
- CompensationTypeId - int, compensation type id: 1 = paid, 2 = unpaid, 3 = reduced salary
- CompensationTypeName - string, translated compensation type name
- EarnsVacationDays - boolean, whether vacation days are earned from absence
- AbsenceTypeId - int, absence type id. Check activity editing popup for absence types, as some can be customer specific
- AbsenceTypeName - string, translated absence type name
PlannedWorkDetails
Details related to workshift planning.
- PlannedWorkCalculationUnit - string - the code of the location for the planned work
- PlannedWorkColor - string - the HTML colour code by which the planned work for the location are shown in planning
- PlannedWorkUseForWorkDayLengthCalculations - boolean - Does a scheduled workshift override the work day length settings? Effective setting value from Work shifts -> Planned event types that override work day length -> Scheduled workshift.
- PlannedWorkCanBeCancelledUntil - string - yyyy-MM-dd HH:mm:ss string representation of the date and time after which the planned work cannot be cancelled by the employee
- PlannedWorkWorkTimeLimitOffsetStartInMins - int -
Indicates if the shift should set the starting work time limit for the day, and if so, any offset from the activity's start time that should be applied. Deprecated - this information is only provided for old information only and if not given here, the effective setting under Work shifts -> Planned event type permitted work time start -> Scheduled workshift is used
- PlannedWorkWorkTimeLimitOffsetEndInMins - int -
Indicates if the shift should set the ending work time limit for the day, and if so, any offset from the activity's end time that should be applied. Deprecated - this information is only provided for old information only and if not given here, the effective setting under Work shifts -> Planned event type permitted work time end -> Scheduled workshift is used
- AssumedLunchInMinutes - unsigned short - number in minutes of the assumed lunch in the activity. Assumed lunch is used when lunch time not recorded or it is recorded shorter than it should last at minimum in the activity.
- PlannedWorkActivityGroupPublicInfo - string - Publicly shown information entered by the planner in the work shift planning
SickLeaveDetails
- CompensationTypeId - int, compensation type id: 1 = paid, 2 = unpaid, 3 = reduced salary
- CompensationTypeName - string, translated compensation type name
- EarnsVacationDays - boolean, whether vacation days are earned from absence
- SickLeaveTypeId - int, sick leave type: 1 = Sick, 2 = Child sick, 3 = Work accident at work, 4 = Work accident while commuting, 5 = Work accident at home
- SickLeaveTypeName - string, translated sick leave type name
- MedicalCertificateGiven - boolean
- SupervisorsPermission - boolean
- ReasonCode - string, sick leave reason code
Accrual
- InternalName - internal string ID of the accrual
- Name - translated/customer name of the accrual
- Amount - accrual amount
- ChangeAmount - amount the accrual has changed from the previous day's value (not returned if there is no change)
WorkIncrement
Contains information about supplement for the related request. Both fields are mandatory. Index and unit used for the supplement can be retrieved for a user with TerminalLogin methods WorkIncrementNamesList which contains a list of WorkIncrementName elements describing the set values for the supplement, see description of WorkIncrementName below.
- Index - integer, describes the index of the supplement.
- Value - decimal, describes the value of the supplement. Value in minutes, as units or decimal, whichever is set as UsedUnit for the supplement as retrieved by WorkIncrementName.
WorkIncrementName
Contains information about supplement for the related request.
- Index - integer, describes the index of the supplement. Can be used for mapping the correct supplement for InsertActivities method's WorkIncrement element.
- Name - string, name of supplement
- UsedUnit - string, describes the used unit of the supplement. Value in minutes, as units or decimal.
Response codes
These are the response codes that can be returned in the ResponseCode field. See Handling error responses for more details.
- 1000: All clear. No errors.
- 1001: Authentication failed. Please check that the CallerAuthentication credentials provided are correct and the CustomerId is present.
- 1002: The event was not found with the identifier given.
- 1003: Person was not found with the identifier given.
- 1004: Project was not found with the identifier given.
- 1005: All settings required were not provided in the request.
- 1006: Setting was not valid because of a missing identifier.
- 1007: Setting was invalid.
- 1008: Processing of the current setting failed.
- 1009: Project was invalid.
- 1010: Failure during database communication.
- 1011: Delete operation failed in database.
- 1012: Parameters were invalid.
- 1013: Target dates were not found.
- 1014: Setting was not recognised or is not supported.
- 1015: No permission to access or modify the requested object.
- 1016: Parameter provided is not supported.
- 1017: Requested functionality is not supported by Nepton service.
- 1018: There were too many failed login attempts by person or from IP. Login is temporarily locked.
- 1019: One or more of the items listed failed processing - see Handling error responses.
- 1020: Login failed because the account of the person is disabled.
- 999: An unexpected error occurred. The ResponseString of the message may provide more details. Please check that all the parameters given were correct. This may be also be due to an internal error in Nepton. You may need to report this error to Nepton.
Handling error responses
When updating data to Nepton it is important to check that the ResponseCode is 1000. If the ResponseCode is anything but 1000, there is something that was not updated correctly. See the code explanations above. The ResponseString may contain general information, but to get information about where the problem exactly occurred, you need to check the details of the response.
For example, InsertActivities request returns a list ActivityInserted elements matching the Activity elements in the request with a Success field with value true for each field that was successfully added and false for activities with any problems. Then the ErrorMessage element will contain the details of an individual problem related to that field.
It is the responsibility of the calling software to properly display or log the error messages related to individual messages. The error messages might not be found in Nepton later on.