Skip to content

AVEVA/sample-adh-data_views-python

Repository files navigation

Using the Cds Data View Service in Python

Version: 1.5.6

Build Status

The sample code in this demonstrates how to invoke the Data View REST API via the sample Python client library. The sample demonstrates how to establish a connection to SDS, obtain an authorization token, create an SdsType and SdsStream with data (if needed), create a Data View, update it, retrieve it, and retrieve data from it in different ways. At the end of the sample, everything that was created is deleted.

This example uses the adh_sample_library_preview library which is also included in this github repo. It is downloadable via pip.

Developed against Python 3.9.5.

Running the Sample

  1. Clone the GitHub repository
  2. Install required modules: pip install -r requirements.txt
  3. Open the folder with your favorite IDE
  4. The sample is configured using the file appsettings.placeholder.json. Before editing, rename this file to appsettings.json. This repository's .gitignore rules should prevent the file from ever being checked in to any fork or branch, to ensure credentials are not compromised.
  5. Update appsettings.json with the credentials provided by AVEVA
  6. Run program.py

To test the sample after running it:

  1. Run python test.py

or

  1. Install pytest pip install pytest
  2. Run pytest program.py

Automated test uses Python 3.9.5 x64

For the main Cds data views samples page ReadMe
For the main Cds samples page ReadMe
For the main AVEVA samples page ReadMe

About

No description, website, or topics provided.

Resources

License

Security policy

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages