OSI/MHS Gateway Programmatic Interface (GPI) Reference Manual
Procedure Calls
OSI/MHS Gateway Programmatic Interface (GPI) Reference Manual—522223-001
4-46
GPI_OPEN_
GPI_OPEN_
This procedure establishes a session between a client and the GPI service. You must call 
this procedure to obtain a session identifier before calling any of the object management 
or message transfer procedures. GPI_OPEN_ also provides the identifier of an object 
that describes the environment of the local MTA or gateway. You can examine attributes 
of this object to obtain the information. 
status returned value
INT:value
indicates the outcome of the call. A value of OM-RC-SUCCESS indicates a 
successful call. For additional values of status, see Appendix B, Return Codes
.
gateway-name input
STRING .EXT:ref:32
specifies the name used to configure the GATEWAY object through DSM; that is, 
the name by which the GATEWAY object is added to a specific OSI/MHS object 
hierarchy. 
The name can contain up to 32 alphanumeric characters; shorter names must be 
padded with trailing blanks.
gateway-instance-name input
STRING .EXT:ref:32
specifies a name that uniquely identifies a specific session’s use of a gateway. The 
name serves as a textual tag for the session identifier. gateway-instance-
name can contain up to 32 alphanumeric characters; shorter names must be padded 
with trailing blanks.
Each session should have its own gateway instance name. All gateway instances of 
the same GATEWAY object share the same input and output queues. Although the 
GPI service maintains the gateway instance name, the name has no significance to 
the GPI. You can use the name as a logging or tracing mechanism or for archiving 
or auditing gateway activity.
status := GPI_OPEN_ (  gateway-name    ! I
   ,  gateway-instance-name  ! I
   , session   ! O
   , environment   ! O
   , MHS-mgr-name   ! I
   ,  MHS-mgr-name-length  ! I
   , [ gateway-password ]  ! I
    , [ gateway-password-length ] ) ;  ! I










