User Tools

Site Tools


api1:student:student_group

A good way to manage your students is to gather them into groups on our API. Il will provide you some convenient method to get aggregated results on a group.
A group can represent a class, or a formation session.

 Student Group example

Object resources

Property Type Description
name String Custom data
instance_id Integer The instance this student group belongs to
student_cluster_id Integer The student cluster this student group belongs to
created_at Timestamp The creation date of the object
updated_at Timestamp The last update date of the object

Create (POST)

Method POST
URL /student_groups
Parameters (*Requiered parameters)
Property Type Description
name String Custom data
student_cluster_id Integer The student cluster this student group belongs to
Send the request (JSON input example)
{
	name: "2nd year associates financial services",
	student_cluster_id: 1
}
Get the response (JSON output example)
{
	id : 1,
	name : "2nd year associates financial services",
	student_cluster_id : 1,
	instance_id : 1,
	created_at : 2014-09-17 09:21:03,
	updated_at : 2014-09-17 09:21:03
}

Fetch (GET)

Method GET
URL /student_groups/{student_group_id}

If no student_group_id is provided it will fetch all the Student Groups for your instance.

Get the response (JSON output example)

With ID provided

{
	id : 1,
	name : "2nd year associates financial services",
	student_cluster_id : 1,
	instance_id : 1,
	created_at : 2014-09-17 09:21:03,
	updated_at : 2014-09-17 09:21:03
}

Without ID provided

[{
	id : 1,
	name : « 2nd year associates financial services »,
	student_cluster_id : 1,
	instance_id : 1,
	created_at : 2014-09-17 09:21:03,
	updated_at : 2014-09-17 09:21:03
},
{
	id : 2,
	name : « senior associates financial services »,
	student_cluster_id : 1,
	instance_id : 1,
	created_at : 2014-09-17 09:21:03,
	updated_at : 2014-09-17 09:21:03
}]

EDIT (PUT)

Method PUT
URL /student_groups/{student_group_id}
Editable parameters
Property Type Description/expected values
name String Custom data (<255 chars)
student_cluster_id Integer The student cluster this student group belongs to
Send the request (JSON input example)
{
	name : "No more 2nd year associates financial services"
}
Get the response (JSON output example)

{

id : 1,
name : "No more 2nd year associates financial services",
student_cluster_id : 1,
instance_id : 1,
created_at : 2014-09-17 09:21:03,
updated_at : 2014-09-20 09:21:03

} </code>

api1/student/student_group.txt · Last modified: 2017/10/17 12:28 by maries