3.828.0 • Published 4 months ago
@aws-sdk/dsql-signer v3.828.0
@aws-sdk/dsql-signer
Description
This package provides utilities for interacting with Dsql.
Installation
npm install @aws-sdk/dsql-signer
Getting Started
Import
ES6 import
import { DsqlSigner } from "@aws-sdk/dsql-signer";
Or CommonJS import
const { DsqlSigner } = require("@aws-sdk/dsql-signer");
Generate Authentication Token for Dsql IAM Authentication
const signer = new DsqlSigner({
/**
* Required: The hostname of the database to connect to.
*/
hostname: "foo0bar1baz2quux3quux4.dsql.us-east-1.on.aws";
/**
* Optional: The region the database is located in. Uses the region inferred from the runtime if omitted.
*/
region?: "us-east-1";
/**
* Optional: The SHA256 hasher constructor to sign the request.
*/
sha256?: HashCtor;
/**
* Optional: The amount of time in seconds the generated token is valid
*/
expiresIn?: 3600;
/**
* Optional: The AWS credentials to sign requests with. Uses the default credential provider chain if not specified.
*/
credentials?: fromNodeCredentialProvider();
});
// Creates auth token.
const authToken = await signer.getDbConnectAuthToken();
// Creates admin auth token.
const adminAuthToken = await signer.getDbConnectAdminAuthToken();
// Use the token as the password for connecting to your Dsql instance.
3.828.0
4 months ago
3.826.0
4 months ago
3.825.0
4 months ago
3.823.0
5 months ago
3.821.0
5 months ago
3.817.0
5 months ago
3.816.0
5 months ago
3.812.0
5 months ago
3.810.0
5 months ago
3.808.0
5 months ago
3.806.0
5 months ago
3.804.0
5 months ago
3.803.0
6 months ago
3.799.0
6 months ago
3.798.0
6 months ago
3.797.0
6 months ago
3.796.0
6 months ago
3.787.0
6 months ago
3.782.0
7 months ago
3.778.0
7 months ago
3.777.0
7 months ago
3.775.0
7 months ago
3.774.0
7 months ago
3.772.0
7 months ago
3.768.0
7 months ago
3.758.0
8 months ago
3.750.0
8 months ago
3.749.0
8 months ago
3.744.0
8 months ago
3.743.0
8 months ago
3.742.0
9 months ago
3.741.0
9 months ago
3.738.0
9 months ago
3.734.0
9 months ago
3.733.0
9 months ago
3.731.1
9 months ago
3.731.0
9 months ago
3.730.0
9 months ago
3.729.0
9 months ago
3.726.1
9 months ago
3.726.0
9 months ago
3.723.0
9 months ago
3.721.0
10 months ago
3.716.0
10 months ago
3.715.0
10 months ago
3.714.0
10 months ago
3.713.0
10 months ago
3.712.0
10 months ago
3.709.0
10 months ago
3.705.0
11 months ago