webapi_swagger_documentation
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
webapi_swagger_documentation [2020/05/06 13:43 (4 years ago)] – kevin | webapi_swagger_documentation [2022/02/23 13:40 (2 years ago)] (current) – kevin | ||
---|---|---|---|
Line 2: | Line 2: | ||
===== Summary ===== | ===== Summary ===== | ||
- | The s5webAPI solution runs as a 32-bit service and provides a doorway to push and pull information from a System Five database. | + | The s5webAPI solution runs as a 32-bit service and provides a doorway to push and pull information from a System Five database. |
The following is an explanation for retrieving and using the Swagger 2.0 documentation from all available endpoints of the Windward S5WebAPI. | The following is an explanation for retrieving and using the Swagger 2.0 documentation from all available endpoints of the Windward S5WebAPI. | ||
Line 9: | Line 9: | ||
<note important> | <note important> | ||
+ | |||
+ | < | ||
Line 59: | Line 61: | ||
===== Known Limitations ===== | ===== Known Limitations ===== | ||
- | Prior to 6.2.2.175 released versions of the Web API had a maximum limit of 32 concurrent connections. This limit has been removed and is now limited by how much available memory (max 4GB as this is a 32 bit service) running the API. | + | Prior to 6.2.2.175 released versions of the Web API had a maximum limit of 32 concurrent connections. This limit has been removed and is now limited by how much available memory (max 4GB as this is a 32-bit service) running the API. |
- | <note tip> | + | The Swagger 2.0 interface is only supported via HTTP, it is not supported via HTTPS. The other methods described below can be used when HTTPS is the only protocol configured. |
- | Due to the JSON parser that the Windward Web API uses, any ' | + | |
- | </ | + | ===== Setup and Configuration Details ===== |
+ | |||
+ | Configuring both HTTP and HTTPS is not required, but in order to support HTTPS communication and allow the use of the Swagger interface, both need to be configured. | ||
+ | |||
+ | Azure Hosting - Network Security - Both the HTTP Port 80 and the HTTPS Port 443 need to be opened in order to allow external communication. The use of other Ports can be supported, but it is recommended that the standard HTTP - 80 and/or HTTPS - 443 be used to eliminate confusion. | ||
+ | |||
+ | Azure VM - Firewall Rules - Inbound rules for the same HTTP Port 80 and/or HTTPS port 440 need to be added. | ||
+ | |||
+ | The specific instance of the S5WebAPISvc.exe needs to have UDP and TCP Inbound rules to allow communication. | ||
+ | |||
+ | Azure Environment Variables on the VM - A System Environment Variable named S5INIPATH must exists and contain the path to the SystemFive_SaaS.ini file that is used by System Five SaaS to launch the application. This INI file should already exists and be in use by the installation | ||
===== Retrieving The Documentation ===== | ===== Retrieving The Documentation ===== | ||
Line 115: | Line 127: | ||
===== Samples | ===== Samples | ||
+ | <note tip> | ||
* [[webapi: | * [[webapi: | ||
* [[webapi: | * [[webapi: | ||
Line 122: | Line 135: | ||
===== What Version are you using? ===== | ===== What Version are you using? ===== | ||
Depending on the feature you may be looking for in an endpoint you may need to know what version you are running. | Depending on the feature you may be looking for in an endpoint you may need to know what version you are running. | ||
- | It is not uncommon | + | It is common |
* http:// | * http:// | ||
Line 132: | Line 145: | ||
===== Release 6.2.4.x History ===== | ===== Release 6.2.4.x History ===== | ||
+ | * Review Further [[https:// | ||
+ | * Version 6.2.4.185 - December 7, 2020 | ||
+ | * [ TFS 41605 / 58429 ] - The Inventory Changes end point has been enhanced to include changes in the stock level, not just the changes inventory records. The End Point will now include the changes made by Purchase Orders and Sales Invoices. | ||
+ | * Version 6.2.4.141 - October 2, 2020 | ||
+ | * [ TFS 40116 ] - Web API: Added Logging information to the Web API Service to help determine the root cause of some runaway processes on the cloud. | ||
+ | * Version 6.2.4.113 - August 14, 2020 | ||
+ | * [ TFS 36512 ] - The / | ||
+ | * Version 6.2.4.80 - July 6, 2020 | ||
+ | * [ TFS 37259 ] - Web API Fix: to Inventory Changes endpoint to ensure proper functionality with pages. | ||
+ | * Version 6.2.4.65 - June 19, 2020 | ||
+ | * [ TFS 31992 / 58075 ] Web API Fix: to include an email in the / | ||
* Version 6.2.4.10 – April 2, 2020 | * Version 6.2.4.10 – April 2, 2020 | ||
* [ TFS 33670 / 58200 ] Web API Fix: eCommerceExport=Y filter was not working for / | * [ TFS 33670 / 58200 ] Web API Fix: eCommerceExport=Y filter was not working for / | ||
===== Release 6.2.2.x History ===== | ===== Release 6.2.2.x History ===== | ||
+ | * Review further [[https:// | ||
* Version 6.2.2.636 – March 12, 2020 | * Version 6.2.2.636 – March 12, 2020 | ||
* [ TFS 32447 / 58176 ] The Inventory/ End Point methods now accepts a Department Parameter to reduce the volume of data returned by the API by limiting Stock, Price, and Sale Date information to the requested Department. Also matched the contents of the Returned Pricing to the object listed in the Swagger documentation. | * [ TFS 32447 / 58176 ] The Inventory/ End Point methods now accepts a Department Parameter to reduce the volume of data returned by the API by limiting Stock, Price, and Sale Date information to the requested Department. Also matched the contents of the Returned Pricing to the object listed in the Swagger documentation. | ||
Line 227: | Line 252: | ||
===== Beta 6.2.7.x History ===== | ===== Beta 6.2.7.x History ===== | ||
There can be functionality available in our beta that will not be present in our released product. | There can be functionality available in our beta that will not be present in our released product. | ||
+ | * Version 6.2.7.696 - December 9, 2020 | ||
+ | * [ TFS 41605 / 58429 ] - The Inventory Changes end point has been enhanced to include changes in the stock level, not just the changes inventory records. The End Point will now include the changes made by Purchase Orders and Sales Invoices. | ||
+ | * Version 6.2.7.615 - August 14, 2020 | ||
+ | * [ TFS 36512 ] - The / | ||
* Version 6.2.7.562 – April 28, 2020 | * Version 6.2.7.562 – April 28, 2020 | ||
- | * [ TFS 34807 ] Fix for / | + | * [ TFS 34807 ] Fix for / |
* Version 6.2.7.530 – March 25, 2020 | * Version 6.2.7.530 – March 25, 2020 | ||
* [ TFS 33670 / 58200 ] Web API Fix: eCommerceExport=Y filter was not working for / | * [ TFS 33670 / 58200 ] Web API Fix: eCommerceExport=Y filter was not working for / | ||
Line 276: | Line 305: | ||
* [56999] Added pagination to the Inventory, Virtual Inventory, Customer and A/P Bill endpoints to eliminate calls that exceed the maximum number of records that the S5WebAPISvc can handle. | * [56999] Added pagination to the Inventory, Virtual Inventory, Customer and A/P Bill endpoints to eliminate calls that exceed the maximum number of records that the S5WebAPISvc can handle. | ||
- | ===== Troubleshooting | + | ===== Common Errors/ |
+ | Best practices when troubleshooting errors or issues for escalation with engineering or another technician. | ||
+ | * Check the logs and capture the specific error message text (with an export of the logs or screenshot) | ||
+ | * Capture the complete S5webapi INI file settings | ||
+ | * Any other relevant information such as the operating systems (Are windows updates applied) | ||
+ | |||
+ | |||
+ | ** Getting POS Failure! {" | ||
+ | |||
+ | Reasons : | ||
+ | The JSON that is being used is invalid. | ||
+ | |||
+ | Only 1 InvoiceLines Array is allowed. | ||
+ | The Description must only have 255 characters MAXIMUM! The database will throw away anything longer. | ||
+ | The Invoice Comment must not contain invalid characters. (Carriage Returns and Line Feeds) | ||
+ | |||
+ | Additional information: | ||
+ | You do not need to include the InvoiceCustomer / InvoiceShipTo unique numbers AND the InvoiceShipping / InvoiceBilling | ||
+ | One or the other is all that is required. If you know the Unique Numbers, use them. The system will ignore InvoiceShipping and InvoiceBilling data. | ||
+ | If you don’t, then use the InvoiceShipping and InvoiceBilling. The system will look-up the Account records or create them. | ||
+ | |||
+ | Here is what it should look like: | ||
+ | < | ||
+ | { | ||
+ | " | ||
+ | { | ||
+ | " | ||
+ | " | ||
+ | " | ||
+ | " | ||
+ | " | ||
+ | " | ||
+ | " | ||
+ | " | ||
+ | " | ||
+ | " | ||
+ | " | ||
+ | " | ||
+ | " | ||
+ | }, | ||
+ | " | ||
+ | { | ||
+ | " | ||
+ | " | ||
+ | } | ||
+ | ], | ||
+ | " | ||
+ | { | ||
+ | " | ||
+ | " | ||
+ | " | ||
+ | " | ||
+ | }, | ||
+ | { | ||
+ | " | ||
+ | " | ||
+ | " | ||
+ | " | ||
+ | } | ||
+ | ] | ||
+ | } | ||
+ | ], | ||
+ | " | ||
+ | " | ||
+ | } | ||
+ | } | ||
+ | </ | ||
+ | |||
+ | You can prevent all of these problems by simply checking the JSON payload in a JSON editor like: | ||
+ | https:// | ||
+ | |||
+ | |||
+ | ** Adding Newline Feed on Invoice Comment ** | ||
+ | |||
+ | In /addInvoice method, you can add Invoice Comment. In the parameter, look for this field " | ||
+ | |||
+ | To add a new line feed, add this \\n in the comment. | ||
+ | |||
+ | ** Access Violation when making API call ** | ||
+ | |||
+ | When troubleshooting the s5webAPI if receiving an access violation when making an API call, XML may require re-installation. | ||
+ | |||
+ | |||
+ | **Getting a User Security Error on WordsToo.btr** | ||
+ | |||
+ | If you are presented with a "User # Security Error on WordsToo.btr. User Record has been tampered with" message. | ||
+ | |||
+ | The reason for this error message is due to the user account being locked out or expired and the S5webapi is trying to login using those credentials. | ||
+ | |||
+ | To resolve this issue: | ||
+ | - Go to Setup Wizard > Users and Security > Go to user # (It is the WEB API log in) | ||
+ | - Uncheck the lockout tick box or reset the password | ||
+ | - Ensure the password is the same in the WebAPI.INI configuration | ||
+ | - Restart the S5WebAPI | ||
+ | - Optionally test the S5WebAPI using swagger if configured | ||
+ | |||
+ | |||
+ | **LogAnaylytics: | ||
+ | |||
+ | This happens when the Log Analytics workspace is unreachable. The API service keeps trying to connect to the workspace which causes it to use too much CPU on the client' | ||
+ | |||
+ | As a workaround, we removed the Log Analytics argument from the ini file. | ||
+ | |||
+ | {{: | ||
- | ===Access Violation when making API call=== | + | Once it is removed, CPU usage goes back to normal. |
- | When troubleshooting the s5webAPI if receiving an access violation when making and API call re-install XML. |
webapi_swagger_documentation.1588797797.txt.gz · Last modified: 2020/05/06 13:43 (4 years ago) by kevin