@effect-aws/client-bedrock-agentcore-control 1.11.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/BedrockAgentCoreControlClientInstance/package.json +6 -0
- package/BedrockAgentCoreControlService/package.json +6 -0
- package/BedrockAgentCoreControlServiceConfig/package.json +6 -0
- package/Errors/package.json +6 -0
- package/LICENSE +19 -0
- package/README.md +58 -0
- package/dist/cjs/BedrockAgentCoreControlClientInstance.d.ts +26 -0
- package/dist/cjs/BedrockAgentCoreControlClientInstance.d.ts.map +1 -0
- package/dist/cjs/BedrockAgentCoreControlClientInstance.js +52 -0
- package/dist/cjs/BedrockAgentCoreControlClientInstance.js.map +1 -0
- package/dist/cjs/BedrockAgentCoreControlService.d.ts +596 -0
- package/dist/cjs/BedrockAgentCoreControlService.d.ts.map +1 -0
- package/dist/cjs/BedrockAgentCoreControlService.js +219 -0
- package/dist/cjs/BedrockAgentCoreControlService.js.map +1 -0
- package/dist/cjs/BedrockAgentCoreControlServiceConfig.d.ts +26 -0
- package/dist/cjs/BedrockAgentCoreControlServiceConfig.d.ts.map +1 -0
- package/dist/cjs/BedrockAgentCoreControlServiceConfig.js +60 -0
- package/dist/cjs/BedrockAgentCoreControlServiceConfig.js.map +1 -0
- package/dist/cjs/Errors.d.ts +21 -0
- package/dist/cjs/Errors.d.ts.map +1 -0
- package/dist/cjs/Errors.js +20 -0
- package/dist/cjs/Errors.js.map +1 -0
- package/dist/cjs/index.d.ts +44 -0
- package/dist/cjs/index.d.ts.map +1 -0
- package/dist/cjs/index.js +56 -0
- package/dist/cjs/index.js.map +1 -0
- package/dist/dts/BedrockAgentCoreControlClientInstance.d.ts +26 -0
- package/dist/dts/BedrockAgentCoreControlClientInstance.d.ts.map +1 -0
- package/dist/dts/BedrockAgentCoreControlService.d.ts +596 -0
- package/dist/dts/BedrockAgentCoreControlService.d.ts.map +1 -0
- package/dist/dts/BedrockAgentCoreControlServiceConfig.d.ts +26 -0
- package/dist/dts/BedrockAgentCoreControlServiceConfig.d.ts.map +1 -0
- package/dist/dts/Errors.d.ts +21 -0
- package/dist/dts/Errors.d.ts.map +1 -0
- package/dist/dts/index.d.ts +44 -0
- package/dist/dts/index.d.ts.map +1 -0
- package/dist/esm/BedrockAgentCoreControlClientInstance.js +25 -0
- package/dist/esm/BedrockAgentCoreControlClientInstance.js.map +1 -0
- package/dist/esm/BedrockAgentCoreControlService.js +192 -0
- package/dist/esm/BedrockAgentCoreControlService.js.map +1 -0
- package/dist/esm/BedrockAgentCoreControlServiceConfig.js +33 -0
- package/dist/esm/BedrockAgentCoreControlServiceConfig.js.map +1 -0
- package/dist/esm/Errors.js +17 -0
- package/dist/esm/Errors.js.map +1 -0
- package/dist/esm/index.js +27 -0
- package/dist/esm/index.js.map +1 -0
- package/dist/esm/package.json +4 -0
- package/package.json +71 -0
- package/src/BedrockAgentCoreControlClientInstance.ts +35 -0
- package/src/BedrockAgentCoreControlService.ts +3229 -0
- package/src/BedrockAgentCoreControlServiceConfig.ts +56 -0
- package/src/Errors.ts +50 -0
- package/src/index.ts +50 -0
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @since 1.0.0
|
|
3
|
+
*/
|
|
4
|
+
import type { BedrockAgentCoreControlClientConfig } from "@aws-sdk/client-bedrock-agentcore-control";
|
|
5
|
+
import * as ServiceLogger from "@effect-aws/commons/ServiceLogger";
|
|
6
|
+
import * as Effect from "effect/Effect";
|
|
7
|
+
import * as FiberRef from "effect/FiberRef";
|
|
8
|
+
import { dual } from "effect/Function";
|
|
9
|
+
import { globalValue } from "effect/GlobalValue";
|
|
10
|
+
import * as Layer from "effect/Layer";
|
|
11
|
+
import type { BedrockAgentCoreControlService } from "./BedrockAgentCoreControlService.js";
|
|
12
|
+
|
|
13
|
+
/**
|
|
14
|
+
* @since 1.0.0
|
|
15
|
+
* @category bedrock-agentcore-control service config
|
|
16
|
+
*/
|
|
17
|
+
const currentBedrockAgentCoreControlServiceConfig = globalValue(
|
|
18
|
+
"@effect-aws/client-bedrock-agentcore-control/currentBedrockAgentCoreControlServiceConfig",
|
|
19
|
+
() => FiberRef.unsafeMake<BedrockAgentCoreControlService.Config>({}),
|
|
20
|
+
);
|
|
21
|
+
|
|
22
|
+
/**
|
|
23
|
+
* @since 1.0.0
|
|
24
|
+
* @category bedrock-agentcore-control service config
|
|
25
|
+
*/
|
|
26
|
+
export const withBedrockAgentCoreControlServiceConfig: {
|
|
27
|
+
(config: BedrockAgentCoreControlService.Config): <A, E, R>(effect: Effect.Effect<A, E, R>) => Effect.Effect<A, E, R>;
|
|
28
|
+
<A, E, R>(effect: Effect.Effect<A, E, R>, config: BedrockAgentCoreControlService.Config): Effect.Effect<A, E, R>;
|
|
29
|
+
} = dual(
|
|
30
|
+
2,
|
|
31
|
+
<A, E, R>(effect: Effect.Effect<A, E, R>, config: BedrockAgentCoreControlService.Config): Effect.Effect<A, E, R> =>
|
|
32
|
+
Effect.locally(effect, currentBedrockAgentCoreControlServiceConfig, config),
|
|
33
|
+
);
|
|
34
|
+
|
|
35
|
+
/**
|
|
36
|
+
* @since 1.0.0
|
|
37
|
+
* @category bedrock-agentcore-control service config
|
|
38
|
+
*/
|
|
39
|
+
export const setBedrockAgentCoreControlServiceConfig = (config: BedrockAgentCoreControlService.Config) =>
|
|
40
|
+
Layer.locallyScoped(currentBedrockAgentCoreControlServiceConfig, config);
|
|
41
|
+
|
|
42
|
+
/**
|
|
43
|
+
* @since 1.0.0
|
|
44
|
+
* @category adapters
|
|
45
|
+
*/
|
|
46
|
+
export const toBedrockAgentCoreControlClientConfig: Effect.Effect<BedrockAgentCoreControlClientConfig> = Effect.gen(
|
|
47
|
+
function*() {
|
|
48
|
+
const { logger: serviceLogger, ...config } = yield* FiberRef.get(currentBedrockAgentCoreControlServiceConfig);
|
|
49
|
+
|
|
50
|
+
const logger = serviceLogger === true
|
|
51
|
+
? yield* ServiceLogger.toClientLogger(ServiceLogger.defaultServiceLogger)
|
|
52
|
+
: (serviceLogger ? yield* ServiceLogger.toClientLogger(ServiceLogger.make(serviceLogger)) : undefined);
|
|
53
|
+
|
|
54
|
+
return { logger, ...config };
|
|
55
|
+
},
|
|
56
|
+
);
|
package/src/Errors.ts
ADDED
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
import type {
|
|
2
|
+
AccessDeniedException,
|
|
3
|
+
ConcurrentModificationException,
|
|
4
|
+
ConflictException,
|
|
5
|
+
DecryptionFailure,
|
|
6
|
+
EncryptionFailure,
|
|
7
|
+
InternalServerException,
|
|
8
|
+
ResourceLimitExceededException,
|
|
9
|
+
ResourceNotFoundException,
|
|
10
|
+
ServiceException,
|
|
11
|
+
ServiceQuotaExceededException,
|
|
12
|
+
ThrottledException,
|
|
13
|
+
ThrottlingException,
|
|
14
|
+
UnauthorizedException,
|
|
15
|
+
ValidationException,
|
|
16
|
+
} from "@aws-sdk/client-bedrock-agentcore-control";
|
|
17
|
+
import type { TaggedException } from "@effect-aws/commons/Errors";
|
|
18
|
+
|
|
19
|
+
export const AllServiceErrors = [
|
|
20
|
+
"AccessDeniedException",
|
|
21
|
+
"ConcurrentModificationException",
|
|
22
|
+
"ConflictException",
|
|
23
|
+
"DecryptionFailure",
|
|
24
|
+
"EncryptionFailure",
|
|
25
|
+
"InternalServerException",
|
|
26
|
+
"ResourceLimitExceededException",
|
|
27
|
+
"ResourceNotFoundException",
|
|
28
|
+
"ServiceException",
|
|
29
|
+
"ServiceQuotaExceededException",
|
|
30
|
+
"ThrottledException",
|
|
31
|
+
"ThrottlingException",
|
|
32
|
+
"UnauthorizedException",
|
|
33
|
+
"ValidationException",
|
|
34
|
+
] as const;
|
|
35
|
+
|
|
36
|
+
export type AccessDeniedError = TaggedException<AccessDeniedException>;
|
|
37
|
+
export type ConcurrentModificationError = TaggedException<ConcurrentModificationException>;
|
|
38
|
+
export type ConflictError = TaggedException<ConflictException>;
|
|
39
|
+
export type DecryptionError = TaggedException<DecryptionFailure>;
|
|
40
|
+
export type EncryptionError = TaggedException<EncryptionFailure>;
|
|
41
|
+
export type InternalServerError = TaggedException<InternalServerException>;
|
|
42
|
+
export type ResourceLimitExceededError = TaggedException<ResourceLimitExceededException>;
|
|
43
|
+
export type ResourceNotFoundError = TaggedException<ResourceNotFoundException>;
|
|
44
|
+
export type ServiceError = TaggedException<ServiceException>;
|
|
45
|
+
export type ServiceQuotaExceededError = TaggedException<ServiceQuotaExceededException>;
|
|
46
|
+
export type ThrottledError = TaggedException<ThrottledException>;
|
|
47
|
+
export type ThrottlingError = TaggedException<ThrottlingException>;
|
|
48
|
+
export type UnauthorizedError = TaggedException<UnauthorizedException>;
|
|
49
|
+
export type ValidationError = TaggedException<ValidationException>;
|
|
50
|
+
export type SdkError = TaggedException<Error & { name: "SdkError" }>;
|
package/src/index.ts
ADDED
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @since 1.0.0
|
|
3
|
+
*/
|
|
4
|
+
import { BedrockAgentCoreControlService } from "./BedrockAgentCoreControlService.js";
|
|
5
|
+
|
|
6
|
+
/**
|
|
7
|
+
* @since 1.0.0
|
|
8
|
+
*/
|
|
9
|
+
export * from "./Errors.js";
|
|
10
|
+
|
|
11
|
+
/**
|
|
12
|
+
* @since 1.0.0
|
|
13
|
+
*/
|
|
14
|
+
export * as BedrockAgentCoreControlClientInstance from "./BedrockAgentCoreControlClientInstance.js";
|
|
15
|
+
|
|
16
|
+
/**
|
|
17
|
+
* @since 1.0.0
|
|
18
|
+
*/
|
|
19
|
+
export * as BedrockAgentCoreControlServiceConfig from "./BedrockAgentCoreControlServiceConfig.js";
|
|
20
|
+
|
|
21
|
+
/**
|
|
22
|
+
* @since 1.0.0
|
|
23
|
+
*/
|
|
24
|
+
export * from "./BedrockAgentCoreControlService.js";
|
|
25
|
+
|
|
26
|
+
/**
|
|
27
|
+
* @since 1.0.0
|
|
28
|
+
* @category exports
|
|
29
|
+
* @alias BedrockAgentCoreControlService
|
|
30
|
+
*/
|
|
31
|
+
export declare namespace BedrockAgentCoreControl {
|
|
32
|
+
/**
|
|
33
|
+
* @since 1.0.0
|
|
34
|
+
* @alias BedrockAgentCoreControlService.Config
|
|
35
|
+
*/
|
|
36
|
+
export type Config = BedrockAgentCoreControlService.Config;
|
|
37
|
+
|
|
38
|
+
/**
|
|
39
|
+
* @since 1.0.0
|
|
40
|
+
* @alias BedrockAgentCoreControlService.Type
|
|
41
|
+
*/
|
|
42
|
+
export type Type = BedrockAgentCoreControlService.Type;
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
/**
|
|
46
|
+
* @since 1.0.0
|
|
47
|
+
* @category exports
|
|
48
|
+
* @alias BedrockAgentCoreControlService
|
|
49
|
+
*/
|
|
50
|
+
export const BedrockAgentCoreControl = BedrockAgentCoreControlService;
|