Service Pack Audit

api.scripter.service_pack_audit()

A stripped down version of group audit focussing only on the service packs assigned within the group. This only shows the service packs assigned and total count of unlike group audit which details the users this is assigned to.

The script makes use of the following methods:

api.get.group_services()

Parameters

  • service_provider_id: Service Provider ID or Enterprise ID containing the Group ID.

  • group_id: Group ID to generate the report for.

Return

  • JSON: A JSON formatted report of service packs assigned in the group.

How To Use:

from odins_spear import api

my_api= api.Api(base_url="https://base_url/api/vx", username="john.smith", password="ODIN_INSTANCE_1")
my_api.authenticate()

print(
    my_api.scripter.service_pack_audit(
        "ServiceProviderId",
        "GroupId"
    )
)

Example returned data (formatted):


{
    "service_pack_services": [
        {
            "servicePackName": "Standard pack 1",
            "usage": 20,
            "description": "Standard pack 1"
        },
        {
            "servicePackName": "Premium pack 1",
            "usage": 1,
            "description": "Premium pack 1"
        },
        {
            "servicePackName": "Service pack 2",
            "usage": 13,
            "description": "Service pack 2"
        }
    ]
}

Last updated