server library

Support for doing something awesome.

More dartdocs go here.

Classes

ApiGatewayAuthorizer
ApiGatewayEvent
ApiGatewayRequestContext
AppContract
The base contract definition.
AppStackTrace
AwsALBEvent
Event send by an Application Load Balancer to the invocation to the Lambda.
AwsALBEventContext
AWS ALB Event Request Context ...
AwsALBResponse
Response for a request from an Application Load Balancer. It has to have a statusCode, headers and a body. They should reflect the informationen needed here.
AwsAlexaEvent
Event send by an Application Load Balancer to the invocation to the Lambda.
AwsAlexaEventHeader
Header are meta information about the event.
AwsApiGatewayEvent
API Gateway Event ...
AwsApiGatewayEventHeaders
API Gateway Event Headers ...
AwsApiGatewayEventRequestContext
API Gateway Event Request Context ...
AwsApiGatewayEventRequestContextIdentity
API Gateway Event Identity
AwsApiGatewayResponse
API Gateway Response contains the data for a response to the API Gateway. It contains the body of the HTTP response. It also contains a HTTP Status Code which by default is 200. Furthermore it indicates if the body is Base64 encoded or not.
AwsAppSyncEvent
App Sync Event ...
AwsClaimOverrideDetails
AwsCloudwatchEvent
Event that is send via SQS to trigger for an innovation of a Lambda.
AwsCloudwatchLogEvent
Cloudwatch Log Event ...
AwsCognitoEvent
AwsCognitoRequest
AwsCognitoResponse
AwsDynamoDBUpdateEvent
DynamoDB Update Event ...
AwsDynamoDBUpdateEventRecord
DynamoDB Update Event Record ...
AwsDynamoDBUpdateRecord
Event send by a DynamoDB stream that contains the updated records in the DynamoDB table.
AwsGroupConfiguration
AwsKinesisDataStream
Kinesis .....
AwsKinesisDataStreamEvent
Kinesis Event ...
AwsKinesisDataStreamRecord
Kinesis record that is send via AwsKinesisEvent.
AwsKinesisFirehoseData
Kinesis .....
AwsKinesisFirehoseDataEvent
Kinesis Event ...
AwsS3Bucket
AwsS3Data
AwsS3Event
Representing a recorded S3 Event send to the Lambda. This can be send in batches of operations.
AWSS3EventObject
AwsS3EventRecord
Notifcation Event for Lambda in S3.
AwsS3UserIdentity
AwsSQSEvent
Event that is send via SQS to trigger for an innovation of a Lambda.
AwsSQSEventRecord
SQS Event Record that is send via AwsSQSEvent.
BaseAppApiHandler<TConfig extends BaseServerConfig>
The base API Handler implementation for fulfilling requests.
BaseConfig
The base configuration model
BaseServerConfig
The base server configuration definition
BaseServerRegistry<TConfig extends BaseServerConfig>
The server-side injection registry.
Client
Client is the Lambda Runtime Interface client. It is implemented as a singleton whereby Client.instance always returns the already instantiated client.
CloudFront
CloudFrontConfig
CloudFrontHeaders
CloudFrontOrigin
CloudFrontOriginRequestEvent
CloudFrontOriginResponse
A response message from a CloudFront Origin Request Event
CloudFrontRecords
CloudFrontRequest
CloudFrontRequestBody
ErrorResponse
Event
Event is the abstraction for every event that can be ingested by a handler.
InvocationError
Invocation error occurs when there has been an error in the invocation of a handlers. It dynamically wraps the inner error and attaches the requestId to track it along the event.
InvocationResult
Invocation result is the result that the invoked handler returns and is posted to the Lambda Runtime Interface.
NextInvocation
Next invocation data wraps the data from the invocation endpoint of the Lambda Runtime Interface.
Registry<TConfig extends BaseConfig>
An injection registry.
RequestBase
ResponseBase
Runtime
A Runtime manages the interface to the Lambda API.

Properties

words List<String>
getter/setter pair

Functions

createParagraph({int numSentences = -1, int numParagraphs = 1}) String
Creates random paragraphs.
createSentence({int sentenceLength = -1, int numSentences = 1}) String
Creates random sentences.
createText({int numParagraphs = -1, int numSentences = -1}) String
Creates a text comprised of a number of paragraphs.
createWord({int count = 1}) String
Creates count number of random words.
getHttpReason(int status) String?
makeFakes<T>({required ThingGenerator<T> factory, int count = 20}) List<T>
Generates a non-growable count sized list of the items returned by factory.
randomBool() bool
Generates a random bool value.
randomId([int length = 12]) String
Generates a random alpha-numeric ascii encoded value of the specified length (defaults to 12).
randomInt(int min, int max) int
Generates a random integer between min and max.

Typedefs

ConfigBuilder<T, TConfig extends BaseConfig> = T Function(TConfig config)
The function signature of a configuration-driven factory builder
Handler<E> = Future Function(Context context, E event)
A function which ingests and Event and a Context and returns a InvocationResult. The result is ecoded by the Runtime and posted to the Lambda API.
MissingValueHandler<T> = T? Function(String key)
RandomBool = bool Function()
The shape of a bool producing function.
RandomNumber = int Function(int min, int max)
The shape of a number producing function.
RequestFactory<T extends RequestBase> = T Function(AwsApiGatewayEvent event)
ThingGenerator<T> = T Function(int index, RandomNumber random, RandomBool yesOrNo)
The shape of a T producing function.

Exceptions / Errors

AppError
BadContextError
HttpError
IntegrationError
MissingConfigError
RuntimeException
An exception thrown when there is an error in the runtime.
SecurityError