billstclair / elm-dynamodb / DynamoDB.Types

Types for DynamoDB module

Types


type alias TableName =
String

The name of a DynamoDB table.


type Key
    = SimpleKey (( String, AttributeValue ))
    | CompositeKey (( String, AttributeValue )) (( String, AttributeValue ))

A key for a database item.


type alias Item =
Dict String AttributeValue

An item in a database.


type AttributeValue
    = BinaryValue String
    | BoolValue Basics.Bool
    | BinarySetValue (List String)
    | ListValue (List AttributeValue)
    | MapValue (Dict String AttributeValue)
    | NumberValue Basics.Float
    | NumberSetValue (List Basics.Float)
    | NullValue
    | StringValue String
    | StringSetValue (List String)

A value in a database key or item.

See: https://docs.aws.amazon.com/amazondynamodb/latest/APIReference/API_AttributeValue.html


type Error
    = HttpError Http.Error
    | AWSError AWS.Http.AWSAppError
    | DecodeError String

Errors returned from S3 operations

HttpError is from the standard Elm Http module.

AWSError is from the AWS.Http module.

DecodeError denotes a Decoder error in parsing DynamoDB account info.


type alias Account =
{ name : String
, region : Maybe String
, accessKey : String
, secretKey : String
, tableName : TableName 
}

Information about a DynamoDB account