Web Services XML Examples


Portal Overview Information Guide -> Web Services XML Examples ->
The webservices include support for both legacy sites, as well as customizable fields on a per-customer basis.
The per-customer field customization is not intended to be implemented via web services at this time.

Note: All web service calls should leave T_LEGACY set to N or not specified, and T_INDEX_ID set to "WSDL" to retrieve all available data.

Date formats are YYYYMMDD, time formats are HHMMSS. Yes/No fields take either Y or N, and blank defaults to N.

Portal API Calls

Portal calls to support account customer portal.
TX_CUST_LOGIN or TK_WS_EMAIL_LOGIN must be called first to get a session key, and that session key must be used for all additional calls.

General

Setup

Contract Inquiries

Invoice Inquiries

Reservation Inquiries

Quotation Inquiries

Accounts Receivable Inquiries

Group Inquiries

Maintenance

Shopping Cart

Shopping cart flow:
The shopping cart is maintained by the website. When the user is ready to submit the cart, call TK_WS_UPDATE_CART or TX_UPDATE_CART to clear and then update the cart data stored within the application.
You can then call TX_GET_CART or TK_WS_GET_CART to return the shopping cart contents that will be submitted to the application. TK_WS_GET_CART allows you to request pricing with taxes and other charges while TX_GET_CART only returns quantities.
TX_CHECK_OUT will return the list of parameters to be prompted for (date out, date due, etc) as inputs to TX_SUBMIT_CART or TK_WS_SUBMIT_CART.
TX_SUBMIT_CART and TK_WS_SUBMIT_CART create a Quote or Reservation request within the application and clears the stored cart.
TK_WS_GET_CART, TK_WS_UPDATE_CART, and TK_WS_SUBMIT_CART replace the older TX_* API's, which are only provided for backwards compatibility.

Pickup Requests
Pickup Request Flow
To obtain the list of items available for pickup, you must first call TX_LIST_CONTRACTS, with T_ACTIVE_ONLY = 'Y' or 'O' to obtain a list of contracts. T_DETAIL_REPORT should be set to N or blank.
For each contract in the list returned, call TX_REQUEST_PICKUP, passing it the contract number. This will return a list of product numbers on the contract which are eligible for pickup, as well as the quantity on rent, pending, and confirmed.
On Rent is the current quantity out on contract. Pending is the quantity submitted by pickup via API but not yet confirmed by the application. Once items are confirmed they are removed from this list completely.
The difference between On Rent and Pending is the maximum quantity which can be requested for pickup. As an example, if On Rent is 6 and Pending is 4, you can only request a pickup of 1 or 2.
To submit pickup requests, call TX_SUBMIT_PICKUP_REQUEST, and provide it the list of contract number, product number, quantity to pick up, detail #, etc.
After submitting the pickup request, call TX_REQUEST_PICKUP_ERRORS, and pass it the Pickup# returned by the submit request. This will return any errors that will result in an item not being picked up.

Delivery And Pickup Tickets

Single Line Items

For single line items, T_TICKET_NO = trim(Contract_n) + '-' + trim(Ticket_n) + '-' + trim(offrent_trx_n) + TicketType, where TicketType is 'D' for a deliver, 'P' for a pickup, and 'X' for the outgoing exchange item on a pickup ticket.
T_STOP_TYPE must be either ASSIGN, LOAD or UNLOAD, and is called when the driver is assigned to a ticket, loads an item onto the truck, or unloads it.
This updates the driver within the application when an item is loaded, and captures the quantities and completed times.
T_REPLACED_BY can be used if a product is replaced by a different product, for example if the requested equipment doesn't start, and a different one is taken instead.

Update Multiple Items

For updating multiple items, T_TICKET_NO = trim(Contract_n) + '-' + trim(Ticket_n), and T_STOP_TYPE is either DELIVER or PICKUP.
The API is only called once, upon completion of the pickup or delivery ticket. You can pass up to 5 products that are on the ticket.
Sample Single Line Item Request
Sample Single Line Item Response
Update Ticket Sample Request
Update Ticket Sample Response

Account Payment Calls

These are used to record payments on account.

API Key Calls

These calls require an API key, and can be used without requiring a call to TX_CUST_LOGIN to create a "Portal" Session Id.

These calls are intended to support a multi-tiered shopping cart structure, and the ability to link an email address to an existing account customer number.

Other APIs

These calls are independent of Portal.


Topic Keyword: Portal_Webservices
Converted from CHM to HTML with chm2web Pro 2.85 (unicode)