Example Script Repository
This page collection features script examples and automated solutions using the JumpCloud Api. In general these examples are written using the JumpCloud PowerShell Module and SDKs. These examples are published with the intent to inspire administrators to automate their own solutions.
JumpCloud PowerShell Module and the PowerShell SDKs
In several script examples make use of both the JumpCloud PowerShell Module and it's SDKs.
The JumpCloud PowerShell Module is a collection of functions written to help administrators automate actions within their JumpCloud organizations. This module contains custom functions outside the scope of the API. Several functions have been modified to accept things like Name values instead of Ids.
The JumpCloud PowerShell SDKs are an automatically generated and verbose interpretation of the JumpCloud Api. Pagination is built into these functions but core functionality of a given function is dictated by the Api. The latest version of these SDK modules are installed whenever the JumpCloud PowerShell Module is installed or updated to a new version.
Search Posts by Tag:
powershell(14)
automation(12)
reports(7)
windows(4)
groups(4)
users(2)
mac(2)
commands(2)
bash(2)
wifi(1)
settings(1)
python(1)
policy(1)
policies(1)
mdm(1)
fonts(1)
authentication(1)
accounts(1)
RADIUS(1)
Latest Posts:
To suspend users by their last known successful authentication we first need to know some data about the users. Directory Insights data contains information about a users last known authentication time. The Get-JcLoginEvent
function is a streamlined function to help query users who have completed a successful authentication within a defined time period. This function returns a user’s last known successful “radius_auth”, “sso_auth”, “login_attempt”, “ldap_bind” and/or “user_login_attempt”.
Read More
This script will create two device groups: MacOS-MDM-Pending & MacOS-MDM-Approved. It can be run multiple times to update the membership of the two system groups. If systems are waiting on MDM user approval they will be added to the MacOS-MDM-Pending group. Systems enrolled in JumpCloud MDM and user approved are added to the MacOS-MDM-Approved group.
Read More
(Update 04/02/2024) Temporary admin access can be granted with the JumpCloud console, plesae see the documentation on Granting Administraor Rights for more formation.
The purpose of this script is to grant admin access to a JumpCloud user to a bound system.
This script prompts the user to enter username, system Id, and minutes of how long the user is going to be an admin/sudo. After granted admin status, the user will need to re-login if on Windows machine to see the admin access change. The user is revoked admin status after x mins. User must re-login if on Windows machine to be demoted to standard user.
Read More
This script generates a CSV report of all users and their associations to systems, LDAP Servers, and Google Workspace
Read More
This is to showcase a possible use case of deleting old/expired RADIUS certificates from user’s keychains and allow for the new RADIUS certificates to take their place.
Read More