public String setGradeURL() { String request = ""; setResources("setGrade"); request = "/" + getResources(); request = ApplicationSettings.EdmodoAPIBase + request; return request; }
public String createTurninURL() { String request = ""; setResources("turnInAssignment"); request = "/" + getResources(); request = ApplicationSettings.EdmodoAPIBase + request; return request; }
public String launchRequest(String launchKey) { String request = ""; setResources("launchRequests"); request = "/" + getResources() + "?" + "api_key=" + getApi_key() + "&launch_key=" + launchKey; request = ApplicationSettings.EdmodoAPIBase + request; return request; }
/* * GET /profiles?api_key=<API_KEY>&access_token=<ACCESS_TOKEN>&user_tokens=["b020c42d1"] */ public String getProfile(List<String> userTokens) { String request = ""; setResources("profiles"); Gson gson = new Gson(); String userTokensJson = gson.toJson(userTokens); request = "/" + getResources() + "?" + "api_key=" + getApi_key() + "&access_token=" + getAccess_token() + "&user_tokens=" + userTokensJson; request = ApplicationSettings.EdmodoAPIBase + request; return request; }
// GET /groups?api_key=<API_KEY>&access_token=<ACCESS_TOKEN>&group_ids=[379557,379562] public String getGroupsInfo(List<Long> groups) { String request = ""; setResources("groups"); Gson gson = new Gson(); String groupJson = gson.toJson(groups); // System.out.println(groupJson); request = "/" + getResources() + "?" + "api_key=" + getApi_key() + "&access_token=" + getAccess_token() + "&group_ids=" + groupJson; request = ApplicationSettings.EdmodoAPIBase + request; return request; }
// GET /members?api_key=<API_KEY>&access_token=<ACCESS_TOKEN>&group_id=379557,456322 public String getMembers(List<Long> groups) { String request = ""; setResources("members"); Gson gson = new Gson(); String groupJson = gson.toJson(groups); groupJson = groupJson.substring(1, groupJson.length() - 1); // System.out.println(groupJson); request = "/" + getResources() + "?" + "api_key=" + getApi_key() + "&access_token=" + getAccess_token() + "&group_id=" + groupJson; request = ApplicationSettings.EdmodoAPIBase + request; return request; }