Back to Documentation Overview
getAffiliateInfo
public static getAffiliateInfo(string apikey)
Retrieve your User Unique Id and your Affiliate link to display/use for Monkey Rewards. While we don't use the User Id for any API functions, it can be useful if building up URL strings for things such as the profile editor and sub/unsub links.
- Section:
- Helper
- Parameters:
- apikey a valid API Key for your user account. Get by calling login()
- Returns:
- array - containing your Affilliate Id and full link.
- Returned Fields:
string user_id Your User Unique Id. string url Your Monkey Rewards link for our Affiliate program - <?php
- /**
- This Example shows how to Update an A/B Split Campaign via the MCAPI class.
- **/
- require_once 'inc/MCAPI.class.php';
- require_once 'inc/config.inc.php'; //contains apikey
- $retval = $api->getAffiliateInfo();
- if ($api->errorCode){
- } else {
- }
- <?php
- /**
- This Example shows how retrieve your account's Affiliate info using XML-RPC.
- Note that we are using the PEAR XML-RPC client and recommend others do as well.
- **/
- require_once 'XML/RPC2/Client.php';
- require_once 'inc/config.inc.php';
- try {
- $result = $client->getAffiliateInfo($apikey);
- } catch (XML_RPC2_FaultException $e){
- }
Examples (2)
download example code[1] mcapi_getAffiliateInfo.php
[2] xml-rpc_getAffiliateInfo.php
|
Add New Note
User Contributed Notes for
getAffiliateInfo |
|---|
| No notes, yet... Will you be the first?? |