background image

 

 

 

IP Office CTI Link 

DevLink Programmer’s Guide 

  

40DHB0002UKAD Issue 11a (14th June 2005) 

Summary of Contents for IP Office CTI Link

Page 1: ...IP Office CTI Link DevLink Programmer s Guide 40DHB0002UKAD Issue 11a 14th June 2005 ...

Page 2: ......

Page 3: ...h Borland Delphi 6 Connecting to an IP Office using DevLink 7 Connecting 7 Example Connecting to IP Office in C 8 Example Connecting to IP Office in Delphi 9 Disconnecting 10 DevLink Real Time Event Stream 11 DevLink Real Time Event Stream 11 S events 12 Field 25 Cause Codes 15 D events 16 A events 16 DevLink reference 17 Functions 17 DLOpen 17 DLClose 18 DLRegisterType2CallDeltas 19 Callbacks 20 ...

Page 4: ......

Page 5: ...make call transfer and provides CLI ANI for screen popping Please see the TAPILink Developers Guide for more details on TAPILink Lite and TAPILink Pro Note that the first version of CTI Link Lite contained DevLink Lite DevLink version 1 0 0 3 which provided a Call Logging interface This has been superseded by IP Office SMDR which is available on the IP Office 1 3 Admin CD DevLink version 1 0 0 4 n...

Page 6: ...vLink header file devlink h and appropriate library file devlink lib or devlinkomf lib should be copied to the same directory as the project source files The devlink lib library file contains export symbols in COFF format which can be used with projects written in Visual C The devlinkomf lib library file contains export symbols in OMF format for other linkers Using the DevLink DLL DEVLINK DLL can ...

Page 7: ...ffice system unit A value of 255 255 255 255 can be used in which case DevLink will broadcast to locate an IP Office system unit Notes 1 If DevLink is being used to control more than one IP Office system at the same time then the specific IP address of the IP Office must be used 2 The cb parameter Communications Status Callback is required and must not be set to NULL The return result from DLOpen ...

Page 8: ...n lost rebooted fall through case DEVLINK_COMMS_REJECTED incorrect system password specified if bStarting dwCommsEvent comms_evt SetEvent hEvent else insert your code here break case DEVLINK_COMMS_MISSEDPACKETS Indicates that the system is under heavy load IP Office always prioritises data routing and call handling above CTI events parm1 contains the number of packets missed break int main int arg...

Page 9: ... uses devlink R DFM var hEvent THANDLE dwCommsEvent DWORD bStarting boolean procedure HandleCommsEvent pbxh LongInt Comms_status DWORD Parm1 DWORD stdcall begin case Comms_status of DEVLINK_COMMS_OPERATIONAL DEVLINK_COMMS_NORESPONSE DEVLINK_COMMS_REJECTED begin if bStarting then begin dwCommsEvent comms_status SetEvent hEvent end end DEVLINK_COMMS_MISSEDPACKETS begin parm1 indicates the number of ...

Page 10: ...ShowMessage Error connecting to IP Office end end procedure TForm1 Button2Click Sender TObject begin DLClose 0 CloseHandle hEvent end end Disconnecting To disconnect from IP Office use the DLClose routine passing the same application supplied handle that was used to open the connection LONG PASCAL DLClose LONG pbxh ...

Page 11: ...Sig or VoIP line and the IP Office decides to swap the A end and the B end of the call Examples of when this may happen include When a parked party hangs up When an outgoing call is transferred When a call is un parked The format and information contained in these events are described in more detail below Applications request information real time events by calling the DLRegisterCallDelta2 functio...

Page 12: ... see above for values If there is no B end this will be 0 Idle 5 Aconnected Number 0 indicates not connected to the switch e g If receiving dialtone 6 A is music Number Indicates whether the A end of the call is listening to music on hold 7 Bconnected Number As in field 5 above but for the B end 8 B is music Number Indicates whether the B end of the call is listening to music on hold 9 Aname Strin...

Page 13: ...mbers 1 call type e g speech video and 2 the transport type 0 circuit 2 packet The format of the string is Number Number 29 Owner hunt group name String The name of the hunt group where the call is currently queued 30 Original hunt group name String The name of the hunt group where the call was originally targeted 31 Original user name String The name of the user where the call was originally targ...

Page 14: ...Programmer s Guide Page 14 IP Office CTI Link 40DHB0002UKAD Issue 11a 14th June 2005 used 48 Service quota time Number The service quota time 49 Account code String The account code of the call if any 50 CallID Number Unique call id ...

Page 15: ... return timeout 116 CMCauseE911Emergency 117 CMCauseParked 118 CMCauseUnParked 119 CMCausePickup 120 CMCauseReminder A held or parked call is returning due to a hold park timeout 121 CMCauseRedirect The call has been redirected 122 CMCauseCallBarred The call was barred 123 CMCauseForwardToVoicemail The call has been forwarded to voicemail 124 CMCauseAnsweredByOther The call has been answered by so...

Page 16: ...end of the call 2 B call id String Call id for the B end of the call 3 CallID Number Unique call id A events A events indicate that the call ends have been swapped This occurs for example when the originating extension unparks an external call The format of an A event is very similar to that for a D event CALL A field1 field2 field3 The fields are Field Name Type Description 1 A call id String Cal...

Page 17: ... unit here pbx_password The password of the IP Office system reserved1 This parameter should be set to NULL nil in Delphi reserved2 This parameter should be set to NULL nil in Delphi cb This is the address of a call back function to which connection status events will be sent This parameter is mandatory Return value This routine may return either 0 DEVLINK_SUCCESS or 1 DEVLINK_UNSPECIFIEDFAIL Note...

Page 18: ...ect from an IP Office system Parameters pbxh A number used to identify the system This is the user supplied parameter used to connect to DevLink in the call to DLOpen Return value This routine may return 0 DEVLINK_SUCCESS or 1 DEVLINK_UNSPECIFIEDFAIL in the event of an error C C LONG PASCAL DLClose LONG pbxh Delphi function DLClose pbxh LongInt LongInt stdcall ...

Page 19: ...ess of the callback function that will receive real time events Only one callback can receive real time events at one time and if this parameter is NULL then real time events will no longer be sent to the application Return value This routine may return 0 DEVLINK_SUCCESS 1 DEVLINK_UNSPECIFIEDFAIL Returned in the event of an error 2 DEVLINK_LICENCENOTFOUND If no CTI licence is activated on the IP O...

Page 20: ...1 No response from system unit This occurs either after the initial call to DLOpen or if the system unit is powered off or rebooted It can also occur if network problems prevent communications DEVLINK_COMMS_REJECTED 2 Reserved for future use DEVLINK_COMMS_MISSEDPACKETS 3 Packets were generated by the IP Office system unit but were not received by DevLink This can occur either because the IP Office...

Page 21: ...quired for returning Delta2 events Parameters pbxh A number used to identify the system This is the user supplied parameter used to connect to the IP Office system unit in DLOpen info Text string containing the event Please see the previous section on real time events for more details Return value No return value C C typedef void CALLBACK CALLLOGEVENT Long pbxh TEXT info Delphi type TCallLogEvent ...

Page 22: ......

Page 23: ...CENOTFOUND 2 const DEVLINK_COMMS_OPERATIONAL 0 DEVLINK_COMMS_NORESPONSE 1 DEVLINK_COMMS_REJECTED 2 DEVLINK_COMMS_MISSEDPACKETS 3 type TCallLogEvent procedure pbxh LongInt info PChar stdcall type TCommsEvent procedure pbxh LongInt Comms_status DWORD Parm1 DWORD stdcall function DLOpen pbxh LongInt pbx_address PChar pbx_password PChar reserved1 PChar reserved2 PChar cb TCommsEvent LongInt stdcall fu...

Page 24: ...fine DEVLINK_SUCCESS 0 define DEVLINK_UNSPECIFIEDFAIL 1 define DEVLINK_LICENCENOTFOUND 2 define DEVLINK_COMMS_OPERATIONAL 0 define DEVLINK_COMMS_NORESPONSE 1 define DEVLINK_COMMS_REJECTED 2 define DEVLINK_COMMS_MISSEDPACKETS 3 ifdef __cplusplus extern C endif typedef void CALLBACK CALLLOGEVENT LONG pbxh TEXT info typedef void CALLBACK COMMSEVENT LONG pbxh DWORD comms_state DWORD parm1 LONG PASCAL ...

Page 25: ... 19 20 21 23 DevLink DLL uses 6 Using 6 DevLink DLL 6 DevLink Lite 5 DevLink Pro 5 DevLink Real Time Event Stream 11 DEVLINK DLL 6 23 DEVLINK H 6 8 24 DEVLINK H file contains 6 DEVLINK H file 6 Devlink lib link 6 Devlink lib 6 DEVLINK PAS 6 23 DEVLINK PAS file contains 6 DEVLINK PAS file 6 23 DEVLINK_COMMS_ MISSEDPACKETS 8 9 20 23 24 DEVLINK_COMMS_ NORESPONSE 8 9 20 23 24 DEVLINK_COMMS_ OPERATIONA...

Page 26: ...ar 17 21 23 Printf 8 Prioritises 8 Pro 5 6 Program Files Avaya IP Office DEV Link 6 Q QSig 11 R R 9 Real time 6 Receiving dialtone 12 Receiving 12 Redialling 12 Refer IP Office CTI Link Installation Manual 6 Refer 6 Releases IP Office 12 Releases 12 Reserved1 7 17 23 24 Reserved2 7 17 23 24 Returning Delta2 21 Returning 19 21 S S 11 12 S events 12 SDK 5 See TAPILink Developers Guide 5 See 5 Set NU...

Page 27: ......

Page 28: ... others Intellectual property related to this product including trademarks and registered to Lucent Technologies have been transferred or licensed to Avaya All trademarks identified by the or are registered trademarks or trademarks respectively of Avaya Inc All other trademarks are the property of their respective owners This document contains proprietary information of Avaya and is not to be disc...

Reviews: