PwsGetExpenseDocumentApprovers

Overview


This web service retrieves a list of expense document approvers (PwsApprovalSet). The service can be invoked with or without a list of projects.

If this service is invoked with a list of projects (PwsProjectRef), the caller must also specify either an expense document (PwsExpenseDocumentRef) or a document type and a resource (PwsResourceRef). The specified document type, or the type of the specified expense document, must be expense report ('E'). If both an expense document and a resource are specified, they must be consistent (the resource specified must match the resource associated with the specified expense report). Disbursing cost center is not required, but if both an expense document and a disbursing cost center (PwsCostCenterRef) are specified, they must also be consistent.

If no projects are specified, an expense document is required. A document type, disbursing cost center or resource are not required in this case, but if they are specified, they must be consistent with the specified expense document. A resource may only be specified for expense report expense documents.

The list of approvers returned depends on the approval type:

  • For project-based expense approval, the approvers consist of some contingent of the PM team (project manager, engagement manager, members of project management team), or a specific individual as determined by the expense approver type for the project in question,
  • For resource-based expense approval (also determined by expense approver type setting), the list consists of the designated expense approver for the resource in question, and all users with expense approval permission in the disbursing cost center.

Request Format


PwsGetExpenseDocumentApprovers Request

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.

AXSG6rN0j9gBkWbkRw6OpQ==

DisbursingCostCenterIdentity

PwsCostCenterRef

No


The caller may specify a disbursing cost center identity to retrieve a list of users that can approve expense documents associated with the disbursing cost center.


ExpenseDocumentIdentity

PwsExpenseDocumentRef

If ProjectIdentities not specified


The caller may specify an expense document to retrieve a a list of users that can approve expenses on the expense document.


ProjectIdentities

PwsProjectRef[]

No


The caller may specify one or more projects to retrieve a a list of users that can approve expense documents associated with the project(s)


ResourceIdentity

PwsResourceRef

If ProjectIdentifies is specified and ExpenseDocumentIdentity is not specified


The caller may specify a resource to retrieve a list of users that can approve expense documents associated with the resource. This can only be specified if the document type is an expense report (i.e. "E").


DocumentType

String

If ProjectIdentifies is specified and ExpenseDocumentIdentity is not specified


The expense document type:

"E" for Expense Report

"C" for Subcontractor Invoice

"V" for Vendor Invoice

"S" for Soft Cost Batch 

E

Request Usage Example(s)


Example 01
<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:PwsGetExpenseDocumentApprovers>
         <pws:serviceRequest>
            <req:RequestId>1</req:RequestId>
            <req:SessionTicket>AXSG6rN0j9gBkWbkRw6OpQ==</req:SessionTicket>
            <tim:ExpenseDocumentIdentity>
               <com:DocumentNumber>ER00719</com:DocumentNumber>
            </tim:ExpenseDocumentIdentity>
            <tim:ProjectIdentities>
               <com:PwsProjectRef>
                  <com:ProjectCode>P001407-001</com:ProjectCode>
               </com:PwsProjectRef>
            </tim:ProjectIdentities>
            <tim:DocumentType>E</tim:DocumentType>
         </pws:serviceRequest>
      </pws:PwsGetExpenseDocumentApprovers>
   </soapenv:Body>
</soapenv:Envelope>

Response Format


PwsGetExpenseDocumentApprovers Response

Response Elements


Element

Data Type

Description

Sample Data

Messages

PwsMessage[]

The web service response status and message. Click here for more information. 


ResponseId

Int32

Click here for more information


Status

RequestStatus

Click here for more information


ServerTimestampUtc

DateTime

Click here for more information


ApprovalSets

PwsApprovalSet[]

The complete set of unique identifying information about an expense document approver


Response Usage Example(s)


Example 01
<s:Envelope xmlns:s="http://schemas.xmlsoap.org/soap/envelope/">
   <s:Body>
      <PwsGetExpenseDocumentApproversResponse xmlns="http://projectorpsa.com/PwsProjectorServices/">
         <PwsGetExpenseDocumentApproversResult 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-02-26T20:31:34.7996322Z</ServerTimestampUtc>
            <a:ApprovalSets>
               <a:PwsApprovalSet>
                  <a:Approvers xmlns:b="http://projectorpsa.com/DataContracts/Shared/Common/">
                     <b:PwsUserSummary>
                        <b:UserDisplayName>Jack Spratt</b:UserDisplayName>
                        <b:UserId i:nil="true"/>
                        <b:UserReferenceSystemId>E123</b:UserReferenceSystemId>
                        <b:UserUid>1152921504607112369</b:UserUid>
                        <b:EmailAddress>jack@revcorp.bb</b:EmailAddress>
                        <b:FirstName>Jack</b:FirstName>
                        <b:LastName>Spratt</b:LastName>
                        <b:MiddleName i:nil="true"/>
                     </b:PwsUserSummary>
                     <b:PwsUserSummary>
                        <b:UserDisplayName>Katrina Barden</b:UserDisplayName>
                        <b:UserId i:nil="true"/>
                        <b:UserReferenceSystemId>EX (USA) - 01</b:UserReferenceSystemId>
                        <b:UserUid>1152921504607062079</b:UserUid>
                        <b:EmailAddress>katrina@revcorp.bb</b:EmailAddress>
                        <b:FirstName>Katrina</b:FirstName>
                        <b:LastName>Barden</b:LastName>
                        <b:MiddleName i:nil="true"/>
                     </b:PwsUserSummary>
                     <b:PwsUserSummary>
                        <b:UserDisplayName>Mike Martin</b:UserDisplayName>
                        <b:UserId i:nil="true"/>
                        <b:UserReferenceSystemId>E100</b:UserReferenceSystemId>
                        <b:UserUid>1152921504607112371</b:UserUid>
                        <b:EmailAddress>mike@revcorp.bb</b:EmailAddress>
                        <b:FirstName>Mike</b:FirstName>
                        <b:LastName>Martin</b:LastName>
                        <b:MiddleName i:nil="true"/>
                     </b:PwsUserSummary>
                  </a:Approvers>
                  <a:Projects xmlns:b="http://projectorpsa.com/DataContracts/Shared/Common/">
                     <b:PwsProjectSummary>
                        <b:ProjectCode>P001407-001</b:ProjectCode>
                        <b:ProjectId i:nil="true"/>
                        <b:ProjectUid>1152921504607413030</b:ProjectUid>
                        <b:EngagementIdentity>
                           <b:EngagementCode>P001407</b:EngagementCode>
                           <b:EngagementId i:nil="true"/>
                           <b:EngagementUid>1152921504607325242</b:EngagementUid>
                        </b:EngagementIdentity>
                        <b:ProjectName>Project A</b:ProjectName>
                     </b:PwsProjectSummary>
                  </a:Projects>
               </a:PwsApprovalSet>
            </a:ApprovalSets>
         </PwsGetExpenseDocumentApproversResult>
      </PwsGetExpenseDocumentApproversResponse>
   </s:Body>
</s:Envelope>


PwsGetExpenseDocumentApprovers - Common Errors and Warnings

ErrorNumber

ErrorCode

ErrorText

19021ExpenseDocumentOrDisbursingCostCenterRequiredMust specify either an expense document or a disbursing cost center for retrieving approvers.
65686CanOnlyRetrieveApproversForExistingExpenseReportsApprovers can only be retrieved for existing non-ER expense documents.
65818ResourceMismatchSelectingApproversThe specified resource does not match the resource associated with the specified expense document.
65819ResourceMayOnlyBeSpecifiedForExpenseReportsA resource identity may only be specified when retrieving approvers for an expense report.
65820ExpenseDocumentRefOrResourceRefRequiredForExpenseReportsPlease specify either an expense document identity or a resource identity, or both. When retrieving approvers for an expense report.