This course is aimed for developers and programmers looking to leverage HTTP Web Requests to build applications for the PI System. It is for someone who needs to understand how to interact with the PI System using RESTful Web Services and develop HTTP requests to retrieve the necessary information. Generic HTTP web request knowledge will not be taught in this course.
By the end of the course, you will be able to:
- Understand the common use cases of Web API and determine if it is the correct tool for your use case
- Comfortably utilize the PI Web API in a browser to navigate to specific elements, attributes, and points as well as certain configurational and security items.
- Locate the PI Web API Programmers’ Reference and utilize the Help files to develop queries necessary for your application
- Leverage URL parameters to specify your query with reference to the Help Documentation for valid parameters
- Create, Edit, and Delete AF Elements, AF Attributes, and PI Points
- Leverage the Batch Controller endpoint to make multiple dependent sub-requests and dynamically create requests based on previous sub-request responses
- Perform basic AF Search Queries via the PI Web API to filter for event Frames, Elements, and Attributes of interest
- Retrieve incremental real-time updates via the Stream Updates and/or Channels features
- Identify and resolve issues with making cross-origin requests by properly setting Cross-Origin Resource Sharing (CORS) and Cross-Site Forgery Request (CSRF) Defense Settings in the PI Web API
- Identify and Utilize Debugging tools to troubleshoot your own code
- Identify improvements that can be cumulatively applied to improve code/HTTP request performance and readability
Audience: Developers and programmers looking to leverage HTTP Web Requests to build applications for the PI System
Time: 6 hours/week, for 3 weeks
- This course does not teach programming, but rather how to use the PI Web API within your business. Developers should have basic knowledge of HTTP requests and JSON syntax, though we will cover some of these concepts as well.
- Basic knowledge of the PI System generally is required for this course. Concepts such as PI Asset Framework and the relationship of attributes and elements to PI Points/Tag on the Data Archive should be familiar and comfortable before beginning this course.
- Knowledge and use of developer tools in modern browsers as well as either Postman of Fiddler is beneficial, but not required. Knowledge of RESTful Web Services and Web API’s is valuable, but also not required.
- If you don’t feel comfortable with above the following links provide some introductory information on the necessary background in order to take this course:
- 259 USD: By signing up for this course you will have access to:
- OSIsoft Engineers who can review your final project
- Sharable certificate of completion that can be directly posted on LinkedIn (*To obtain the certificate of completion, you need to pass the final project.)
You can also audit the video lecture content on the OSIsoft Learning YouTube Channel. This does not include the exercises, supplementary readings, graded final project or certificate of completion.
In order to follow along with the videos and complete the exercises, learners will need:
- PI System
- PI Data Archive that is running and collecting data.
- PI Asset Framework with write access to an AF Database
- PI Web API v2018 or newer
- Membership to the PI Web API Administrators local Windows Group on the machine where the PI Web API service is installed
- Google Chrome (v. 70.0.3538 or newer), Firefox (v. 60.0 or newer), or Microsoft Edge (v. 42.17134 or newer)
- This course is taught utilizing Google Chrome for Developer tools and is the preferred browser for the course, though not required
- Fiddler (v. 2.x)
If you do not have access to your own PI System, subscribe to the optional Training Cloud Environment:
Grading and Certification of Completion:
Once you register for this course, you must select one of the final submission review periods below. During this period, our course facilitators will be available to review and grade your project. If you don't receive a passing grade in the first submission, you can re-submit your work again during the 1 week review period.