Hi Rock,

You should be able to reuse the same token for both requests.

Using OAuth Playground I was able to query the 2 feeds using the same
OAuth Token:
http://googlecodesamples.com/oauth_playground/

GET /calendar/feeds/default/private/full HTTP/1.1
Host: www.google.com
Accept: */*
Authorization: OAuth oauth_version="1.0",
oauth_nonce="5b661aa11f4130e8d55faeeca04ec58d",
oauth_timestamp="1310139459",
oauth_consumer_key="googlecodesamples.com",
oauth_token="1%2FB4yA-_habB0Fwb9wbHMkVQcQ0WQF8jRMr_ht74BZkXc",
oauth_signature_method="RSA-SHA1",
oauth_signature="wQah3RLt3Kbr6rWP9GW3LsZ0q%2BH93XnKHAtKodM%2BH6vHH3ueWCJkTaWLfjyrxWa9TBqjGrhiVZ8HkypIjurpQVCu5g2TCHrNCwwZr4TcYKt10wiQJg1umyFag9Gfu23JzMmDMsVpEw7OcULCObcg4lwdEVkEaswsV2iWlxGAjro%3D"
Content-Type: application/atom+xml
GData-Version: 2.0

HTTP/1.1 200 OK

GET /calendar/feeds/default/allcalendars/full HTTP/1.1
Host: www.google.com
Accept: */*
Authorization: OAuth oauth_version="1.0",
oauth_nonce="1d94f9610b029d0dfa294799ac673c28",
oauth_timestamp="1310139486",
oauth_consumer_key="googlecodesamples.com",
oauth_token="1%2FB4yA-_habB0Fwb9wbHMkVQcQ0WQF8jRMr_ht74BZkXc",
oauth_signature_method="RSA-SHA1",
oauth_signature="vglFTUeSKiA6SSjRzpn6LWw3G4d6CPY1%2FjS3s2IXQWIYWDWeCvQuPyBL0oxM%2FerII5nx1sCuPGWvz618Teivvd8QKOA4LJIDprOvYgqkXD2b5QrIq0rsSuIjF0Xkcg2T0%2FjuFSQrr0%2BPi3txJrqbMqvoYLMJ3KM0BsgV3LAQLAs%3D"
Content-Type: application/atom+xml
GData-Version: 2.0

HTTP/1.1 200 OK

Hope that helps.

On Fri, Jul 8, 2011 at 9:36 AM, rock lin <[email protected]> wrote:
>  i've got a token to retrieve all events of a calendar( feedUrl :
> https://www.google.com/calendar/feeds/default/private/full ) and it's done
>
> , but in the same way i want to retrieve all calendars(use the same token i
> got from google), i got an error like that
>
> "GET https://www.google.com/calendar/feeds/default/allcalendars/full.....
>  401 (Authorization required)"
>
> i use javascript to develop.
>
> in the developer guide <
> http://code.google.com/intl/zh-TW/apis/calendar/data/2.0/developers_guide_java.html#Auth>
>            "Retrieving all calendars"
>
>             You can get a list of a user's calendars by sending an
> authenticated GET request to the allcalendars feed URL:
>
>      https://www.google.com/calendar/feeds/default/allcalendars/full
>
>             The result is a feed that includes all primary, secondary, and
> imported calendars.
>
> should i get  another  Authentication of the
> URL:"https://www.google.com/calendar/feeds/default/allcalendars/full";????
>
>
>
> --
> You received this message because you are subscribed to the Google
> Groups "Google Calendar Data API" group.
> To post to this group, send email to
> [email protected]
> To unsubscribe from this group, send email to
> [email protected]
> For more options, visit this group at
> http://code.google.com/apis/calendar/community/forum.html
>



-- 
Johan Euphrosine (proppy)
Developer Programs Engineer
Google Developer Relations

-- 
You received this message because you are subscribed to the Google
Groups "Google Calendar Data API" group.
To post to this group, send email to
[email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://code.google.com/apis/calendar/community/forum.html

Reply via email to