JAMF to JSM Assets

JAMF to JSM Assets

Import Jamf Data into JSM Assets with OnLink

Overview

Use OnLink to import devices, applications, users, and related attributes from Jamf into JSM Assets. OnLink supports data imports from both Jamf Classic API and Jamf Pro API endpoints.

Prerequisites

Configure the Jamf Connection

  1. Go to OnLink from Manage your apps.

  2. Open Connections.

  3. Select Add System.

  4. Choose Idm/Device Assets Sources.

  5. Enter the Jamf API connection details and save the connection.

Create an Assets Import Configuration

  1. After the Jamf connection is established, review the setup instructions here.

  2. Open the OnLink app from Manage your apps.

  3. Create or update the Assets import configuration.

  4. Configure the field-level mapping based on the Jamf API response you want to import.

Field Mapping Examples

Use mapping rules to define the source fields from Jamf and the target attributes in JSM Assets.

Classic API example: Mobile Devices

The following example imports mobile device data from the Jamf Classic API: Find mobile devices.

key:mobile_device.id=Device ID map:mobile_device.serial_number=Serial Number map:mobile_device.device_name=Device Name map:mobile_device.name=Name map:mobile_device.model=Model config:api=JSSResource/mobiledevices

Pro API example: Computer Inventory

The following example imports computer inventory data from the Jamf Pro API: Get computer inventory.

key:id=id map:general.name=Name map:general.platform=platform map:userAndLocation.username=User Name map:userAndLocation.email=Email map:hardware.make=Hardware Name map:hardware.model=Hardware Model map:hardware.serialNumber=Serial Number map:operatingSystem.name=OS Name map:operatingSystem.version=OS Version map:groupMemberships=BAssets|Name=${groupMemberships}|arrayElement=GROUPID config:api=api/v1/computers-inventory

Mapping Reference

Configuration item

Purpose

Example

Configuration item

Purpose

Example

key

Defines the unique identifier for the imported record. OnLink uses this value to match and update existing Assets records.

key:mobile_device.id=Device ID

map

Maps a field from the Jamf API response to an attribute in JSM Assets.

map:mobile_device.device_name=Device Name

config:api

Specifies the Jamf API endpoint that OnLink should call. Update this value and the field mappings to import data from a different Jamf API endpoint.

config:api=JSSResource/mobiledevices

Sample API Response

Use the sample response to identify field names. We recommend starting with few fields for mapping and use Fetch API Sample to view response and use it for mapping

{ "totalCount": 3, "results": [ { "id": "1", "udid": "123", "general": { "name": "Boalime", "lastIpAddress": "247.185.82.186", "lastReportedIpV4": "247.185.82.186", "lastReportedIpV6": "2001:0db8:85a3:0000:0000:8a2e:0370:7335", "jamfBinaryVersion": "9.27", "platform": "Mac", "barcode1": "5 12345 678900", "barcode2": "5 12345 678900", "assetTag": "304822", "remoteManagement": { "managed": true }, "supervised": true, "mdmCapable": { "capable": true, "userManagementInfo": [ [ { "capableUser": "admin", "managementId": "123e4567-e89b-42d3-a456-426614174000" }, { "capableUser": "rootadmin", "managementId": "123e4567-e89b-42d3-a456-426614174001" } ] ] }, "reportDate": "2018-10-31T18:04:13Z", "lastContactTime": "2018-10-31T18:04:13Z", "lastCloudBackupDate": "2018-10-31T18:04:13Z", "lastEnrolledDate": "2018-10-31T18:04:13Z", "mdmProfileExpiration": "2018-10-31T18:04:13Z", "initialEntryDate": "2018-10-31", "distributionPoint": "distribution point name", "enrollmentMethod": { "id": "1", "objectName": "user@domain.com", "objectType": "User-initiated - no invitation" }, "site": { "id": "1", "name": "Eau Claire" }, "itunesStoreAccountActive": true, "enrolledViaAutomatedDeviceEnrollment": true, "userApprovedMdm": true, "declarativeDeviceManagementEnabled": true, "extensionAttributes": [ { "definitionId": "23", "name": "Some Attribute", "description": "Some Attribute defines how much Foo impacts Bar.", "enabled": true, "multiValue": true, "values": [ "foo", "bar" ], "dataType": "STRING", "options": [ "foo", "bar" ], "inputType": "TEXT" } ], "managementId": "73226fb6-61df-4c10-9552-eb9bc353d507", "lastLoggedInUsernameSelfService": "admin", "lastLoggedInUsernameSelfServiceTimestamp": "2018-10-31T18:04:13Z", "lastLoggedInUsernameBinary": "admin", "lastLoggedInUsernameBinaryTimestamp": "2018-10-31T18:04:13Z" }, "diskEncryption": { "bootPartitionEncryptionDetails": { "partitionName": "main", "partitionFileVault2State": "ENCRYPTING", "partitionFileVault2Percent": 100 }, "individualRecoveryKeyValidityStatus": "VALID", "institutionalRecoveryKeyPresent": true, "diskEncryptionConfigurationName": "Test configuration", "fileVault2Enabled": true, "fileVault2EnabledUserNames": [ "admin" ], "fileVault2EligibilityMessage": "Not a boot partition" }, "purchasing": { "leased": true, "purchased": true, "poNumber": "53-1", "poDate": "2019-01-01", "vendor": "Example Vendor", "warrantyDate": "2019-01-01", "appleCareId": "abcd", "leaseDate": "2019-01-01", "purchasePrice": "$500", "lifeExpectancy": 5, "purchasingAccount": "admin", "purchasingContact": "true", "extensionAttributes": [ { "definitionId": "23", "name": "Some Attribute", "description": "Some Attribute defines how much Foo impacts Bar.", "enabled": true, "multiValue": true, "values": [ "foo", "bar" ], "dataType": "STRING", "options": [ "foo", "bar" ], "inputType": "TEXT" } ] }, "applications": [ { "name": "Microsoft Word", "path": "/usr/local/app", "version": "1.0.0", "macAppStore": true, "sizeMegabytes": 25, "bundleId": "1", "updateAvailable": false, "externalVersionId": "1" } ], "storage": { "bootDriveAvailableSpaceMegabytes": 3072, "disks": [ { "id": "170", "device": "disk0", "model": "APPLE HDD TOSHIBA MK5065GSXF", "revision": "5", "serialNumber": "a8598f013366", "sizeMegabytes": 262144, "smartStatus": "OK", "type": "false", "partitions": [ { "name": "Foo", "sizeMegabytes": 262144, "availableMegabytes": 131072, "partitionType": "BOOT", "percentUsed": 25, "fileVault2State": "ENCRYPTING", "fileVault2ProgressPercent": 45, "lvmManaged": true } ] } ] }, "userAndLocation": { "username": "Madison Anderson", "realname": "13-inch MacBook", "email": "email@com.pl", "position": "IT Team Lead", "phone": "123-456-789", "departmentId": "1", "buildingId": "1", "room": "5", "extensionAttributes": [ { "definitionId": "23", "name": "Some Attribute", "description": "Some Attribute defines how much Foo impacts Bar.", "enabled": true, "multiValue": true, "values": [ "foo", "bar" ], "dataType": "STRING", "options": [ "foo", "bar" ], "inputType": "TEXT" } ] }, "configurationProfiles": [ { "id": "1", "username": "username", "lastInstalled": "2018-10-31T18:04:13Z", "removable": true, "displayName": "Displayed profile", "profileIdentifier": "0ae590fe-9b30-11ea-bb37-0242ac130002" } ], "printers": [ { "name": "My Printer", "type": "XYZ 1122", "uri": "ipp://10.0.0.5", "location": "7th floor" } ], "services": [ { "name": "SomeService" } ], "hardware": { "make": "Apple", "model": "13-inch MacBook Pro (Mid 2012)", "modelIdentifier": "MacBookPro9,2", "serialNumber": "C02ZC2QYLVDL", "processorSpeedMhz": 2100, "processorCount": 2, "coreCount": 2, "processorType": "Intel Core i5", "processorArchitecture": "i386", "busSpeedMhz": 2133, "cacheSizeKilobytes": 3072, "networkAdapterType": "Foo", "macAddress": "6A:2C:4B:B7:65:B5", "altNetworkAdapterType": "Bar", "altMacAddress": "82:45:58:44:dc:01", "totalRamMegabytes": 4096, "openRamSlots": 0, "batteryCapacityPercent": 85, "batteryHealth": "UNKNOWN", "smcVersion": "2.2f38", "nicSpeed": "N/A", "opticalDrive": "MATSHITA DVD-R UJ-8A8", "bootRom": "MBP91.00D3.B08", "bleCapable": false, "supportsIosAppInstalls": false, "appleSilicon": false, "provisioningUdid": "00000AAA888-IH866799UUJD991", "extensionAttributes": [ { "definitionId": "23", "name": "Some Attribute", "description": "Some Attribute defines how much Foo impacts Bar.", "enabled": true, "multiValue": true, "values": [ "foo", "bar" ], "dataType": "STRING", "options": [ "foo", "bar" ], "inputType": "TEXT" } ] }, "localUserAccounts": [ { "uid": "501", "userGuid": "844F1177-0CF5-40C6-901F-38EDD9969C1C", "username": "jamf", "fullName": "John Jamf", "admin": true, "homeDirectory": "/Users/jamf", "homeDirectorySizeMb": 131072, "fileVault2Enabled": true, "userAccountType": "LOCAL", "passwordMinLength": 4, "passwordMaxAge": 5, "passwordMinComplexCharacters": 5, "passwordHistoryDepth": 5, "passwordRequireAlphanumeric": true, "computerAzureActiveDirectoryId": "1", "userAzureActiveDirectoryId": "1", "azureActiveDirectoryId": "ACTIVATED" } ], "certificates": [ { "commonName": "jamf.com", "identity": true, "expirationDate": "2030-10-31T18:04:13Z", "username": "test", "lifecycleStatus": "ACTIVE", "certificateStatus": "ISSUED", "subjectName": "CN=jamf.com", "serialNumber": "40f3d9fb", "sha1Fingerprint": "ed361458724d06082b2314acdb82e1f586f085f5", "issuedDate": "2022-05-23T14:54:10Z" } ], "attachments": [ { "id": "1", "name": "Attachment.pdf", "fileType": "application/pdf", "sizeBytes": 1024 } ], "plugins": [ {} ], "packageReceipts": { "installedByJamfPro": [ "com.jamf.protect.JamfProtect" ], "installedByInstallerSwu": [ "com.apple.pkg.Core" ], "cached": [ "com.jamf.protect.JamfProtect" ] }, "fonts": [ { "name": "font name", "version": "1.02", "path": "/Applications/" } ], "security": { "sipStatus": "ENABLED", "gatekeeperStatus": "APP_STORE_AND_IDENTIFIED_DEVELOPERS", "xprotectVersion": "1.2.3", "autoLoginDisabled": false, "remoteDesktopEnabled": true, "activationLockEnabled": true, "recoveryLockEnabled": true, "firewallEnabled": true, "secureBootLevel": "FULL_SECURITY", "externalBootLevel": "ALLOW_BOOTING_FROM_EXTERNAL_MEDIA", "bootstrapTokenAllowed": true, "bootstrapTokenEscrowedStatus": "ESCROWED", "lastAttestationAttempt": "1970-01-01T00:00:00Z", "lastSuccessfulAttestation": "1970-01-01T00:00:00Z", "attestationStatus": "PENDING" }, "operatingSystem": { "name": "Mac OS X", "version": "10.9.5", "build": "13A603", "supplementalBuildVersion": "13A953", "rapidSecurityResponse": "(a)", "activeDirectoryStatus": "Not Bound", "fileVault2Status": "ALL_ENCRYPTED", "softwareUpdateDeviceId": "J132AP", "extensionAttributes": [ { "definitionId": "23", "name": "Some Attribute", "description": "Some Attribute defines how much Foo impacts Bar.", "enabled": true, "multiValue": true, "values": [ "foo", "bar" ], "dataType": "STRING", "options": [ "foo", "bar" ], "inputType": "TEXT" } ] }, "licensedSoftware": [ { "id": "1", "name": "Microsoft Word" } ], "ibeacons": [ { "name": "room A" } ], "softwareUpdates": [ { "name": "BEdit", "version": "1.15.2", "packageName": "com.apple.pkg.AdditionalEssentials" } ], "extensionAttributes": [ { "definitionId": "23", "name": "Some Attribute", "description": "Some Attribute defines how much Foo impacts Bar.", "enabled": true, "multiValue": true, "values": [ "foo", "bar" ], "dataType": "STRING", "options": [ "foo", "bar" ], "inputType": "TEXT" } ], "contentCaching": { "computerContentCachingInformationId": "1", "parents": [ { "contentCachingParentId": "1", "address": "SomeAddress", "alerts": { "contentCachingParentAlertId": "1", "addresses": [], "className": "SomeClass", "postDate": "2018-10-31T18:04:13Z" }, "details": { "contentCachingParentDetailsId": "1", "acPower": true, "cacheSizeBytes": 0, "capabilities": { "contentCachingParentCapabilitiesId": "1", "imports": true, "namespaces": true, "personalContent": true, "queryParameters": true, "sharedContent": true, "prioritization": true }, "portable": true, "localNetwork": [ { "contentCachingParentLocalNetworkId": "1", "speed": 5000, "wired": true } ] }, "guid": "CD1E1291-4AF9-4468-B5D5-0F780C13DB2F", "healthy": true, "port": 0, "version": "1" } ], "alerts": [ { "cacheBytesLimit": 0, "className": "SomeClass", "pathPreventingAccess": "/some/path", "postDate": "2018-10-31T18:04:13Z", "reservedVolumeBytes": 0, "resource": "SomeResource" } ], "activated": false, "active": false, "actualCacheBytesUsed": 0, "cacheDetails": [ { "computerContentCachingCacheDetailsId": "1", "categoryName": "SomeCategory", "diskSpaceBytesUsed": 0 } ], "cacheBytesFree": 23353884672, "cacheBytesLimit": 0, "cacheStatus": "OK", "cacheBytesUsed": 0, "dataMigrationCompleted": false, "dataMigrationProgressPercentage": 0, "dataMigrationError": { "code": 0, "domain": "SomeDomain", "userInfo": [ { "key": "foo", "value": "bar" } ] }, "maxCachePressureLast1HourPercentage": 0, "personalCacheBytesFree": 23353884672, "personalCacheBytesLimit": 0, "personalCacheBytesUsed": 0, "port": 0, "publicAddress": "SomeAddress", "registrationError": "NOT_ACTIVATED", "registrationResponseCode": 403, "registrationStarted": "2018-10-31T18:04:13Z", "registrationStatus": "CONTENT_CACHING_FAILED", "restrictedMedia": false, "serverGuid": "CD1E1291-4AF9-4468-B5D5-0F780C13DB2F", "startupStatus": "FAILED", "tetheratorStatus": "CONTENT_CACHING_DISABLED", "totalBytesAreSince": "2018-10-31T18:04:13Z", "totalBytesDropped": 0, "totalBytesImported": 0, "totalBytesReturnedToChildren": 0, "totalBytesReturnedToClients": 0, "totalBytesReturnedToPeers": 0, "totalBytesStoredFromOrigin": 0, "totalBytesStoredFromParents": 0, "totalBytesStoredFromPeers": 0 }, "groupMemberships": [ { "groupId": "1", "groupName": "groupOne", "groupDescription": "groupOne description", "smartGroup": true } ] } ] }

 

Run and Test the Import

OnLink processes data in two steps: Get Data and Import Data.

  1. Click Get Data to retrieve records from Jamf.

  2. Open Job Logs and wait until you see: No more pending records. Data will be imported on next Import run.

  3. Click Import to import the retrieved records into JSM Assets.

  4. For production use, configure a schedule. Production runs are fully automated based on the schedule you choose.

Troubleshooting and Notes

  • Use the Jamf API response structure to verify each mapped field path.

  • If records are not updating, confirm that the key field is unique and consistently returned by the API.

  • If no data is imported, confirm that the config:api endpoint is correct and that the Jamf API credentials have the required permissions.

  • OnLink can import data from any supported Jamf Classic API or Jamf Pro API endpoint when the mapping matches the API response.

image-20240318-045922.png