PHP code example of payfully / integrator

1. Go to this page and download the library: Download payfully/integrator 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/ */

    

payfully / integrator example snippets


$urlgenerator->setUser([...]);
$urlgenerator->setApplication([...]);
$urlgenerator->setDocuments([...]);



use Payfully\Integrator\UrlGenerator;
use Payfully\Integrator\Env;

$relativeUrl = 'SuperAgency';
$aesKey = "Qkoghsks1Oe3V+/s+wtV6b1FFmM+YdQCg0mGPTiO3xofssrcsgR6yA3rvsSIyq/85DiHm/7BIbrEg1GOL1soag==";
$urlgenerator = new UrlGenerator($relativeUrl, $aesKey, Env::Stage);

$urlgenerator->setUser([...]);
$urlgenerator->setApplication([...]);
$urlgenerator->setDocuments([...]);

echo $urlgenerator->generate();



use Payfully\Integrator\UrlGenerator;
use Payfully\Integrator\Env;

$relativeUrl = 'SuperAgency';
$aesKey = "Qkoghsks1Oe3V+/s+wtV6b1FFmM+YdQCg0mGPTiO3xofssrcsgR6yA3rvsSIyq/85DiHm/7BIbrEg1GOL1soag==";
$urlgenerator = new UrlGenerator($relativeUrl, $aesKey, Env::Stage);
$urlgenerator->setUser([...]);
$urlgenerator->setApplication([...]);
$urlgenerator->setDocuments([...]);

echo $urlgenerator->generate();

$user = [
  "email"=> "...", // (red) [string] Agent's full name
  "phone" => "..." // (

$application = [
  'shareOfCommission' => ..., // (optional) [number] - Commission ammount expected by the Agent for the deal
  'dealInformation' => [
    'propertyAddress' => "...", // (optional) [string] - Address of the property
    'propertyType' => "...", // (optional) [string] - Type of property
    'isNewConstruction' => true/false, // (optional) [boolean] - Is it a new contruction?
    'isShortSale' => true/false, // (optional) [boolean] - Is it a short sale?
    'ratificationDate' => "...", // (optional) [string] ISO 8601 Date String - Date in which al contingencies are met
    'closingDate' => "...", // (optional) [string] ISO 8601 Date String - Closing date of the contract
    'mlsId' => "..." // (optional) [string] - MLS ID
  ],
  'agentInformation' => [
    'represents' => "...", // (optional) [string] - Who does the agent represents on this deal (see below)
    'completedTransactions' => ..., // (optional) [number] - Completed transactions by the agent in the last 6 months
    'pendingContracts' => ..., // (optional) [number] - Number of Agent's pending contracts at the moment
    'activeListings' => ..., // (optional) [number] - Number of Agent's active listings at the moment
    'licenseNumber' => "..." // (optional) [string] - Agent's license number
  ]
];

$documents = [
  [
    "type" => "..." // (A URL for a direct document download. HTTP GET is used to fetch the document.
  ],
  [ ... ]
];