CtrlK
BlogDocsLog inGet started
Tessl Logo

tessl/npm-aws-sdk--client-sts

AWS SDK for JavaScript STS Client for Node.js, Browser and React Native, providing temporary security credentials and role assumption capabilities

92

1.05x

Evaluation92%

1.05x

Agent success when using this tile

Overview
Eval results
Files

task.mdevals/scenario-9/

Multi-Source Credential Provider

A credential provider system that retrieves AWS credentials from multiple custom sources with fallback support.

Capabilities

Implements custom credential provider

  • Creating a custom credential provider that retrieves credentials from environment variables with a custom prefix (CUSTOM_AWS_KEY_ID, CUSTOM_AWS_SECRET_KEY) returns valid credentials when these variables are set. @test
  • The custom provider throws an error when the required environment variables are not set. @test

Implements credential provider chain

  • Creating a credential provider chain with multiple providers attempts each provider in order until credentials are found. @test
  • The provider chain returns credentials from the first successful provider. @test
  • The provider chain throws an error when all providers in the chain fail. @test

Integrates with AWS SDK client

  • An S3 client configured with the custom credential provider chain successfully authenticates and can be instantiated without errors. @test

Implementation

@generates

API

import { AwsCredentialIdentity, AwsCredentialIdentityProvider } from "@aws-sdk/types";

/**
 * Creates a custom credential provider that reads from custom environment variables.
 *
 * @returns An AWS credential identity provider function
 * @throws Error when required environment variables are not set
 */
export function customEnvCredentialProvider(): AwsCredentialIdentityProvider;

/**
 * Creates a credential provider chain that tries multiple providers in sequence.
 *
 * @param providers - Array of credential providers to try in order
 * @returns An AWS credential identity provider function that implements fallback logic
 * @throws Error when all providers fail to provide credentials
 */
export function createCredentialChain(
  providers: AwsCredentialIdentityProvider[]
): AwsCredentialIdentityProvider;

Dependencies { .dependencies }

AWS SDK Types { .dependency }

Provides TypeScript type definitions for AWS SDK credential identities and providers.

@satisfied-by

AWS SDK S3 Client { .dependency }

Provides S3 client for testing credential provider integration.

@satisfied-by

Install with Tessl CLI

npx tessl i tessl/npm-aws-sdk--client-sts

tile.json