Home | History | Annotate | Download | only in webapp

Lines Matching refs:xhr

80   /** @param {XMLHttpRequest} xhr */
81 var onResponse = function(xhr) {
82 if (xhr.status == 200) {
87 var tokens = JSON.parse(xhr.responseText);
95 console.error('Failed to refresh token. Status: ' + xhr.status +
96 ' response: ' + xhr.responseText);
97 onError(remoting.OAuth2Api.interpretXhrStatus_(xhr.status));
108 remoting.xhr.post(remoting.OAuth2Api.getOAuth2TokenEndpoint_(),
128 /** @param {XMLHttpRequest} xhr */
129 var onResponse = function(xhr) {
130 if (xhr.status == 200) {
135 var tokens = JSON.parse(xhr.responseText);
144 console.error('Failed to exchange code for token. Status: ' + xhr.status +
145 ' response: ' + xhr.responseText);
146 onError(remoting.OAuth2Api.interpretXhrStatus_(xhr.status));
157 remoting.xhr.post(remoting.OAuth2Api.getOAuth2TokenEndpoint_(),
172 /** @param {XMLHttpRequest} xhr */
173 var onResponse = function(xhr) {
174 if (xhr.status == 200) {
176 var result = JSON.parse(xhr.responseText);
184 console.error('Failed to get email. Status: ' + xhr.status +
185 ' response: ' + xhr.responseText);
186 onError(remoting.OAuth2Api.interpretXhrStatus_(xhr.status));
190 remoting.xhr.get(remoting.OAuth2Api.getOAuth2ApiUserInfoEndpoint_(),
205 /** @param {XMLHttpRequest} xhr */
206 var onResponse = function(xhr) {
207 if (xhr.status == 200) {
210 console.error('Failed to revoke token. Status: ' + xhr.status +
211 ' response: ' + xhr.responseText);
212 onError(remoting.OAuth2Api.interpretXhrStatus_(xhr.status));
217 remoting.xhr.post(remoting.OAuth2Api.getOAuth2RevokeTokenEndpoint_(),