我正在尝试从谷歌课堂名册中提取学生信息。这是我到目前为止所拥有的:
function studentRoster() {
var optionalArgs = {
pageSize: 2
};
var getStudents = Classroom.Courses.Students.list("757828465",optionalArgs).students;
Logger.log(getStudents);
}
桑迪在下面的回答帮助解决了我的部分问题,我将其作为日志(姓名、身份证、电子邮件等已更改):
[16-01-05 17:44:04:734 PST] [{profile={photoUrl= https://lh3.googleusercontent.com/-XdUIqdMkCWA/AAAAAAAAAAI/AAAAAAAAAA/4252rscbv5M/photo.jpg , emailAddress=jsdoe@fjuhsd .org, name={givenName=John, familyName=Doe, fullName=John Doe}, id=108117124004883828162}, courseId=757828465, userId=108117124004883828162}, {profile={photoUrl= https://lh3.googleusercontent.com/ -XdUIqdMkCWA/AAAAAAAAAAI/AAAAAAAAAAAA/4252rscbv5M/photo.jpg , emailAddress=jhdoe@fjuhsd.org, name={givenName=Jane, familyName=Doe, fullName=Jane Doe}, id=115613162385930536688}, courseId=757828465, userId=130563682856363 }]
所以我现在的问题是:如何只提取这些信息的某些部分(如全名和电子邮件)?
最终结果会将其推送到谷歌表格。