Issue with webservices invocation and template storage

Use this forum for questions regarding adoption and functionality of OpenEMM

Moderator: moderator

steprm
Posts: 1
Joined: Tue Jan 21, 2020 11:20 am

Issue with webservices invocation and template storage

Post by steprm »

Hi everybody. I've just installed OpenEMM 2015 on a docker environment in order to replace the previous installation of OpenEMM (maybe 2013) that is gotten lost because of an hardware failure. I'm not able to understand how have I to configure the properties urlService and urlService2.0:
At this URL <host:port>/openemm-ws/emmservices.wsdl I can see the WSDL. I'd like to perform some test calls by using soap ui, but I always get exception, someone has a request example to use?
I have one more question: I have an old backup of the previoos environment, I'd like to restore the template on the new envinroment, but I have no idea about templates are stored. I was expected to find a table on the OpeneEMM database containings templates, but it seems there isn't.
Someone can kindly help me?
Thank you so much, and excuse me for my bad english.
Regards
Step
rodig03
Posts: 45
Joined: Thu Sep 18, 2014 1:27 pm

Re: Issue with webservices invocation and template storage

Post by rodig03 »

Hi,

did you create the user for this already? In 2015 you have to enter it directly into MySQL, in 2019 there is a frontend way.

I have a PHP script for testing some functions, I'll copy some line from it (URL for web services is a bit different, changed to work with OpeneEmm 2019, but the test script didn't need to be changed essentially from the 2013 and 2015 versions). You should be able to enter the URL into the browser and see the XML definition of the web services. Then the URL is ok.

Here, I wanted to debug how the data structure looks like, so I entered some data, found the IDs of the entries (either in the interface or hidden in the URL when you open the element in the web interface, and put them into the code below to show the customer 7, the functions and mailinglists availabe and the structure and data fields (e.g. time stamps) in the GetSubsciber and GetSubscriberBinding functions.

I hope this helps a bit.
Robert

Code: Select all

<?php

require ("../includes/someicludedes.php"); //open Mysql DB connection
require "../classes/WSSESoapClient.php"; //Important - this is the library to use. Is available from Agnitas.

mysql_set_charset("UTF8"); // Use current connection


// URL of the WSDL document. Test
    $wsdlURI = "http://server.domain.xx/2.0/emmservices.wsdl";
// OpenEmm server authentication information
    $wsUser = "ws-user-name";
    $wsPassword = "secretpwd";
//
$werte = array("customerID" => "7");
$client = new WsseSoapClient($wsdlURI, $wsUser, $wsPassword);
var_dump( $client->__getFunctions());
var_dump( $client->ListMailinglists());
echo "<pre>";
print_r ( $client->GetSubscriber($werte));

$werte = array("customerID" => "7", "mailinglistID" => "2", "mediatype" => "0");
print_r ( $client->GetSubscriberBinding($werte));

echo "</pre>";
?>
Post Reply