| 1234567891011121314151617181920212223242526272829 |
- @startuml
- participant ChargeStation as cs
- participant CrazyCarge as cc
- autonumber
- note over cs, cc
- ChargeStation(CS) requesting CrazyCharge(CC) webhook
- vice versa with CrazyCharge requesting ChargeStation API
- end note
- cs -> cc ++: Request Access token with payload \nOperatorID & OperatorSecret
- cc -> cs --: Response Access token
- activate cs
- cs -> cs: Encrypt Data using AES with \n`DataSecret` & `DataSecretIV`
- cs -> cs: Sign using HMAC-MD5 with \nOperatorSecret+Data+TimeStamp+Seq
- cs -> cs: Encrypt payload using RSA with \npublic_key.pem
- cs->cc: Request webhooks with encrypted payload
- deactivate
- activate cc
- cc -> cc: Decrypt payload using RSA with \nprivate_key.pem
- cc -> cc: Verify signature using HMAC-MD5
- cc -> cc: Decrypt Data using AES
- cc -> cs: Response Success
- deactivate
|