PHP code example of yproximite / yprox-api-client-bundle

1. Go to this page and download the library: Download yproximite/yprox-api-client-bundle library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

yproximite / yprox-api-client-bundle example snippets


// app/AppKernel.php
public function registerBundles()
{
    return [
        // ...
        new Yproximite\Bundle\YproxApiClientBundle\YproxApiClientBundle(),
    ];
}

// yprox_api_client.service_aggregator.<client_name_from_config>
$api = $this->get('yprox_api_client.service_aggregator.default');

$message = new ArticleListMessage();
$message->setSiteId(1);

// Yproximite\Api\Model\Article\Article[]
$articles = $api->article()->getArticles($message);