SkyDrive Result to Object
-
jeudi 23 février 2012 12:46
Hi,
How to turn the result below from skydrive to an Object?
I need to loop thru below and get Folder ID and make a request to get the Files within the folder using REST.
thanks
{
"data": [
{
"id": "folder.b16fb993939aa9b4.B16FB993939AA9B4!104",
"from": {
"name": "XXXXXXXXXXXXXX",
"id": "000000000000000"
},
"name": "Pictures",
"description": null,
"parent_id": "folder.00000000000000",
"upload_location": "https://apis.live.net/v5.0/folder.b16fb993939aa9b4.B16FB993939AA9B4!104/files/",
"is_embeddable": true,
"count": 0,
"link": "https://skydrive.live.com/redir.aspx?cid\u003db16fb993939aa9b4\u0026page\u003dview\u0026resid\u003dB16FB993939AA9B4!104\u0026parid\u003dB16FB993939AA9B4!103",
"type": "album",
"shared_with": {
"access": "Just me"
},
"created_time": "2012-02-13T16:11:17+0000",
"updated_time": "2012-02-13T16:11:17+0000"
}, {
"id": "folder.b16fb993939aa9b4.B16FB993939AA9B4!106",
"from": {
"name": "XXXXXXXXXXXXXX",
"id": "000000000000000"
},
"name": "Documents",
"description": null,
"parent_id": "folder.000000000000000000",
"upload_location": "https://apis.live.net/v5.0/folder.00000000000000000.B16FB993939AA9B4!106/files/",
"is_embeddable": true,
"count": 0,
"link": "https://skydrive.live.com/redir.aspx?cid\u003db16fb993939aa9b4\u0026page\u003dview\u0026resid\0000000000000000000!106\u0026parid\u003dB16FB993939AA9B4!103",
"type": "folder",
"shared_with": {
"access": "Just me"
},
"created_time": "2012-02-13T16:11:17+0000",
"updated_time": "2012-02-13T16:11:17+0000"
}, {
"id": "folder.00000000000000000.B16FB993939AA9B4!105",
"from": {
"name": "XXXXXXXXXXXXXXXXX",
"id": "000000000000000000"
},
"name": "Public",
"description": null,
"parent_id": "folder.000000000000000000",
"upload_location": "https://apis.live.net/v5.0/folder.0000000000000000.B16FB993939AA9B4!105/files/",
"is_embeddable": true,
"count": 1,
"link": "https://skydrive.live.com/redir.aspx?cid\0000000000000000000\u0026page\u003dview\u0026resid\000000000000000000!105\u0026parid\u003dB16FB993939AA9B4!103",
"type": "folder",
"shared_with": {
"access": "Everyone (public)"
},
"created_time": "2012-02-13T16:11:17+0000",
"updated_time": "2012-02-16T15:18:07+0000"
}
]
}
Toutes les réponses
-
jeudi 23 février 2012 21:00Modérateur
Hello,
id: represents the top folder ID and upload_location gives you the top folder location. You may use me/skydrive/files or USER_ID/skydrive/files to get the details of the contents of the Top folder.
-
vendredi 24 février 2012 19:06What is it that you're trying to do?
-
lundi 27 février 2012 13:33
Hi I am trying to download a shared files. I have an app which goes thru outlook email items and if there is a skydrive doc. the app will download it automatically. I already done the sign in bit and tokens.
I am not sure if the link below has a file id in it.
I have modified some numbers below so the link won't be valid.
<https://skydrive.live.com/redir.aspx?cid=62d32a233344434127dc5eb&page=view&resid=6
2D34454546127DC5EB%21138&parid=62D32A2613445C5EB%21137&authkey=%21AEOcpmvVS0iWZK
Y&Bpub=SDX.SkyDrive&Bsrc=SkyMail>
<https://skydrive.live.com/redir.aspx?cid=62d34455a26127dc5eb&page=view&resid=6
2D32A223344427DC5EB%21138&parid=62D324545435427DC5EB%21137&authkey=%21AEOcpmvVS0iWZK
Y&Bpub=SDX.SkyDrive&Bsrc=SkyMail> -
lundi 27 février 2012 13:34
basically i just want to download a skydrive file using REST.
the sample link above is what's sent to us. thanks
-
mardi 28 février 2012 01:38Where are you getting those links? They do not resemble anything that the Live Connect APIs should be returning... Who is generating the content for the emails you're scanning?
-
mardi 28 février 2012 11:37
i think the link is generated from the skydrive.
can you download a file from a skydrive using REST?
what do i need to use to convert the result above into an object?
I just need to extract the Folder ID. I tried using
DataContractJsonSerializer
- Modifié EvoLiveSDK mardi 28 février 2012 11:39
-
mardi 28 février 2012 18:51
All SkyDrive IDs that the Live Connect APIs use should be treated as opaque strings and we do not support any scenarios involving generating them yourself.- Marqué comme réponse Dare Obasanjo - MSFT vendredi 2 mars 2012 13:13

