" /> How to update the record in OCS form GVP. - Genesys CTI User Forum

Author Topic: How to update the record in OCS form GVP.  (Read 8058 times)

Offline Kirill

  • Newbie
  • *
  • Posts: 26
  • Karma: 0
How to update the record in OCS form GVP.
« on: September 07, 2010, 12:54:50 PM »
Advertisement
Hello.
I was having problems with the transfer of information from OCS to GVP. http://www.sggu.com/smf/index.php/topic,5837.0.html
Now i transfer all information through Attached Data, i can see correct Attached Data in the OCS log, but i dont know how to update OCS with that data..
For example: I have a field user_response in the calling list, in Composer startegy i assign the value to the user_response variable/ And the, with help of Interaction Data block, i send it to the OCS. In the OCS log i see correct Attached Data with user_response, but field in the calling list keeps the old value.
Can somebody help me?

Offline René

  • Administrator
  • Hero Member
  • *****
  • Posts: 1832
  • Karma: 62
Re: How to update the record in OCS form GVP.
« Reply #1 on: September 07, 2010, 08:16:12 PM »
Hi Kirill,

OCS doesn't react on data attached to the call. It is necessary to send request to OCS via OCS HTTP interface using Web Request block in Composer. You can find simple example in Genesys 8.0 Proactive Contact Solution Guide. OCS HTTP interface is described in Outbound Contact 8.0 Reference Manual.

Unfortunately, there are no blocks supporting OCS operations available in Composer (yet?) so you need to code it yourself.

R.

Offline Kirill

  • Newbie
  • *
  • Posts: 26
  • Karma: 0
Re: How to update the record in OCS form GVP.
« Reply #2 on: September 08, 2010, 12:08:54 PM »
Hi, Rene
Now i am using Web Request block in Composer for sendind data to OCS. I can see it in OCS log, but fields in calling list still didnt update.
There is part of OCS log:


HTTPLog {
request uri: /records/1?req=RecordProcessed
GSW_USER_RESPONSE=1
}

HTTPLog {
HTTP/1.1 200 OK
Server: OCS/8.0
Content-Type: text/html;
Cache-control: private
Etag: 1283943336
Content-length: 32

<HTML><body>200 OK</body></HTML>
}

but in caling list field GSW_USER_RESPONSE did not have the correct value.

In what may be the problem?

Offline René

  • Administrator
  • Hero Member
  • *****
  • Posts: 1832
  • Karma: 62
Re: How to update the record in OCS form GVP.
« Reply #3 on: September 09, 2010, 07:13:34 AM »
Hi Kirill,

I'm not able to test it now so not sure where the problem may be. Could you post here part of OCS log (debug level) showing the HTTP request and OCS response.

R.

Offline cavagnaro

  • Administrator
  • Hero Member
  • *****
  • Posts: 7641
  • Karma: 56330
Re: How to update the record in OCS form GVP.
« Reply #4 on: September 10, 2010, 02:11:44 AM »
[quote author=Kirill link=topic=5843.msg25459#msg25459 date=1283947734]
Hi, Rene
Now i am using Web Request block in Composer for sendind data to OCS. I can see it in OCS log, but fields in calling list still didnt update.
There is part of OCS log:


HTTPLog {
request uri: /records/1?req=RecordProcessed
GSW_USER_RESPONSE=1
}

HTTPLog {
HTTP/1.1 200 OK
Server: OCS/8.0
Content-Type: text/html;
Cache-control: private
Etag: 1283943336
Content-length: 32

<HTML><body>200 OK</body></HTML>
}

but in caling list field GSW_USER_RESPONSE did not have the correct value.

In what may be the problem?
[/quote]

Check OCS logs too, maybe the record was already closed (agent ready) and therefore you can't update the record.

Offline Kirill

  • Newbie
  • *
  • Posts: 26
  • Karma: 0
Re: How to update the record in OCS form GVP.
« Reply #5 on: September 13, 2010, 01:59:38 PM »
Hi, there is the part of OCS log. Level Debug.

17:20:47.593 PA Session Info:
OwnerDBID: 102; Campaign DBID: 102; Group DBID: 104; Name: Campaign@Empty;
Mode: PowerGVP; Status: Running; WorkTime: 25;
Optimization: Busy Factor; Goal: 100; ProgressiveFlag: 1;
Max Queue Size: 10000;
Timeout - Dial: 120; Handle: 1800; Consider: 1800;
Calls predicted: 100; Engage calls predicted: 0; Algorithm:  Classical
Expected: Busy Factor= 1.000; Abandon Rate= 0.000; Wait Time= 0.000;
Real:                  0.000;              0.000;            0.000;
Current for  20 min:  0.000;              0.000;            0.000; (unreliable)
Agents/Places - Total: 0; Ready: 0; Engaged: 0; BusyOut: 0; BusyInB: 0;
BusyPaper: 0; BusyUnk: 0; BusyRingOrDial: 0; NotAvail: 0;
CheckedOut: 0;
Calls Engaging - Dialed: 0;
Calls Outbound - Dialed: 0; Queued: 0; Established: 1;
Calls Inbound  - Queued: 0; Established: 0;
Hit Ratio: 1.000;
Durations - Out:  0.00; In:  0.00; Total:  0.00; Dial:  5.50; NoContact:  0.00; Enagage:  0.00;
Traffic  - Out: 1.255; In: 0.000;
Outbound Calls - TotalDialed: 1; Established: 1; Completed: 0;
NoContact: 0; Abandoned: 0; Cleaned: 0; Removed: 0;
Inbound Calls  - TotalQueued: 0; Established: 0; Completed: 0;
Abandoned: 0; Cleaned: 0; Removed: 0;
17:20:47.593 Session Status Event GSW_CM_MessageType              34 [GSW_CM_EvPrimaryCallProgress]
GSW_CM_AttrCampaignID          102
GSW_CM_AttrGroupID              104
GSW_CM_AttrProperties         
'PA_CALL_DURATION' '  0.00'
'PA_MIN_DIAL_DURATION' '  0.00'
'PA_HIT_RATIO' '  1.00'
'PA_INB_RATE' '  0.00'
'PA_OUT_DIALED' '0'
'PA_OUT_QUEUED' '0'
'PA_PRED_FLAG' '0'
'PA_PRED_START' '0'
'PA_OUT_ESTABLISHED' '1'
'PA_OUT_ABANDONED' '0'
'PA_ENGAGE_DURATION' '  0.00'
'PA_WORKING_TIME' '0'

received from 65200(t-server)genesysnew:4090(fd=300) message EventResourceInfo
AttributeThisDN 'Resources'
AttributeExtensions [46] 00 02 01 00..
'available-ports' 3
'total-ports' 4
AttributeTimeinSecs 1284384047 (17:20:47)
AttributeTimeinuSecs 937000
AttributeCustomerID 'Resources'
AttributeEventSequenceNumber 0000000000000089
17:20:47.937 Trc 50002 TEvent: EventResourceInfo
SIPDialer::TrunkGroup[Resources (DBID=109)]::Total ports 4, available ports 3
17:20:51.062 CM_DBCallList(101-102-104): WeightInfo: RecordType:  0, Agents:  0, Share: 10, RecsNeededTotal: 15000, SumShares: 10, Result: 15000
17:20:51.062 CM_DBCallList(101-102-104): ExecuteSP:0
17:20:51.062 CM_DBCallList(101-102-104): DBServer 'oc_db_server for call_list_1 (440)' SQL: sp101102104110 @CampID = '102', @GroupID = '104', @ListID = '101', @RecType = 2, @NumRec = 15000, @CTime = '48051', @TTime = '1284384151', @ReadyCount = @out, @RetrievedCount = @out, @FinalCount = @out, @TotalCount = @out, @TotalRecsCount = @out, @ReadyRecsCount = @out [ReqID=67]
17:20:51.062 CM_DBCallList(101-102-104): DBServer 'oc_db_server for call_list_1 (440)' MSG_RETRIEVED(DBM_SUCCESS) [ReqID=67]
17:20:51.062 CM_DBCallList(101-102-104): SP return value (ReadyCount):0
CallingList[101`call_list_1].campaign_name_field = <default>; not configured
17:20:51.062 CM_DBCallList(101-102-104): ExecuteRequest:0
17:20:51.062 CM_DBCallList(101-102-104): DBServer 'oc_db_server for call_list_1 (440)' SQL: select T.* from #ReadyRecord R, MSGS4 T where R.chain_id=T.chain_id and T.record_status = 2  order by T.chain_id,T.chain_n [ReqID=68]
17:20:51.062 CM_DBCallList(101-102-104): DBServer 'oc_db_server for call_list_1 (440)' MSG_PROCCOMPLETED(DBM_SUCCESS) [ReqID=67]
17:20:51.062 CM_DBCallList(101-102-104): DBServer 'oc_db_server for call_list_1 (440)' MSG_RETRIEVED(DBM_EMPTY) [ReqID=68]
17:20:51.062 CM_DBCallList(101-102-104): SelectEnd:0  SelectedRecords:0 RequestID:68 ReadyRecords:0 SelectTime:0
17:20:51.062 CM_DBCallList(101-102-104): DBServer 'oc_db_server for call_list_1 (440)' SQL: TRUNCATE TABLE #ReadyRecord [ReqID=69]
17:20:51.062 CM_DBCallList(101-102-104): DBServer 'oc_db_server for call_list_1 (440)' MSG_SQLEXECUTED(DBM_SUCCESS) [ReqID=69]
received from 65200(t-server)genesysnew:4090(fd=300) message EventResourceInfo
AttributeThisDN 'Resources'
AttributeExtensions [46] 00 02 01 00..
'available-ports' 3
'total-ports' 4
AttributeTimeinSecs 1284384052 (17:20:52)
AttributeTimeinuSecs 953000
AttributeCustomerID 'Resources'
AttributeEventSequenceNumber 000000000000008a
17:20:52.953 Trc 50002 TEvent: EventResourceInfo
SIPDialer::TrunkGroup[Resources (DBID=109)]::Total ports 4, available ports 3
HTTPProxyClient[]::mesage received
'GSW_AGENT_REQ_TYPE' 'RecordProcessed'
'GSW_RECORD_HANDLE' '1'
'GSW_APPLICATION_ID' 110
Attribute <GSW_TREATMENT> not found
CallIpGVPDesktop[]::EventUserEvent {
CallProgressor[1:7S000001]::EventUserEvent {
CallProgressor[1:7S000001]::EventUserEvent{
CampaignGroup[102`Campaign@Empty].record_save_intermediate_results = true
UpdateRecord Handle:1 ChainID:1 ChainNum:0
17:20:53.218 CM_DBCallRecord(101-102-104): DBServer 'oc_db_server for call_list_1 (440)' SQL:  update MSGS4 set call_result=33,agent_id='',call_time=1284384041,switch_id=0  where chain_id=1 and chain_n=0 [ReqID=70]
FTCcall[109:5]::EventUserEvent
CallingList[101`call_list_1].dial_log_destination = <default>; not configured
Call[1:7S000001]::Finalizing, call state: Answer
CMDialerMng::sendCommEvent: TDialer for switch DBID:0 is not found
CMDialerMng::sendCommEvent: TDialer for switch DBID:0 is not found
CallingList[101`call_list_1].dial_log_destination = <default>; not configured
CallingList[101`call_list_1].dial_log_destination = <default>; not configured
Call[1:7S000001]::Deleting chained calls {
Call[1:7S000001]::Deleting call{
CallIpGVPDesktop[]::RequestClearCall {
CallIpGVPDesktop[]::not a UserEvent, skipped
}

17:20:53.218 PAEventInfo (ContactInfo):
OwnerSessionDBID: 102; OriginSessionDBID: 102;
CallType:  PA_CallOutbound; StatType: PA_StatCallCleanup;
RecHandle: 1; CallID: 0;
PlaceDBID: 0; CallResult: 33;
17:20:53.218 PA Outbound Call Info:
OwnerDBID: 102; OriginDBID: 102; RecHandle: 1;
CurrentStatType: AgentBusy; State: OutCallSuccess; CPDCompletedFlag: 3; CompletedFlag: 0; CallResult: 0;
StatType Durations:
      CallDialed   11.92
      AgentBusy   6.42
Outbound Call deleted. RecHandle: 1; OwnerDBID: 102;
FTCcall[109:5]::detached
}
}
UpdateRecord Handle:1 ChainID:1 ChainNum:0
17:20:53.218 CM_DBCallRecord(101-102-104): DBServer 'oc_db_server for call_list_1 (440)' SQL:  update MSGS4 set call_result=33,agent_id='',call_time=1284384041,record_type=2,record_status=3,attempt=90,switch_id=0  where chain_id=1 and chain_n=0 [ReqID=71]
CM_DBCampaign:102 ProcessChain ChainID=1 GroupDBID:104 Records:1 Chains:0 OnTimer:0 AtWork:0
}
}
CallIpGVPDesktop[]::not a UserEvent, skipped
}
HTTPProxyClient[]::mesage
'GSW_CALLING_LIST' 'call_list_1'
'GSW_CALL_RESULT' 33
'GSW_CAMPAIGN_NAME' 'Campaign'
'GSW_RECORD_HANDLE' '1'
'GSW_APPLICATION_ID' 110
'GSW_USER_EVENT' 'RecordProcessedAcknowledge'
17:20:53.218 sent to  HTTPProxyClient[]

HTTPLog {
request uri: /records/1?req=RecordProcessed
GSW_USER_RESPONSE=1
}
17:20:53.218 CM_DBCallList(101-102-104): DBServer 'oc_db_server for call_list_1 (440)' MSG_SQLEXECUTED(DBM_SUCCESS) [ReqID=70]
17:20:53.218 CM_DBCallList(101-102-104): DBServer 'oc_db_server for call_list_1 (440)' MSG_SQLEXECUTED(DBM_SUCCESS) [ReqID=71]
Campaign[102`Campaign].customer_id = <default>; not configured
17:20:53.218 Trc 61007 Record is removed  Chain_id: 1 Chain_n 0 Record_id: 1 Phone: 3203

HTTPLog {
HTTP/1.1 200 OK
Server: OCS/8.0
Content-Type: text/html;
Cache-control: private
Etag: 1284384053
Content-length: 32

<HTML><body>200 OK</body></HTML>
}
received from 65200(t-server)genesysnew:4090(fd=300) message EventTreatmentEnd
AttributeCallState 0
AttributeCallType 3
AttributePropagatedCallType 3
AttributeCallID 1
AttributeConnID 006d01d87c429001
AttributeCallUUID 'FPDMCV1E1T12DD43GABDK5AH94000001'
AttributeUserData [788] 00 1B 01 00..
'GSW_TZ_OFFSET' -25200
'GSW_PHONE' '3203'
'GSW_MSG_ID' '1'
'GSW_USER_RESPONSE' ''
'GSW_CALLING_LIST' 'call_list_1'
'GSW_CAMPAIGN_NAME' 'Campaign'
'InteractionType' 'Outbound'
'InteractionSubtype' 'OutboundNew'
'GSW_RECORD_HANDLE' 1
'GSW_APPLICATION_ID' 110
'GSW_CAMPAIGN_GROUP_DBID' 102
'GSW_CALLING_LIST_DBID' 101
'GSW_SWITCH_DBID' 0
'GSW_CAMPAIGN_GROUP_NAME' 'Campaign@Empty'
'GSW_CAMPAIGN_GROUP_DESCRIPTION' ''
'GSW_CHAIN_ID' 1
'GSW_ATTEMPTS' 89
'GSW_AGENT_ID' ''
'GSW_CALL_RESULT' 33
'GSW_TZ_NAME' 'PST'
'GSW_RECORD_URI' 'http://192.168.4.70:8082/records/1'
'GSW_CALL_ATTEMPT_GUID' 'KP6K3M6O3H6G9313SH0A0UF77S000001'
'GSW_CONTACT_MEDIA_TYPE' 'voice'
'GSW_CALL_TYPE' 'REGULAR'
'GSW_QUEUE_DBID' 0
'GSW_SESSION_DBID' 102
'GSW_MEDIA_SRV_ID' 'sip:Genesys@192.168.4.70:5070'
AttributeDNIS '3203'
AttributeCustomerID 'Resources'
AttributeThisDN 'Resources'
AttributeThisDNRole 1
AttributeTreatmentType 13 (TreatmentPlayApplication)
AttributeReferenceID 6
AttributeExtensions [23] 00 01 01 00..
'BusinessCall' 1
AttributeTimeinSecs 1284384053 (17:20:53)
AttributeTimeinuSecs 250000
AttributeEventSequenceNumber 000000000000008b
17:20:53.250 Trc 50002 TEvent: EventTreatmentEnd
17:20:53.250 OCSEvent[28]::EventTreatmentEnd(Unknown,CallTypeOutbound)
TrTServer[109`t-server]
DN[109`Resources]TrunkGroup
{
FTCcall[109:5]::EventTreatmentEnd
}

17:20:53.593 PA Session Info:
OwnerDBID: 102; Campaign DBID: 102; Group DBID: 104; Name: Campaign@Empty;
Mode: PowerGVP; Status: Running; WorkTime: 31;
Optimization: Busy Factor; Goal: 100; ProgressiveFlag: 1;
Max Queue Size: 10000;
Timeout - Dial: 120; Handle: 1800; Consider: 1800;
Calls predicted: 100; Engage calls predicted: 0; Algorithm:  Classical
Expected: Busy Factor= 1.000; Abandon Rate= 0.000; Wait Time= 0.000;
Real:                  0.000;              0.000;            0.000;
Current for  20 min:  0.000;              0.000;            0.000; (unreliable)
Agents/Places - Total: 0; Ready: 0; Engaged: 0; BusyOut: 0; BusyInB: 0;
BusyPaper: 0; BusyUnk: 0; BusyRingOrDial: 0; NotAvail: 0;
CheckedOut: 0;
Calls Engaging - Dialed: 0;
Calls Outbound - Dialed: 0; Queued: 0; Established: 0;
Calls Inbound  - Queued: 0; Established: 0;
Hit Ratio: 1.000;
Durations - Out:  6.42; In:  0.00; Total:  6.42; Dial:  5.50; NoContact:  0.00; Enagage:  0.00;
Traffic  - Out: 0.147; In: 0.000;
Outbound Calls - TotalDialed: 1; Established: 1; Completed: 1;
NoContact: 0; Abandoned: 0; Cleaned: 0; Removed: 0;
Inbound Calls  - TotalQueued: 0; Established: 0; Completed: 0;
Abandoned: 0; Cleaned: 0; Removed: 0;
17:20:53.593 Session Status Event GSW_CM_MessageType              34 [GSW_CM_EvPrimaryCallProgress]
GSW_CM_AttrCampaignID          102
GSW_CM_AttrGroupID              104
GSW_CM_AttrProperties         
'PA_CALL_DURATION' '  6.42'
'PA_MIN_DIAL_DURATION' '  0.00'
'PA_HIT_RATIO' '  1.00'
'PA_INB_RATE' '  0.00'
'PA_OUT_DIALED' '0'
'PA_OUT_QUEUED' '0'
'PA_PRED_FLAG' '0'
'PA_PRED_START' '0'
'PA_OUT_ESTABLISHED' '0'
'PA_OUT_ABANDONED' '0'
'PA_ENGAGE_DURATION' '  0.00'
'PA_WORKING_TIME' '0'

Offline René

  • Administrator
  • Hero Member
  • *****
  • Posts: 1832
  • Karma: 62
Re: How to update the record in OCS form GVP.
« Reply #6 on: September 14, 2010, 08:39:51 AM »
Hi Kirilli,

Log shows two RecordProcessed requests received using HTTP interface.

First one...
[quote]17:20:52.953 Trc 50002 TEvent: EventResourceInfo
SIPDialer::TrunkGroup[Resources (DBID=109)]::Total ports 4, available ports 3
HTTPProxyClient[]::mesage received
      'GSW_AGENT_REQ_TYPE'  'RecordProcessed'
      'GSW_RECORD_HANDLE'  '1'
      'GSW_APPLICATION_ID'  110[/quote]

Second one...
[quote]HTTPLog {
request uri: /records/1?req=RecordProcessed
GSW_USER_RESPONSE=1
}[/quote]

As your request comes as second one OCS will ignore it. It's a bit odd that you get 200 OK response as I would expect some error message but it doesn't change the fact the you're trying to update a record that was finished already.

R.