@startuml

skinparam {
  shadowing false
}

!u="<color:blue><&person><color:black>"
!p="<color:red><&people><color:black>"

actor "CPM User" as TESTER
rectangle "CPM Prod" as CPM_ENV {
  rectangle "CPM u p" as CPM
}
rectangle "Vista Site" as VISTA_SITE {
  rectangle "CPRS u p" as CPRS
  rectangle "Vista u p" as VISTA
  CPRS . VISTA
}

rectangle "DSVA Prod" as DSVA_ENV {
  rectangle "Gateway" as GW
  rectangle "OAuth Proxy" as AUTH
}

rectangle "IAM PROD" as SSOI_ENV {
  rectangle "SSOi u" as SSOi
}

rectangle "MPI Prod" as MPI_ENV {
  rectangle "MPI p" as MPI
}

rectangle "DVP Production" as DVP_ENV {
 rectangle "Clinical Health API" as CHAPI
 rectangle "Data Query" as DQ
 rectangle "Vista FHIR Query" as VFQ
 rectangle "Charon" as CHARON
}

database "CDW p" as CDW

TESTER --> CPM : view p
TESTER ---> CPRS : login as u

CPM --> GW : u+p
'CPM -[#blue]-> SSOi
AUTH -[#blue]-> SSOi : u
AUTH -[#blue]-> CHARON : u

GW --> CHAPI : u+p
CHAPI --> VFQ : u+p
CHAPI ----> DQ : u+p
DQ --> CDW : p
DQ -[#blue]-> AUTH : u
VFQ --> CHARON : p
VFQ -[#blue]-> AUTH : u
CHARON -up-> VISTA: p
CHARON -[#blue]up-> VISTA: u
CHARON --> MPI: p

GW .[hidden]. AUTH

legend
<color:blue>___ authentication/authorization
<color:maroon>___ data
u user
p patient data
end legend



@enduml