Google Batch permissions request return success but no permission granted for users -


i have create multiple user permissions single folder using drive rest api. if requests (more one) continuously each user (because document list api batchacl deprecated) returns permissionids every user of time 1 user granted permission. caused errors in application. moved google batch requests , request postbody generated this,

        var postbody = "";         dataobj.users.foreach(function (entry) {              var batchbody = {role: entry.role, type: "user", value: entry.email };             batchbody = json.stringify(batchbody);             postbody = postbody.concat("--batch_", collectionid, "\n");             postbody = postbody.concat("content-type: application/http \n");             postbody = postbody.concat("content-id: ", entry.email, "\n");             postbody = postbody.concat("content-transfer-encoding: binary \n");             postbody = postbody.concat("post /drive/v2/files/", collectionid, "/permissions \n");             postbody = postbody.concat("content-type: application/json \n");             postbody = postbody.concat("content-length: ", batchbody.length, " \n");             postbody = postbody.concat(batchbody, " \n");         });          postbody = postbody.concat("--batch_", collectionid, "--"); 

it returns success 200 , response body this,

--batch_vffepoyzl9q_aaypevhdvni--  --batch_vffepoyzl9q_aaypevhdvni-- 

but no permission granted user. , response body shouldn't per google documentation. can me find problem or guidance use "google-api-nodejs-client" same batch request?


Comments

Popular posts from this blog

cakephp - simple blog with croogo -

How to group boxplot outliers in gnuplot -

bash - Performing variable substitution in a string -