AgreementService
Version: 1.33
AgreementService is optional and is queried from within Service. AgreementService is the using of an Agreement for a particular instance of a Service for a customer.
Agreement can be queried to show which Agreements you have available to use. You attach Agreements to Products when you create or change the Product in the interface. Then when your customer purchases a Product with an Agreement, through the API, use AgreementService through Service to define the start date and end date and the final action at the end of the Service.
Parameters
Element Name | Element Type | Field Length | Description |
---|---|---|---|
queryScope |
QueryScope |
- - |
Whether default query results are overridden by QueryScope resulting in SHALLOW or DEEP query results. |
eid |
Long |
System Generated |
System generated unique identity number assigned to all entities in Gotransverse. |
agreement |
Agreement |
- - |
The Agreement used currently for this Service. |
nextAgreement |
Agreement |
- - |
The next Agreement that occurs after this Agreement if the Agreement End Action is "Change Agreement." |
nextServiceProduct |
Product |
- - |
The next service Product if the Agreement End Action is "Change Service." |
startDate |
DateTime |
Refer to Data Types for dateTime formats. |
The start date of the Agreement. |
endDate |
DateTime |
Refer to Data Types for dateTime formats. |
The end date of the Agreement. |
endAction |
AgreementEndAction |
- - |
The action that occurs when the Agreement ends. |
nextEndAction |
AgreementEndAction |
- - |
The action, if any, that occurs after endAction. |
nextServicePayOnPurchase |
Boolean |
Select either: "true" (Yes) or "false" (No) |
The next Service will be Pay on Purchase. YES, the next Service will be Pay on Purchase. NO, the next Service will NOT be Pay on Purchase. |
renewed |
Boolean |
Select either: "true" (Yes) or "false" (No) |
This Agreement is renewed. YES, this Agreement is renewed. NO, this Agreement is NOT renewed. |
Entity AgreementServices
The entity AgreementServices enables you to see multiple pages of the entity AgreementService.
Element Name | Element Type | Field Length | Description |
---|---|---|---|
pageNumber |
Integer |
as needed |
Shows the current page number. |
pageSize |
Integer |
as needed |
Shows the page size. |
totalElements |
Long |
as needed |
Shows the total number of items found. |
elementCount |
Integer |
as needed |
Shows the current count of the item in the number of items that were found. |
totalPages |
Integer |
as needed |
Shows the total number of pages. |
agreement |
AgreementService |
- - |
Shows the list of AgreementServices. |
Information for the related Entity of AgreementServices:
-
Entity AgreementServices
How to Query for an AgreementService
Query Key Information for SOAP and REST
Querying to see Agreement Services needs to include one of the following parameters. If you do not know the value for the parameter, query separately to learn the value.
Query Key | Value | Definition |
---|---|---|
eid |
Long |
The eid number of the AgreementService. |
serviceEid |
Long |
The eid number of the Service. |
serviceResourceIdentifier |
String |
The name of the Service Resource Identifier. |
childServiceResourceIdentifier |
String |
The name of the Child Service Resource Identifier (if there is one). |
productEid |
Long |
The eid number of the Product. |
accountNum |
String |
The unique Gotransverse Billing Account number |
serviceStatus |
String |
The status of the Service. |
Query to Use | Query to Use | Query to Use | Query to Use |
---|---|---|---|
SimpleDataQuery |
AgreementService |
<parameter name><parameter value> |
List of your AgreementServices for that parameter name and value. |
SOAP Example Query
In the following example SOAP query, the parameter of accountNum (in this example "7") was used.
<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"> <soap:Body> <ns2:query xmlns="http://www.tractbilling.com/billing/1_31/domain" xmlns:ns2="http://www.tractbilling.com/billing/1_31/service"> <ns2:queryRequest> <simpleDataQuery startIndex="0" size="50"> <type>AgreementService</type> <parameter parameter="accountNum" parameterValue="7"/> </simpleDataQuery> </ns2:queryRequest> </ns2:query> </soap:Body> </soap:Envelope>
REST Endpoint
Query
-
GET https://my.tractbilling.com/t/s/r/1.33/agreementServices/<eid>
-
GET https://my.tractbilling.com/t/s/r/1.33/agreementServices?eid=<eid>
-
GET https://my.tractbilling.com/t/s/r/1.33/agreementServices?serviceEid=<serviceEid>
-
GET https://my.tractbilling.com/t/s/r/1.33/agreementServices?serviceResourceIdentifier=<serviceResourceIdentifier>
-
GEThttps://my.tractbilling.com/t/s/r/1.33/agreementServices?childServiceResourceIdentfier=<childServiceResourceIdentfier>
-
GET https://my.tractbilling.com/t/s/r/1.33/agreementServices?productEid=<productEid>
-
GET https://my.tractbilling.com/t/s/r/1.33/agreementServices?accountNum=<accountNum>
-
GET https://my.tractbilling.com/t/s/r/1.33/agreementServices?serviceStatus=<serviceStatus>
Update
-
PUT https://my.tractbilling.com/t/s/r/1.33/agreementServices/<eid>
REST Example for Update
The Mount point for REST call (PUT request) replaces the entire entity, not just one particular field. Query for the Agreement Service, and then pass the modified entity back into Gotransverse using the following PUT request:
-
PUT https://my.tractbilling.com/t/s/r/1.33/agreementServices/33444
REST Example
The following example shows the agreementService eid of "33444" and nextAgreement eid of "11133" and nextServiceProduct eid of "22442." All 3 eids were obtained through separate queries.
<agreementService xmlns="http://www.tractbilling.com/billing/1_31/domain" eid="33444" endDate="2014-11-18" endAction="CHANGE_SERVICE" nextEndAction="RENEW_AGREEMENT" nextServicePayOnPurchase="true"> <nextAgreement eid="11133" /> <nextServiceProduct eid="22442" /> </agreementService>