Skip to main content

Aids calling IriusRisk v1 APIs. Starting point when creating more complex scripts that create, call and process API calls.

Project description

API Shell program

This is a program shell to aid calling IriusRisk APIs. Use this shell to create more complex scripts that create, call and process API calls.

Using this shell program provides default command-line and configuration-file entries useful for making IriusRisk API calls. Most of the command line arguments provided can be duplicated in configuration files, thereby allowing you to provide them in a file once across multiple script calls.

For further information, clone this subdirectory and execute the main file:

python3 main.py

This describes in greater detail how to call the program shell.

TODO

  • Need to look for ini files in multiple locations
  • Need to add a toolkit to ease HTTP calls

This will describe in detail how to call the program shell.

Usage example

  • clone or branch this repository

  • Edit the main.py file, appending the following lines to it:

      from iriusrisk.v1.facade import do_get
    
      (resp, json) = do_get("products")
      for i in json:
          print(i["name"])
    
  • Call the program from the command line:

      cd ./IriusRisk-Central/Integrations/ApiShell/
      python3 main.py --key {valid API key} --subdomain {SaaS sub-domain}
    

This will list out the names of all the projects in the specified IriusRisk instance, available to the user of the API key.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

iriusrisk_apishell_v1-0.2.0.tar.gz (6.5 kB view hashes)

Uploaded Source

Built Distribution

iriusrisk_apishell_v1-0.2.0-py3-none-any.whl (8.4 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page