UNPKG

1.41 kBTypeScriptView Raw
1import { Logger } from "@smithy/types";
2import { AwsCredentialIdentity } from "./identity";
3import { Provider } from "./util";
4/**
5 * @public
6 *
7 * An object representing temporary or permanent AWS credentials.
8 *
9 * @deprecated Use {@link AwsCredentialIdentity}
10 */
11export interface Credentials extends AwsCredentialIdentity {
12}
13/**
14 * @public
15 *
16 * @deprecated Use {@link AwsCredentialIdentityProvider}
17 */
18export type CredentialProvider = Provider<Credentials>;
19/**
20 * @public
21 *
22 * Common options for credential providers.
23 */
24export type CredentialProviderOptions = {
25 /**
26 * This logger is only used to provide information
27 * on what credential providers were used during resolution.
28 *
29 * It does not log credentials.
30 */
31 logger?: Logger;
32 /**
33 * Present if the credential provider was created by calling
34 * the defaultCredentialProvider in a client's middleware, having
35 * access to the client's config.
36 *
37 * The region of that parent or outer client is important because
38 * an inner client used by the credential provider may need
39 * to match its default partition or region with that of
40 * the outer client.
41 *
42 * @internal
43 * @deprecated - not truly deprecated, marked as a warning to not use this.
44 */
45 parentClientConfig?: {
46 region?: string | Provider<string>;
47 [key: string]: unknown;
48 };
49};