Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Activity
    barzee
    @barzee

    this one is not working

    {
    "request": {
    "session_id": "6ed210c4-6ead-44a6-b255-6a792d2c4036",
    "activity_id": "bllassess",
    "items": [
    "BARB_6",
    "BARB_5 Sample Question"
    ],
    "name": "BLL Items API demo - assess activity",
    "state": "initial",
    "config": {
    "assessApiVersion": "v2",
    "questionsApiVersion": "v2",
    "title": "Torts Blackletter law Assessment",
    "time": {
    "max_time": 1500,
    "limit_type": "soft",
    "show_pause": true,
    "warning_time": 120,
    "show_time": true
    },
    "navigation": {
    "show_itemcount": true,
    "show_intro": true,
    "show_outro": true
    },
    "ui_style": "main",
    "subtitle": "Study Hard!!!",
    "configuration": {
    "fontsize": "normal",
    "idle_timeout": {
    "interval": 70,
    "countdown_time": 60
    }
    }
    },
    "user_id": "demo_student",
    "course_id": "BARCA",
    "type": "submit_practice",
    "rendering_type": "assess"
    },
    "security": {
    "timestamp": "20140914-2332",
    "consumer_key": "xxxxxxx",
    "domain": "localhost",
    "user_id": "demo_student3",
    "signature": "7273df447aaf6052bb6ff540fbdb2b5f4155deb3d60125e7229495c14e42b9a3"
    }
    }

    This message was deleted

    this one is working

    {
    "request": {
    "session_id": "089d65dc-7a30-48c8-be49-a4c8908df954",
    "activity_id": "bllassess",
    "items": [
    "BARB_6",
    "BARB_5 Sample Question"
    ],
    "name": "BLL Items API demo - assess activity",
    "state": "initial",
    "config": {
    "assessApiVersion": "v2",
    "questionsApiVersion": "v2",
    "title": "Torts Blackletter law Assessment",
    "navigation": {
    "show_itemcount": true,
    "show_intro": true,
    "show_outro": true
    },
    "ui_style": "main",
    "subtitle": "Study Hard!!!",
    "configuration": {
    "fontsize": "normal",
    "idle_timeout": {
    "interval": 70,
    "countdown_time": 60
    }
    }
    },
    "user_id": "demo_student",
    "course_id": "BARCA",
    "type": "submit_practice",
    "rendering_type": "assess"
    },
    "security": {
    "timestamp": "20140914-2335",
    "consumer_key": "xxxxxxx",
    "domain": "localhost",
    "user_id": "demo_student3",
    "signature": "682b0ede4a4486aef450f27f9511c360ef9a63f489637eb6f28befb24bbdf49f"
    }
    }

    barzee
    @barzee

    loading an activity also is failing with LearnosityItems.init(), and signed json object below.

    "request": {
    "assess_inline": false,
    "session_id": "aecbf4d8-5a8f-49dc-a90e-cdd15f23edbe",
    "activity_id": "TortsBLL",
    "activity_template_id": "BARBRIAssessmentActivity",
    "name": "Demo Activity",
    "user_id": "demo_student",
    "course_id": "demo_yis0TYCu7U9V4o7M"
    },
    "security": {
    "timestamp": "20140914-2141",
    "consumer_key": "xxxxxxx",
    "domain": "localhost",
    "user_id": "demo_student",
    "signature": "935fa67c16465235f6c467546c368c3070440e01adac77819b575df22b1c0e4a"
    }
    }

    Michael Sharman
    @michaelsharman
    ok we’ll take a look at that now
    barzee
    @barzee
    Any updates on these? Thanks.
    klauste
    @klauste
    Hi there, I'm working on this
    so far, I'm not certain where the error is coming from
    I'll let you know once I know more
    barzee
    @barzee
    thanks.
    klauste
    @klauste
    @barzee I was able to get the items api going with a time node, so I don't think this has anything to do with a specific node
    I think the problem might be some whitespace
    what worked well for me, is to create a JSONObject from the JSONString
    and then to pass the JSONObject to the sdk
    do you want to give that a try?
    barzee
    @barzee
    OK
    I'll let you know.
    barzee
    @barzee
    Can you give simple example what exactly you did? Thanks.
    klauste
    @klauste
    sure, here's the code:
            String itemSecString = "{\"consumer_key\":\"yis0TYCu7U9V4o7M\","
                    +    "\"domain\": \"demos.vg.learnosity.com\","
                    +   "\"user_id\": \"demo_student\"}";
    
            String itemsString = "{\"activity_id\": \"itemsassessdemo\","
                    + "\"name\": \"Items API demo - assess activity\","
                    + "\"rendering_type\" : \"assess\","
                    + "\"state\"          : \"initial\","
                    + "\"type\"           : \"submit_practice\","
                    + "\"course_id\"      : \"demo_yis0TYCu7U9V4o7M\","
                    + "\"session_id\"     : \"041f48c9-cb80-42e8-9d06-467d92013b00\","
                    + "\"user_id\"        : \"demo_student\","
                    + "\"items\": [\"Demo3\", \"Demo4\", \"Demo5\", \"Demo6\", \"Demo7\", \"Demo8\", \"Demo9\",\"Demo10\"],"
                    + "\"assess_inline\": true,"
                    + "\"config\": {"
                    + "\"title\": \"Demo activity - showcasing question types and assess options\","
                    + "    \"subtitle\"       : \"Walter White\","
                    + "    \"administration\" : {"
                    + "        \"pwd\" : \"5e884898da28047151d0e56f8dc6292773603d0d6aabbdd62a11ef721d1542d8\","
                    + "        \"options\" : {"
                    + "            \"show_save\" : true,"
                    + "            \"show_exit\" : true,"
                    + "            \"show_extend\" : true"
                    + "        }"
                    + "    },"
                    + "    \"navigation\" : {"
                    + "        \"scroll_to_top\"            : false,"
                    + "        \"scroll_to_test\"           : false,"
                    + "        \"show_intro\"               : true,"
                    + "        \"show_outro\"               : false,"
                    + "        \"show_next\"                : true,"
                    + "        \"show_prev\"                : true,"
                    + "        \"show_accessibility\"       : true,"
                    + "        \"show_fullscreencontrol\"   : true,"
                    + "        \"show_progress\"            : true,"
                    + "        \"show_submit\"              : true,"
                    + "        \"show_title\"               : true,"
                    + "        \"show_save\"                : false,"
                    + "        \"show_calculator\"          : false,"
                    + "        \"show_itemcount\"           : true,"
                    + "        \"skip_submit_confirmation\" : false,"
                    + "        \"swipe\"                    : true,"
                    + "        \"toc\"                      : true,"
                    + "        \"transition\"               : \"slide\","
                    + "        \"transition_speed\"         : 400,"
                    + "        \"warning_on_change\"        : false,"
                    + "        \"scrolling_indicator\"      : false,"
                    + "        \"show_answermasking\"       : true,"
                    + "        \"auto_save\" : {"
                    + "            \"ui\" : false,"
                    + "            \"saveIntervalDuration\" : 500"
                    + "        }"
                    + "    },"
                    + "    \"time\" : {"
                    + "        \"max_time\"     : 1500,"
                    + "        \"limit_type\"   : \"soft\","
                    + "        \"show_pause\"   : true,"
                    + "        \"warning_time\" : 120,"
                    + "        \"show_time\"    : true"
                    + "    },"
                    + "    \"labelBundle\" : {"
                    + "        \"item\" : \"Question\""
                    + "    },"
                    + "    \"ui_style\"            : \"main\","
                    + "    \"ignore_validation\"   : false,"
                    + "    \"configuration\"       : {"
                    + "        \"fontsize\"               : \"normal\","
                    + "        \"stylesheet\"             : \"\","
                    + "        \"onsubmit_redirect_url\"  : \"itemsapi_assess.php\","
                    + "        \"onsave_redirect_url\"    : \"itemsapi_assess.php\","
                    + "        \"ondiscard_redirect_url\" : \"itemsapi_assess.php\","
                    + "        \"idle_timeout\"           : {"
                    + "            \"interval\"       : 300,"
                    + "            \"countdown_time\" : 60"
                    + "        }"
                    + "    }"
                    + "}}";
    
            JSONObject itemsObj = new JSONObject(itemsString);
            //itemsString = itemsObj.toString();
            init = new Init("items", itemSecString, consumerSecret, itemsObj.toString(), "");
            String itemsTest = init.generate();
    When calling the constructor, you can also pass in the JSON Object like so:
    init = new Init("items", itemSecString, consumerSecret, itemsObj,"");
    Does that make sense?
    barzee
    @barzee
    Before I started this chat I tried passing JSONObject, String with all sorts of options and nothing seemed to work with time node init. I'm trying now with the above code.
    klauste
    @klauste
    There are a couple of overloaded constructors and the one you'd want to call is this one:
    public Init (String service, Object securityPacket, String secret, Object requestPacket, String action)
    that's what the above code does
    barzee
    @barzee
    OK
    barzee
    @barzee
    Got it. I appreciate your help.
    klauste
    @klauste
    cool, all good
    barzee
    @barzee
    I have a question about environments. We currently have DEV,QA and PROD environments and I was wandering if you expose environments for testing and production separately or is all the same?
    Michael Sharman
    @michaelsharman
    it often depends on how clients want to set things up
    you can point to our production versions, for you’re own lower level environments
    of course that might mean different versions of our products in your QA for testing and UAT etc
    in terms of content from our item bank, you can use the same (production) content across all environments
    or we can create different sandboxes in the authoring site for you to have separation of content between your environments
    hope that helped
    barzee
    @barzee
    My concern is cluttering your PROD version with QA and DEV user_id's that we'd have to filter somehow after release later on. As far as the authoring tool goes, I think that it is fine for now to use the same PROD content across environments.
    barzee
    @barzee
    I also have a question about storage and performance. On a given school period we might have between 20,000 and 40,000 students taking tests. Would this be a concern to you?
    Michael Sharman
    @michaelsharman
    there is a difference between content (item bank) and student responses
    you can have ALL environments use the same item bank conent
    while storing student responses (different user_ids) in different systems, so they don’t clutter environments
    Michael Sharman
    @michaelsharman
    ~40K students isn’t a problem
    Michael Sharman
    @michaelsharman
    just to confirm, to separate the storage of user related data (across QA, Test, Prod etc) you’d need to liaise with us first so we can give you a different set of consumer credentials
    barzee
    @barzee
    Thanks for the info.
    barzee
    @barzee
    What would it take to establish the testing environments? Thanks.
    Michael Sharman
    @michaelsharman
    would I be correct in assuming you could get away with 2 environments?
    one for production
    and the other for dev, qa, test etc
    would it matter to mix the lower level environments all together?