Subscribe enterprise to receive usage logs

bonnewu
Level 1.5: Cupcake

Currently, I am trying to implement lost mode notifications with push pubsub and I need to subscribe enterprise to receive usage logs. When I try to use the following json to patch my enterprise (a chunk related to usage logs):

"enabledNotificationTypes": [
"ENROLLMENT",
"STATUS_REPORT",
"USAGE_LOGS",
"COMMAND"
]

I receive only "ENROLLMENT", "STATUS_REPORT" and "COMMAND" in response json. And as expected no location event logs are being pushed from the pubsub. Do I need extra configuration to use USAGE_LOGS or something?

Response example json: 

{
        "name": "enterprises/enterpriseName",
        "enabledNotificationTypes": [
                  "ENROLLMENT",
                  "STATUS_REPORT",
                  "COMMAND"

        ],
       "pubsubTopic": "projects/projectId/topics/topicName",
}

1 ACCEPTED SOLUTION

jeremy
Level 2.3: Gingerbread

I've checked our logs, and it seems that even this has not been enabled, I'm seeing some USAGE_LOGS on our incoming notification 

 

 "usageLogEvents": [{
    "eventTime": "2024-03-22T16:49:12.079Z",
    "eventType": "ENROLLMENT_COMPLETE",
    "enrollmentCompleteEvent": {
    }
  }]
}", attributes: {"notificationType"=>"USAGE_LOGS"},

 

So maybe this is enabled "by default" ?

View solution in original post

4 REPLIES 4

jasonbayton
Level 4.0: Ice Cream Sandwich

Hi there

 

I'm seeing the same behaviour when I enable USAGE_LOGS on my enterprise also. @jeremy any insight?

 

This would be worth raising in the partner community (emm.androidenterprise.dev) also for more in-depth assistance 

jeremy
Level 2.3: Gingerbread

Hey @jasonbayton @bonnewu seeing the same thing here also, cannot enable USAGE_LOGS 

jasonbayton
Level 4.0: Ice Cream Sandwich

@Lizzie is this expected? I can't see any docs that would suggest it can't be enabled

jeremy
Level 2.3: Gingerbread

I've checked our logs, and it seems that even this has not been enabled, I'm seeing some USAGE_LOGS on our incoming notification 

 

 "usageLogEvents": [{
    "eventTime": "2024-03-22T16:49:12.079Z",
    "eventType": "ENROLLMENT_COMPLETE",
    "enrollmentCompleteEvent": {
    }
  }]
}", attributes: {"notificationType"=>"USAGE_LOGS"},

 

So maybe this is enabled "by default" ?