| Index: third_party/chrome/idl/experimental_identity.idl
|
| diff --git a/third_party/chrome/idl/experimental_identity.idl b/third_party/chrome/idl/experimental_identity.idl
|
| new file mode 100644
|
| index 0000000000000000000000000000000000000000..625b0cd645cbaf60b738f585654bddb260579c52
|
| --- /dev/null
|
| +++ b/third_party/chrome/idl/experimental_identity.idl
|
| @@ -0,0 +1,52 @@
|
| +// Copyright (c) 2012 The Chromium Authors. All rights reserved.
|
| +// Use of this source code is governed by a BSD-style license that can be
|
| +// found in the LICENSE file.
|
| +
|
| +namespace experimental.identity {
|
| +
|
| + [inline_doc] dictionary TokenDetails {
|
| + // Whether to prompt the user to log in or grant scope permissions (if they
|
| + // have not already done so). Default is false.
|
| + boolean? interactive;
|
| + };
|
| +
|
| + [inline_doc] dictionary WebAuthFlowDetails {
|
| + // The URL that initiates the auth flow.
|
| + DOMString url;
|
| +
|
| + // Whether to launch auth flow in interactive mode. Default is false.
|
| + boolean? interactive;
|
| +
|
| + // Width of the window, if one is shown in interactive mode.
|
| + long? width;
|
| +
|
| + // Height of the window, if one is shown in interactive mode.
|
| + long? height;
|
| +
|
| + // X coordinate of the window, if one is shown in interactive mode.
|
| + long? left;
|
| +
|
| + // Y coordinate of the window, if one is shown in interactive mode.
|
| + long? top;
|
| + };
|
| +
|
| + callback GetAuthTokenCallback = void (optional DOMString token);
|
| + callback LaunchWebAuthFlowCallback = void (optional DOMString responseUrl);
|
| +
|
| + interface Functions {
|
| + // Gets an OAuth2 access token as specified by the manifest.
|
| + //
|
| + // |details| : Token options.
|
| + // |callback| : Called with an OAuth2 access token as specified by the
|
| + // manifest, or undefined if there was an error.
|
| + static void getAuthToken(optional TokenDetails details,
|
| + GetAuthTokenCallback callback);
|
| +
|
| + // Starts an auth flow at the specified URL.
|
| + //
|
| + // |details| : WebAuth flow options.
|
| + // |callback| : Called with the URL redirected back to your application.
|
| + static void launchWebAuthFlow(WebAuthFlowDetails details,
|
| + LaunchWebAuthFlowCallback callback);
|
| + };
|
| +};
|
|
|