mirror of
https://github.com/FlipsideCrypto/DefinitelyTyped.git
synced 2026-02-06 10:56:53 +00:00
Dependencies and linting updates
This commit is contained in:
parent
9ef7415615
commit
a626af102f
24
types/nodecredstash/index.d.ts
vendored
24
types/nodecredstash/index.d.ts
vendored
@ -6,7 +6,7 @@
|
||||
/// <reference types="node"/>
|
||||
import * as AWS from 'aws-sdk';
|
||||
|
||||
interface ICredstashConfig {
|
||||
interface CredstashConfig {
|
||||
table?: string;
|
||||
awsOpts?: AWS.KMS.ClientConfiguration;
|
||||
dynamoOpts?: AWS.DynamoDB.ClientConfiguration;
|
||||
@ -14,32 +14,32 @@ interface ICredstashConfig {
|
||||
kmsOpts?: AWS.KMS.ClientConfiguration;
|
||||
}
|
||||
|
||||
interface ICredstashContext {
|
||||
interface CredstashContext {
|
||||
[key: string]: string;
|
||||
}
|
||||
|
||||
interface IPutSecretOptions {
|
||||
interface PutSecretOptions {
|
||||
name: string;
|
||||
secret: string;
|
||||
context: ICredstashContext;
|
||||
context: CredstashContext;
|
||||
digest?: string;
|
||||
version?: number;
|
||||
}
|
||||
|
||||
interface ICredstash {
|
||||
interface Credstash {
|
||||
getHighestVersion: (options: { name: string }) => Promise<AWS.DynamoDB.AttributeMap>;
|
||||
incrementVersion: (options: { name: string }) => Promise<string>;
|
||||
putSecret: (options: IPutSecretOptions) => Promise<AWS.DynamoDB.DocumentClient.PutItemOutput>;
|
||||
decryptStash: (stash: { key: string; }, context?: ICredstashContext) => Promise<AWS.KMS.DecryptResponse>;
|
||||
getAllVersions: (options: { name: string, context?: ICredstashContext, limit?: number }) => Promise<Array<{ version: string; secret: string }>>;
|
||||
getSecret: (options: { name: string, context?: ICredstashContext, version?: number }) => Promise<string>;
|
||||
deleteSecrets: (options: { name: string }) => Promise<Array<AWS.DynamoDB.DocumentClient.DeleteItemOutput>>;
|
||||
putSecret: (options: PutSecretOptions) => Promise<AWS.DynamoDB.DocumentClient.PutItemOutput>;
|
||||
decryptStash: (stash: { key: string; }, context?: CredstashContext) => Promise<AWS.KMS.DecryptResponse>;
|
||||
getAllVersions: (options: { name: string, context?: CredstashContext, limit?: number }) => Promise<Array<{ version: string; secret: string }>>;
|
||||
getSecret: (options: { name: string, context?: CredstashContext, version?: number }) => Promise<string>;
|
||||
deleteSecrets: (options: { name: string }) => Promise<AWS.DynamoDB.DocumentClient.DeleteItemOutput[]>;
|
||||
deleteSecret: (options: { name: string, version: number }) => Promise<AWS.DynamoDB.DocumentClient.DeleteItemOutput>;
|
||||
listSecrets: () => Promise<string[]>;
|
||||
getAllSecrets: (options: { version?: number, context?: ICredstashContext, startsWith?: string }) => Promise<{ [key: string]: string }>;
|
||||
getAllSecrets: (options: { version?: number, context?: CredstashContext, startsWith?: string }) => Promise<{ [key: string]: string }>;
|
||||
createDdbTable: () => Promise<void>;
|
||||
}
|
||||
|
||||
declare function Credstash(config: ICredstashConfig): ICredstash;
|
||||
declare function Credstash(config: CredstashConfig): Credstash;
|
||||
|
||||
export = Credstash;
|
||||
|
||||
6
types/nodecredstash/package.json
Normal file
6
types/nodecredstash/package.json
Normal file
@ -0,0 +1,6 @@
|
||||
{
|
||||
"dependencies": {
|
||||
"aws-sdk": "^2.211.0"
|
||||
},
|
||||
"private": true
|
||||
}
|
||||
@ -7,6 +7,7 @@
|
||||
"noImplicitAny": true,
|
||||
"noImplicitThis": true,
|
||||
"strictNullChecks": true,
|
||||
"strictFunctionTypes": true,
|
||||
"baseUrl": "../",
|
||||
"typeRoots": [
|
||||
"../"
|
||||
|
||||
Loading…
Reference in New Issue
Block a user