You are viewing an old version of this page. View the current version.
Compare with Current
View Page History
« Previous
Version 10
Next »
Overview
This web service saves changes to time cards. This service should be used to save changes to existing time cards, to insert new time cards or to delete time cards. It is also capable of saving estimates (remaining minutes), saving task notes and performing a submit operation.
The service is written such that a failure to save or delete a time card or time off card, or to save an estimate or task note, will not prevent the saving of other changes, however any failure to save will prevent the submit from occurring, even if the service requests it. Individual errors processing time cards, time off cards, estimates and task notes are reported in the response.
- PwsSaveTimeCards
- serviceRequest: PwsSaveTimeCardsRq
Request Elements
Element | Data Type | Required? | Default | Description | Sample Data |
---|
RequestId | Int32 | No |
| Click here for more information | 1 |
SessionTicket | String | Yes |
| Click here for more information | AUtZcJgtdfVGhgjNekiP9w== |
AdministratorComments | String | No |
| Administrator comments for entering time on behalf of others | Web Service Testing |
DeleteTimeCards | PwsTimeCardRef[] | No |
| The identity of the time card(s) that will be deleted |
|
DeleteTimeOffCards | PwsTimeCardRef[] | No |
| The identity of the time off time card(s) that will be deleted |
|
EndDate | DateTime | Yes |
| The EndDate defines the last work or time off date that affected time cards can be logged against. Only time cards with work or time off dates on or prior to this EndDate will be included when the web service is executed. | 2018-03-31T00:00:00.000Z |
Estimates | PwsEstimate[] | No |
| The estimate to complete for a given task. This is only applicable for time cards logged against a project with detailed task management. |
|
InsertIfNotFoundOnUpdateFlag | Boolean | No | false | If set to 'true', the specified time card or time off time card details will be inserted as a new time card or time off time card if it does not currently exist | true |
ResourceIdentity | PwsResourceRef | No - unless inserting a new time card |
| The identity of the resource associated with the time card or time off time card |
|
SaveTimeCards | PwsTimeCardDetail[] | No - unless inserting a new time card |
| The details of the time card to be saved / updated |
|
SaveTimeOffCards | PwsTimeOffCardDetail[] | No - unless inserting a new time off time card |
| The details of the time off time card to be saved / updated |
|
SendNotificationEmailFlag | Boolean | No | false | If set to 'true', a notification email will be sent to the resource associated with the time card. This is applicable only when entering time on behalf of others. | false |
StartDate | DateTime | Yes |
| The StartDate defines the first work or time off date that affected time cards can be logged against. Only time cards with work or time off dates on or after this StartDate will be included when the web service is executed. | 2018-03-09T00:00:00.000Z |
SubmitFlag | Boolean | No | false | If set to 'true', a submit operation will be performed as part of this request. To submit a specific time card or time off card, use SubmitTimeCardIdentity. | true |
Tasks | PwsProjectTaskNote[] | No |
| Notes to be saved with the task associated with the time card |
|
SubmitSavedCardsOnlyFlag | Boolean | No | false | If set to 'true', draft time cards associated with the provided resource identity will be submitted | true |
SubmitTimeCardIdentity | PwsTimeCardRef | No |
| The specific time card(s) to be submitted, see SubmitFlag |
|
PreserveTimeCardStatusFlag - deprecated | Boolean | *** deprecated *** |
| *** deprecated ***
|
|
Request Usage Example(s)
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:pws="http://projectorpsa.com/PwsProjectorServices/" xmlns:req="http://projectorpsa.com/DataContracts/Requests/" xmlns:tim="http://projectorpsa.com/DataContracts/Shared/TimeAndCost/" xmlns:com="http://projectorpsa.com/DataContracts/Shared/Common/">
<soapenv:Header/>
<soapenv:Body>
<pws:PwsSaveTimeCards>
<pws:serviceRequest>
<req:RequestId>1</req:RequestId>
<req:SessionTicket>AUtZcJgtdfVGhgjNekiP9w==</req:SessionTicket>
<tim:AdministratorComments>Web Service Testing</tim:AdministratorComments>
<tim:EndDate>2018-03-31T00:00:00.000Z</tim:EndDate>
<tim:Estimates>
<tim:PwsEstimate>
<tim:AsOfDate>2018-03-09T00:00:00.000Z</tim:AsOfDate>
<tim:CompletedFlag>false</tim:CompletedFlag>
<tim:ProjectTaskRoleIdentity>
<com:ProjectRoleIdentity>
<com:ProjectRoleUid>1152921504609525049</com:ProjectRoleUid>
</com:ProjectRoleIdentity>
<com:ProjectTaskIdentity>
<com:ProjectTaskUid>1152921504608637344</com:ProjectTaskUid>
</com:ProjectTaskIdentity>
<com:ProjectTaskRoleUid>1152921504608549426</com:ProjectTaskRoleUid>
</tim:ProjectTaskRoleIdentity>
<tim:RemainingMinutes>360</tim:RemainingMinutes>
</tim:PwsEstimate>
</tim:Estimates>
<tim:InsertIfNotFoundOnUpdateFlag>true</tim:InsertIfNotFoundOnUpdateFlag>
<tim:ResourceIdentity>
<com:ResourceReferenceSystemId>E123</com:ResourceReferenceSystemId>
</tim:ResourceIdentity>
<tim:SaveTimeCards>
<tim:PwsTimecardDetail>
<com:TimecardType>T</com:TimecardType>
<tim:DescriptionClearFlag>false</tim:DescriptionClearFlag>
<tim:Status>Submitted</tim:Status>
<tim:WorkDate>2018-03-09T00:00:00.000Z</tim:WorkDate>
<tim:WorkMinutes>60</tim:WorkMinutes>
<tim:CardStatus>Submitted</tim:CardStatus>
<tim:LocationClearFlag>false</tim:LocationClearFlag>
<tim:LocationIdentity>
<com:LocationName>USA</com:LocationName>
</tim:LocationIdentity>
<tim:ProjectIdentity>
<com:ProjectCode>P001396-001</com:ProjectCode>
</tim:ProjectIdentity>
<tim:ProjectRateTypeIdentity>
<com:ProjectRateTypeUid>1152921504607370468</com:ProjectRateTypeUid>
</tim:ProjectRateTypeIdentity>
<tim:ProjectTaskIdentity>
<com:ProjectTaskUid>1152921504608637344</com:ProjectTaskUid>
</tim:ProjectTaskIdentity>
<tim:RoleClearFlag>false</tim:RoleClearFlag>
<tim:RoleIdentity>
<com:ProjectRoleUid>1152921504609525049</com:ProjectRoleUid>
</tim:RoleIdentity>
<tim:Udf1ClearFlag>false</tim:Udf1ClearFlag>
<tim:Udf2ClearFlag>false</tim:Udf2ClearFlag>
<tim:ExternalGroupingIdentifierClearFlag>false</tim:ExternalGroupingIdentifierClearFlag>
</tim:PwsTimecardDetail>
</tim:SaveTimeCards>
<tim:SendNotificationEmailFlag>false</tim:SendNotificationEmailFlag>
<tim:StartDate>2018-03-09T00:00:00.000Z</tim:StartDate>
<tim:SubmitFlag>true</tim:SubmitFlag>
<tim:Tasks>
<tim:PwsProjectTaskNote>
<tim:Notes>Added via the web service</tim:Notes>
<tim:ProjectTaskIdentity>
<com:ProjectTaskUid>1152921504608637344</com:ProjectTaskUid>
</tim:ProjectTaskIdentity>
<tim:EmailPmTeamFlag>false</tim:EmailPmTeamFlag>
</tim:PwsProjectTaskNote>
</tim:Tasks>
<tim:SubmitSavedCardsOnlyFlag>false</tim:SubmitSavedCardsOnlyFlag>
<tim:PreserveTimeCardStatusFlag>true</tim:PreserveTimeCardStatusFlag>
</pws:serviceRequest>
</pws:PwsSaveTimeCards>
</soapenv:Body>
</soapenv:Envelope>
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:pws="http://projectorpsa.com/PwsProjectorServices/" xmlns:req="http://projectorpsa.com/DataContracts/Requests/" xmlns:tim="http://projectorpsa.com/DataContracts/Shared/TimeAndCost/" xmlns:com="http://projectorpsa.com/DataContracts/Shared/Common/">
<soapenv:Header/>
<soapenv:Body>
<pws:PwsSaveTimeCards>
<pws:serviceRequest>
<req:RequestId>1</req:RequestId>
<req:SessionTicket>AUtZcJgtdfVGhgjNekiP9w==</req:SessionTicket>
<tim:AdministratorComments>Web Service Testing</tim:AdministratorComments>
<tim:EndDate>2018-03-31T00:00:00.000Z</tim:EndDate>
<tim:InsertIfNotFoundOnUpdateFlag>true</tim:InsertIfNotFoundOnUpdateFlag>
<tim:ResourceIdentity>
<com:ResourceReferenceSystemId>E123</com:ResourceReferenceSystemId>
</tim:ResourceIdentity>
<tim:SaveTimeOffCards>
<tim:PwsTimeOffCardDetail>
<tim:Description>Vacation Day</tim:Description>
<tim:DescriptionClearFlag>false</tim:DescriptionClearFlag>
<tim:Status>Draft</tim:Status>
<tim:WorkDate>2018-03-21T00:00:00.000Z</tim:WorkDate>
<tim:WorkMinutes>480</tim:WorkMinutes>
<tim:CardStatus>D</tim:CardStatus>
<tim:TimeOffReasonIdentity>
<com:TimeOffReasonName>Vacation</com:TimeOffReasonName>
</tim:TimeOffReasonIdentity>
</tim:PwsTimeOffCardDetail>
</tim:SaveTimeOffCards>
<tim:SendNotificationEmailFlag>false</tim:SendNotificationEmailFlag>
<tim:StartDate>2018-03-09T00:00:00.000Z</tim:StartDate>
<tim:SubmitFlag>true</tim:SubmitFlag>
<tim:Tasks>
<tim:PwsProjectTaskNote>
<tim:Notes>Added via the web service</tim:Notes>
<tim:ProjectTaskIdentity>
<com:ProjectTaskUid>1152921504608637344</com:ProjectTaskUid>
</tim:ProjectTaskIdentity>
<tim:EmailPmTeamFlag>false</tim:EmailPmTeamFlag>
</tim:PwsProjectTaskNote>
</tim:Tasks>
<tim:SubmitSavedCardsOnlyFlag>false</tim:SubmitSavedCardsOnlyFlag>
</pws:serviceRequest>
</pws:PwsSaveTimeCards>
</soapenv:Body>
</soapenv:Envelope>
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:pws="http://projectorpsa.com/PwsProjectorServices/" xmlns:req="http://projectorpsa.com/DataContracts/Requests/" xmlns:tim="http://projectorpsa.com/DataContracts/Shared/TimeAndCost/" xmlns:com="http://projectorpsa.com/DataContracts/Shared/Common/">
<soapenv:Header/>
<soapenv:Body>
<pws:PwsSaveTimeCards>
<pws:serviceRequest>
<req:RequestId>1</req:RequestId>
<req:SessionTicket>AUtZcJgtdfVGhgjNekiP9w==</req:SessionTicket>
<tim:AdministratorComments>Web Service Testing</tim:AdministratorComments>
<tim:DeleteTimeCards>
<com:PwsTimecardRef>
<com:TimecardUid>1152921504646141266</com:TimecardUid>
</com:PwsTimecardRef>
</tim:DeleteTimeCards>
<tim:EndDate>2018-03-31T00:00:00.000Z</tim:EndDate>
<tim:ResourceIdentity>
<com:ResourceReferenceSystemId>E123</com:ResourceReferenceSystemId>
</tim:ResourceIdentity>
<tim:SendNotificationEmailFlag>false</tim:SendNotificationEmailFlag>
<tim:StartDate>2018-03-09T00:00:00.000Z</tim:StartDate>
<tim:SubmitFlag>true</tim:SubmitFlag>
</pws:serviceRequest>
</pws:PwsSaveTimeCards>
</soapenv:Body>
</soapenv:Envelope>
- PwsSaveTimeCardsResponse
- PwsSaveTimeCardsResult: PwsSaveTimeCardsRs
Response Elements
Response Usage Example(s)
<s:Envelope xmlns:s="http://schemas.xmlsoap.org/soap/envelope/">
<s:Body>
<PwsSaveTimeCardsResponse xmlns="http://projectorpsa.com/PwsProjectorServices/">
<PwsSaveTimeCardsResult xmlns:a="http://projectorpsa.com/DataContracts/Shared/TimeAndCost/" xmlns:i="http://www.w3.org/2001/XMLSchema-instance">
<Messages xmlns="http://projectorpsa.com/CommonServices/" xmlns:b="http://projectorpsa.com/DataContracts/Shared/Common/"/>
<ResponseId xmlns="http://projectorpsa.com/CommonServices/">1</ResponseId>
<Status xmlns="http://projectorpsa.com/CommonServices/">Ok</Status>
<ServerTimestampUtc xmlns="http://projectorpsa.com/CommonServices/">2018-03-09T22:22:30.2317159Z</ServerTimestampUtc>
<a:EstimateResults>
<a:PwsSaveEstimateResult>
<a:ErrorDetail i:nil="true" xmlns:b="http://projectorpsa.com/DataContracts/Shared/Common/"/>
<a:Estimates>
<a:PwsProjectTaskRoleRemaining>
<a:CompletedFlag>false</a:CompletedFlag>
<a:RemainingAsOfDate>2018-03-09T00:00:00Z</a:RemainingAsOfDate>
<a:RemainingMinutes>360</a:RemainingMinutes>
</a:PwsProjectTaskRoleRemaining>
</a:Estimates>
<a:ReferenceId i:nil="true"/>
</a:PwsSaveEstimateResult>
</a:EstimateResults>
<a:Locations xmlns:b="http://projectorpsa.com/DataContracts/Shared/Common/">
<b:PwsLocationSummary>
<b:LocationId i:nil="true"/>
<b:LocationName>USA</b:LocationName>
<b:LocationUid>1152921504606855985</b:LocationUid>
<b:CurrencyIdentity>
<b:CurrencyCode>USD</b:CurrencyCode>
<b:CurrencyId i:nil="true"/>
<b:CurrencyUid>1152921504606851838</b:CurrencyUid>
</b:CurrencyIdentity>
<b:InactiveFlag>false</b:InactiveFlag>
<b:MileageUom>M</b:MileageUom>
<b:OpsCurrencyIdentity>
<b:OpsCurrencyCode>USD</b:OpsCurrencyCode>
<b:OpsCurrencyId i:nil="true"/>
</b:OpsCurrencyIdentity>
<b:EnabledForCostcardsFlag>true</b:EnabledForCostcardsFlag>
<b:EnabledForProjectsFlag>true</b:EnabledForProjectsFlag>
<b:EnabledForResourcesFlag>true</b:EnabledForResourcesFlag>
<b:EnabledForTimecardsFlag>true</b:EnabledForTimecardsFlag>
</b:PwsLocationSummary>
</a:Locations>
<a:SubmittedFlag>true</a:SubmittedFlag>
<a:TaskNoteResults/>
<a:TimeOffCardResults/>
<a:TimecardResults>
<a:PwsSaveTimecardResult>
<a:ErrorDetail i:nil="true" xmlns:b="http://projectorpsa.com/DataContracts/Shared/Common/"/>
<a:ReferenceId i:nil="true"/>
<a:TimeCard>
<ReferenceId i:nil="true" xmlns="http://projectorpsa.com/DataContracts/Shared/Common/"/>
<TimecardId i:nil="true" xmlns="http://projectorpsa.com/DataContracts/Shared/Common/"/>
<TimecardType xmlns="http://projectorpsa.com/DataContracts/Shared/Common/">T</TimecardType>
<TimecardUid xmlns="http://projectorpsa.com/DataContracts/Shared/Common/">1152921504646141267</TimecardUid>
<a:Description i:nil="true"/>
<a:DescriptionClearFlag>false</a:DescriptionClearFlag>
<a:RejectedByUser i:nil="true" xmlns:b="http://projectorpsa.com/DataContracts/Shared/Common/"/>
<a:RejectedReason i:nil="true"/>
<a:RejectedTimestamp i:nil="true"/>
<a:Status>Submitted</a:Status>
<a:WorkDate>2018-03-09T00:00:00Z</a:WorkDate>
<a:WorkMinutes>60</a:WorkMinutes>
<a:Timestamp>AAAAAA64Nro=</a:Timestamp>
<a:CardStatus>S</a:CardStatus>
<a:LocationClearFlag>false</a:LocationClearFlag>
<a:LocationIdentity xmlns:b="http://projectorpsa.com/DataContracts/Shared/Common/">
<b:LocationId i:nil="true"/>
<b:LocationName>USA</b:LocationName>
<b:LocationUid>1152921504606855985</b:LocationUid>
</a:LocationIdentity>
<a:ProjectIdentity xmlns:b="http://projectorpsa.com/DataContracts/Shared/Common/">
<b:ProjectCode>P001396-001</b:ProjectCode>
<b:ProjectId i:nil="true"/>
<b:ProjectUid>1152921504607412210</b:ProjectUid>
</a:ProjectIdentity>
<a:ProjectRateTypeIdentity xmlns:b="http://projectorpsa.com/DataContracts/Shared/Common/">
<b:ExternalSystemIdentifier i:nil="true"/>
<b:ProjectRateTypeId i:nil="true"/>
<b:ProjectRateTypeUid>1152921504607370468</b:ProjectRateTypeUid>
</a:ProjectRateTypeIdentity>
<a:ProjectTaskIdentity xmlns:b="http://projectorpsa.com/DataContracts/Shared/Common/">
<b:ExternalSystemIdentifier i:nil="true"/>
<b:ProjectTaskId i:nil="true"/>
<b:ProjectTaskUid>1152921504608637344</b:ProjectTaskUid>
</a:ProjectTaskIdentity>
<a:RoleClearFlag>false</a:RoleClearFlag>
<a:RoleIdentity xmlns:b="http://projectorpsa.com/DataContracts/Shared/Common/">
<b:ExternalSystemIdentifier i:nil="true"/>
<b:ProjectRoleId i:nil="true"/>
<b:ProjectRoleUid>1152921504609525049</b:ProjectRoleUid>
</a:RoleIdentity>
<a:Udf1 xmlns:b="http://projectorpsa.com/DataContracts/Shared/Common/">
<b:UdfId i:nil="true"/>
<b:UdfName>TC-Jira</b:UdfName>
<b:UdfUid>1152921504606857618</b:UdfUid>
<b:BooleanValue i:nil="true"/>
<b:DataType>P</b:DataType>
<b:DateValue i:nil="true"/>
<b:IntegerValue i:nil="true"/>
<b:ResourceIdentityValue i:nil="true"/>
<b:TextValue i:nil="true"/>
<b:UdfTreatment>A</b:UdfTreatment>
<b:StoplightValues/>
<b:NumericValue i:nil="true"/>
<b:RelationValue i:nil="true"/>
</a:Udf1>
<a:Udf1ClearFlag>false</a:Udf1ClearFlag>
<a:Udf2 xmlns:b="http://projectorpsa.com/DataContracts/Shared/Common/">
<b:UdfId i:nil="true"/>
<b:UdfName>TC-Zendesk</b:UdfName>
<b:UdfUid>1152921504606857619</b:UdfUid>
<b:BooleanValue i:nil="true"/>
<b:DataType>P</b:DataType>
<b:DateValue i:nil="true"/>
<b:IntegerValue i:nil="true"/>
<b:ResourceIdentityValue i:nil="true"/>
<b:TextValue i:nil="true"/>
<b:UdfTreatment>A</b:UdfTreatment>
<b:StoplightValues/>
<b:NumericValue i:nil="true"/>
<b:RelationValue i:nil="true"/>
</a:Udf2>
<a:Udf2ClearFlag>false</a:Udf2ClearFlag>
<a:ExternalGroupingIdentifier i:nil="true"/>
<a:ExternalGroupingIdentifierClearFlag>false</a:ExternalGroupingIdentifierClearFlag>
</a:TimeCard>
</a:PwsSaveTimecardResult>
</a:TimecardResults>
</PwsSaveTimeCardsResult>
</PwsSaveTimeCardsResponse>
</s:Body>
</s:Envelope>
<s:Envelope xmlns:s="http://schemas.xmlsoap.org/soap/envelope/">
<s:Body>
<PwsSaveTimeCardsResponse xmlns="http://projectorpsa.com/PwsProjectorServices/">
<PwsSaveTimeCardsResult xmlns:a="http://projectorpsa.com/DataContracts/Shared/TimeAndCost/" xmlns:i="http://www.w3.org/2001/XMLSchema-instance">
<Messages xmlns="http://projectorpsa.com/CommonServices/" xmlns:b="http://projectorpsa.com/DataContracts/Shared/Common/"/>
<ResponseId xmlns="http://projectorpsa.com/CommonServices/">1</ResponseId>
<Status xmlns="http://projectorpsa.com/CommonServices/">Ok</Status>
<ServerTimestampUtc xmlns="http://projectorpsa.com/CommonServices/">2018-03-09T22:19:31.3446007Z</ServerTimestampUtc>
<a:EstimateResults/>
<a:Locations xmlns:b="http://projectorpsa.com/DataContracts/Shared/Common/"/>
<a:SubmittedFlag>true</a:SubmittedFlag>
<a:TaskNoteResults/>
<a:TimeOffCardResults/>
<a:TimecardResults/>
</PwsSaveTimeCardsResult>
</PwsSaveTimeCardsResponse>
</s:Body>
</s:Envelope>
PwsSaveTimeCards - Common Errors and Warnings
ErrorNumber | ErrorCode | ErrorText |
---|
19093 | UnexpectedTimeCardType | Unexpected value for TimeCardType. Valid values are T or R. |
20001 | TimeCardStartDateRequired | The range start date must be specified. |
20002 | TimeCardEndDateRequired | The range end date must be specified. |
20003 | InvalidValueForTimeCardStartDate | The specified start date must be expressed as midnight UTC on the desired date. |
20004 | InvalidValueForTimeCardEndDate | The specified end date must be expressed as midnight UTC on the desired date. |
20028 | TimeCardErrors | One or more time cards or time off cards could not be saved. |
20033 | TimeCardIdentitiesRequired | One or more time card identities must be specified. |
20037 | TimeCardSplitPercentOutOfRange | The specified split percentage is out of range. Please specify a value greater than 0% and less than 100%. |
20050 | InvalidValueForTimeCardApprovalWorkflowStatus | The specified value for time card approval workflow status is invalid. Valid values are D for Draft, R for Rejected, S for Submitted, A for Approved, I for Invoiced (draft), B for Billed and M for Missing. Values of I, B and M are only valid when querying for existing data. |
20051 | InvalidValueForTimeCardType | The specified value for time card type is invalid. Valid values are T for Time Card and R for Reported Time Off. |
64161 | TimeCardResourceMismatch | The specified resource is not the same resource as is currently associated with the time card. |
64182 | TimecardHasBeenChanged | Time card has been changed by another user. |
64220 | InvalidTimeCard | A specified time card identity was incomplete. Each time card identity must specify either a time card id or time card uid. |
64222 | SpecifiedTimeCardDoesNotExist | The specified time card does not exist. |
64237 | UnexpectedErrorSavingTimeCard | There was an unexpected error while trying to save a time card. |
64239 | TimeCardWorkDateRequired | Work date is required for new time cards. |
64240 | InvalidValueForTimeCardWorkMinutes | The value specified for work minutes must be non-negative. |
64244 | UnableToUpdateTimeCard | This time card could not be updated. |
64294 | UnexpectedTimeCardUdfValue | Unexpected UDF value provided (UDF metadata may have changed) |
64295 | TimeCardWorkDateOutOfRange | Specified work date outside of supported date range. |
64299 | OneOrMoreTimeCardsNotFound | One or more time cards does not exist. |
64314 | CannotChangeStatusOfFroTimecards | Cannot change the status of for reporting only time cards. |
64318 | CannotChangeSubmittedTimecardsApClosed | Cannot save changes to submitted time card because the accounting period is closed for time. |
64332 | TimeCardHasBeenDeleted | Referenced time card is deleted. |
64333 | TimeOffCardHasBeenDeleted | Referenced time off card is deleted. |
64334 | SaveCardTimeCardHasBeenDeleted | Referenced time card is deleted. |
64335 | NoPermissionToSaveTimeCard | You do not have permission to save time card. |
64338 | SplitCardTimeCardHasBeenDeleted | Referenced time card is deleted. |
64340 | SubmitCardTimeCardHasBeenDeleted | Referenced time card is deleted. |