With Image AddedSee the different possibilities that our API offers you can to integrate uContact with other external systems.
To AuthorizationEnd session for Image RemovedImage AddedAPI Omnichannel
Image RemovedImage AddedAPI Telephony
Image RemovedImage AddedAPI Other Actions
Image RemovedImage AddedAPI Gamification
Image RemovedImage AddedDataBases
Image RemovedImage AddedExamples
Image RemovedPrior to making any of the queries to the web services it is necessary to obtain the APIkey
through the Login.
To do will UserLogin
and enter super user Expand |
---|
title | Click here to expand UserLogin getUserToken Service
User
Relative URL: https://dominio.ucontactcloud.com/Integra/resources/auth/ |
UserLogingetUserToken
Method: POST
content-type:application/x-www-form-urlencoded; charset=UTF-8
|
ParamsParameters: user
password
|
Result Code Block |
---|
Where Md5secret is the APIKey or if it has no phone will have it on the 3rd item of the List
If error Response is 0 |
Supervisor con teléfono
Md5secret es la APIKey
Code Block |
[ ...
{
....Supervisor without phone
At the end of the list
md5secretQWRtaW46OTgzNWM1MjUtMzU2Ny00YjgyLWEwYWYtY2NkMjNlMDhjNzA3" |
:"Q2FyaW5hOjI3YzdjNWM5LTkzYzQtNDYyMi1iYzg2LTlkMmNkMGVjNWEzMA==",
....
}
Supervisor sin teléfono
Al final de la lista
Code Block |
[... "QWRtaW46OTgzNWM1MjUtMzU2Ny00YjgyLWEwYWYtY2NkMjNlMDhjNzA3"
]
Si esRespuesta Expand |
---|
title | Click here to expand jQuery example codeExample code for jQuery
Code Block |
---|
$.ajax({
type: 'POST',
url: 'https:// |
<ucontactinstance>domain.ucontactcloud.com/Integra/resources/auth/ |
UserLogingetUserToken',
contentType: 'application/x-www-form-urlencoded; charset=UTF-8',
dataType: 'text',
data: {
user: 'ExampleUsername',
password: 'ExamplePassword'
},
success: (resp) => {},
error: (resp) => {}
}); |
Image Removed
we will see API JQuery in each Expand |
---|
title | Click here to expand example configuration in jQueryjQuery configuration example
Code Block |
---|
$.ajaxSetup({
headers: {
'Authorization': "Basic " + APIKey
}
}); |
Expand |
---|
title | Click here to expand example of token in authorization header Code Block |
---|
$.ajax({
type: 'POST',
url: 'https:// |
<ucontactinstance>dominio.ucontactcloud.com/Integra/resources/any/request',
contentType: 'application/x-www-form-urlencoded; charset=UTF-8',
dataType: 'text',
headers:{
'Authorization': 'Basic <APIKey>'
},
data: {
param1: 'exampleParam1',
param2: 'exampleParam2'
},
success: (resp) => {},
error: (resp) => {}
}); |
Image Removed
This in of the startup Expand |
---|
title | Click here to expand and see the methodMethod
Relative URL: https://dominio.ucontactcloud.com/Integra/resources/auth/EndSession
Method: POST
content-type:application/x-www-form-urlencoded; charset=UTF-8
Params: user
token
Result: 1 OK 0 ERROR |
Expand |
---|
title | Click here to expand example Example code for jQuery
code Code Block |
---|
$.ajax({
type: 'POST',
url: 'https:// |
<ucontactinstance>domain.ucontactcloud.com/Integra/resources/auth/EndSession',
contentType: 'application/x-www-form-urlencoded; charset=UTF-8',
dataType: 'text',
headers:{
'Authorization': 'Basic <APIKey>'
},
data: {
user: 'ExampleUser',
token: '<token>'
},
success: (resp) => {},
error: (resp) => {}
}); |
Aditional Iinformation
Note |
---|
All WebServices are REST type. Only uContact uses https by default (http2) is used for security, a valid certificate *.ucontactcloud.com is provided
|
Image RemovedImage AddedCrossDomain Connection
With the Windows proxy window , we can handle events of an iframe inserted in a form, to be able , for example, to make do dispositions, hang up the call, close the form, or whatever is desired.
you want, for example. To do this you don't need any plugin.
Expand |
---|
title | Previous Steps, no plugin is needed.
Previous steps
In the form you must put
this:
Code Block |
---|
|
window.addEventListener('message', event => {
if (event.data.action === 'CLOSE_TAB') {
parent.closeActiveTab();
} else if (event.data.action === 'DISPOSITION_CALL') {
let dataDisp = event.data.disposition;
UC_DispositionCall(dataDisp.campaign, dataDisp.callerid, dataDisp.guid, dataDisp.l1, dataDisp.l2, dataDisp.l3, dataDisp.d1, dataDisp.d2, dataDisp.comment, dataDisp.schedule, callbackDiposition, errorDiposition);
}
}); |
event.data can be used to identify what type the
type of action is.
And the disposition attribute is used as an object to send more information.
Expand |
titleHow to invoke
the eventit?
The way to invoke
the event would be the followingit is:
Code Block |
---|
|
let dataDisp = {
campaign: ' CampanaTestCampañaTest',
callerid: '123456Test',
guid:'3123-3123-3123-312-3123',
l1:'nivel1',
l2:'nivel2',
l3:'nivel3',
d1:'data1',
d2:'data2',
comment:'ComentarioTest',
schedule:'2019-05-04 15:55:55'
};
window.parent.postMessage({ action: 'DISPOSITION_CALL', disposition:dataDisp}, '*'); |
Token creation
Users with "SuperUser" role in uContact have the functionality to create tokens for use outside of the application. To create a token, follow these steps:
Access the user menu.
Image AddedSelect the "API tokens" option in the dropdown menu and a modal will open for its creation.
Image AddedEnter the name that you want to use to identify the token and click the "Save" button to create a new token.
Image AddedOnce a token has been created in uContact, "SuperUsers" have the ability to share it with other users. To do so, simply click on the clip icon. This will automatically copy the token to the clipboard and it can then be sent to anyone with whom you wish to share it.
You may also be interested
... Image Removed Image Added
Upload dialer base
Image RemovedImage Added
Webcallback
Image RemovedImage Added
Postman collection for the Login and Logoff.
View file |
---|
name | API Security.postman_collection.json |
---|
|