@startuml Sequence Diagram - Images 'Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. 'SPDX-License-Identifier: MIT (For details, see https://github.com/awslabs/aws-icons-for-plantuml/blob/master/LICENSE) ' Uncomment the line below for "dark mode" styling '!$AWS_DARK = true !define AWSPuml https://raw.githubusercontent.com/awslabs/aws-icons-for-plantuml/v23.1/dist !include AWSPuml/AWSCommon.puml !include AWSPuml/AWSExperimental.puml !include AWSPuml/Compute/Lambda.puml !include AWSPuml/NetworkingContentDelivery/APIGateway.puml !include AWSPuml/General/Internetalt1.puml !include AWSPuml/General/User.puml !include AWSPuml/Database/DynamoDB.puml 'Hide the bottom boxes / Use filled triangle arrowheads hide footbox skinparam style strictuml skinparam MaxMessageSize 200 participant "$UserIMG()\nUser" as user box AWS Cloud 'Instead of using ...Participant(), native creole img tags can be used participant "$APIGatewayIMG()\nCredit Card System\nAll methods are POST" as api << REST API >> participant "$LambdaIMG()\nAuthorizeCard\nReturns status" as lambda << python3.9 >> participant "PaymentTransactions\n$DynamoDBIMG()\nsortkey=transaction_id+token" as db << on-demand >> endbox participant "Authorizer\nReturns status and token\n$Internetalt1IMG()" as processor 'Use shortcut syntax for activation with colored lifelines and return keyword user -> api++ $AWSColor(ApplicationIntegration): <$Callout_1> Process transaction\l<$Callout_SP> ""POST /prod/process"" api -> lambda++ $AWSColor(Compute): <$Callout_2> Invokes lambda with\l<$Callout_SP> cardholder details lambda -> processor++ $AWS_COLOR_SQUID: <$Callout_3> Submit via API token\l<$Callout_SP> card number, expiry, CID processor -> processor: Validate and\lcreate token return status code, token lambda ->> db: PUT transaction id, token return status code,\rtransaction id return status code @enduml