Please visit our new TrackAbout Knowledge Base at https://supportkb.trackabout.com for the most-up-to-date documentation on TrackAbout and TrackAbout Mobile.
Difference between revisions of "Customer Transaction History Service"
(Created page with '== Cylinder Transaction History Report Web Service == This web service allows you to generate a report outlining all assets that were delivered or returned within a given date r…') |
|||
| Line 1: | Line 1: | ||
| − | |||
| − | |||
This web service allows you to generate a report outlining all assets that were delivered or returned within a given date range for a given customer. Deliveries and returns are matched up on the same line representing a round trip for the asset. | This web service allows you to generate a report outlining all assets that were delivered or returned within a given date range for a given customer. Deliveries and returns are matched up on the same line representing a round trip for the asset. | ||
Revision as of 13:33, 8 February 2010
This web service allows you to generate a report outlining all assets that were delivered or returned within a given date range for a given customer. Deliveries and returns are matched up on the same line representing a round trip for the asset.
Authentication
As with all TrackAbout web services, the HTTP request must have Basic Authentication credentials included. More information on HTTP Basic Authentication can be found at the following resources:
Report Parameters
The parameters for the report are provided via query string values. See the 'Usage' section below for more information on creating the query string. All parameters must have a valid value provided or the web service will return an error code.
- Customer Id - custId - The Id of the customer for which the report should be run.
- Include Departments? - inclDept - True or False value indicating whether departments of the provided customer should also be included in the report.
- Start Date - startDate - Beginning date of the date range that should be included in the report.
- End Date - endDate - Ending date of the date range should should be included in the report.
- Sort Column - sortCol - Numeric value indicating how the resulting data should be sorted. Valid values include:
- 1 - Sort by Product Code
- 2 - Sort by Serial Number
- 3 - Sort by Bar code
- 4 - Sort by Ship Date
- 5 - Sort by Return Date
Validations and Restrictions
The following validations are applicable to the parameters provided to this report. If one or more of these validations fail the web service will return an HTTP error code with a message indicating why validation failed.
- The provided start and end date values must represent valid dates and a valid date range. For example, the end date must come after the start date.
- The provided date range can cover a maximum of three years.
- The provided customer Id must exist within the TrackAbout database.
- The provided sort column number must fall within the allowed values indicated above.
Report Output
The resulting report data will be rendered into a PDF document that will be returned to the caller. The following columns are included in the report:
- Product Code
- Product Description
- Barcode
- Serial Number
- Ship Date
- Expiration Date
- Return Date
- Invoice Number
- Purchase Order Number
- Line Number (sequentially generated line number per record to identify lines and ensure report is complete)
Usage
- Web Service URL: https://www.trackabout.com/ws/CylinderTransactionReport.asmx
- Allowed HTTP Actions: GET
- Input: All parameters are provided in the query string. When creating the query string, use the query string key values specified below for the corresponding parameter. Note: Be sure to properly URL Encode each parameter value. More information on URL Encoding: Wikipedia: URL Encoding
- Customer Id - custId
- Include Departments? - inclDept
- Start Date - startDate
- End Date - endDate
- Sort Column - sortCol
Full Example URL for Customer Id = ABC123, Include Departments = false, Start Date = 1/1/2009, End Date = 12/31/2009, Sort Column = 1 (Product Code):
http://dev.trackabout/ws/CylinderTransactionReport.asmx?custId=ABC123&startDate=1%2f1%2f2009&endDate=12%2f31%2f2009&inclDept=False&sortCol=1
- Output: The resulting report data will be rendered into a PDF file and be returned as binary data in the HTTP response. A 'Content-Disposition' HTTP header will be added with the value 'attachment; filename=<generatedFileName>' where <generatedFileName> will be a unique file name with a sequence number generated from the current system time appended to it.