Skip to end of metadata
Go to start of metadata

In the benchmark the following Goals can be used for App Activity and Network Activity

Information derived from activityCategories.json:  https://raw.githubusercontent.com/yonadev/yona-server/master/dbinit/data/activityCategories.json

localizableName in "en-US"

goalID

Example of
applications
for App Activity

Goal Type 

smoothwall Categories
for Network Activity
example

Adult content1f088f0b-9952-4ac7-bdc0-fd242238bc1d Bad app NO-GOAdult Sites 
Communication90b9838f-1430-484b-94c1-e169318091cb com.whatsapp Budget / TimeZoneChat
Gambling192d69f4-8d3e-499b-983c-36ca97340ba9 Poker App NO-GOGambling
Multimediaeb7be352-b449-4d30-98fe-3be6ad555b43 nl.uitzendinggemist Budget / TimeZoneYouTube
News743738fd-052f-4532-a2a3-ba60dcb1adbf NU.nl Budget / TimeZonenews/media
Social27395d17-7022-4f71-9daf-f431ff4f11e8 Facebook Budget / TimeZoneFacebook

 

Example on News, which shows the smoothwallCategories and the applications

{
      "id": "743738fd-052f-4532-a2a3-ba60dcb1adbf",
      "localizableName": {
         "en-US": "News",
         "nl-NL": "Nieuws"
      },
      "mandatoryNoGo": false,
      "smoothwallCategories": [
         "News",
         "KS-Nieuws",
         "KS-Radio En Tv",
         "news/media",
         "newsgroups/forums"
      ],
      "applications": [
         "nl.sanomamedia.android.nu",
         "nl.nos.app",
         "NU.nl"
      ],
      "localizableDescription": {
         "en-US": "This challenge includes apps and sites like NU.nl and NOS",
         "nl-NL": "Deze challenge bevat apps en sites zoals NU.nl en NOS"
      }
   },

 

Send Activity

Network Activity:

POST /userAnonymized/${vpnLoginUserID_1}/networkActivity/ to port ${analysisServicePort}

{
   "eventTime": "${randomDateTimeStart}",
   "categories":["Adult Sites"],
   "url":"http://www.poker.com"
}

App Activity:

POST /users/${UserID}/appActivity

{
  "deviceDateTime": "${__time(yyyy-MM-dd'T'HH:mm:ss.SSSZ)}",
  "activities": [
    {
      "application": "NU.nl",
      "startTime": "${randomDateTimeStart}",
      "endTime": "${randomDateTimeEnd}"
    }
  ]
}

 

Set Goals

Grab Goals url 

Grab the Goals url for that user/buddy MessagesUserUrl

_embedded.yona:goals._links.self

 

      "_links": {
        "self": {
          "href": "http://build.dev.yona.nu/users/2955f36a-1c2c-4b14-b148-c3941174100b/goals/"
        }
      }

 

Setting BudgetGoal for News

POST ${UserGoalID_1}

{
  "@type": "BudgetGoal",
  "maxDurationMinutes": 45,
  "creationTime": "2017-05-01T11:00:00.000+0000",
  "_links": 
        {
           "yona:activityCategory": 
                {
                        "href": "http://localhost:8082/activityCategories/743738fd-052f-4532-a2a3-ba60dcb1adbf"
                }
        }

Setting TimeZoneGoal for social media (each day has identical TimeZones!):

{
   "@type":"TimeZoneGoal",
   "zones":[
      "07:00-08:30",
      "17:00-22:00"
   ],
   "creationTime":"2017-05-01T11:00:00.000+0000",
   "_links":{
      "yona:activityCategory":{
         "href":"http://localhost:8082/activityCategories/27395d17-7022-4f71-9daf-f431ff4f11e8"
      }
   }
}

 

 

  • No labels