Home

PHP

Edit network configuration

Edit a network configuration.

API Function:edit_network_configuration

API EndPoint

https://synced.io/api/v2_account?wsdl

Parameters:

Name Type Description
username string Your API username. You should have received this with your account
subscription_id string Your Subscription ID. You can copy or regenerate it from your API management interface.
configuration_id string The netwok configuration id that should be deleted.
network_data object The netwok data object
affiliate_id string Encrypted affiliate id of the publisher account associated with the configuration, null if not joined
username string Encrypted username of the publisher account associated with the configuration, null if not joined
password string Encrypted password of the publisher account associated with the configuration, null if not joined
token string Encrypted token of the publisher account associated with the configuration, null if not joined
network_user_id string Encrypted network user id of the publisher account associated with the configuration, null if not joined
network_feed_password string Encrypted network feed password of the publisher account associated with the configuration, null if not joined
ad_space string Network ad space of the publisher account associated with the configuration, null if not joined
currency_id numeric Network currency id of the publisher account associated with the configuration
network_authorization_key string Encrypted network authorization key of the publisher account associated with the configuration, null if not joined

 

Response fields:

Name Type Description
code string The result of the operation. Can be error or success
message string If code is error this field will be filled with the error message
configuration_id string The new configuration id which should be used in the future to edit the network configuration
verification_code string Can be right or wrong. Based on the parameters filled and sent, our platform will try to access the affiliate network APIs to get the required data. If it will succeed the field will contain right, otherwise wrong
                    
                    

                    
                    

                    
                    
                                            
<?php 
                        
class network_data {
    
    /** @var string */    
    public $affiliate_id = null;

    /** @var string */    
    public $username = null;

    /** @var string */    
    public $password = null;
    
    /** @var string */    
    public $token = null;
    
    /** @var string */    
    public $network_user_id = null;
    
    /** @var string */    
    public $network_feed_password = null;
    
    /** @var string */    
    public $ad_space = null;
    
    /** @var int */    
    public $currency_id = 0;
    
    /** @var string */    
    public $request_authorization_key = null; 
    
}                        
                        
                        
$api_username      = '*******';
$api_subscription  = '*******';
$network_configuration_id  = '{replace with the configuration id}';
$network_data = new network_data();

$network_data->affiliate_id = {affiliate_id}; // replace with affiliate data
$network_data->username = {user}; // replace with affiliate data
$network_data->password = {password}; // replace with affiliate data
$network_data->token = {token}; // replace with affiliate data
$network_data->network_user_id = {network_user_id}; // replace with affiliate data
$network_data->network_feed_password = {network_feed_password}; // replace with affiliate data
$network_data->ad_space = {ad_space}; // replace with affiliate data
$network_data->currency_id = {currency_id}; // replace with affiliate data
$network_data->request_authorization_key = {request_authorization_key}; // replace with affiliate data

try
{

        $client     = new SoapClient('https://synced.io/api/v2_account?wsdl');
        $response   = $client->edit_network_configuration($api_username, $api_subscription, $network_configuration_id, $network_data);

        print_r($response);            


} catch (Exception $e)
{

    print_r($e);
    echo $client->__getLastRequest() . "\n";
    exit;
}

?>