انتقل إلى المحتوى الرئيسي

Affiliate Links

The "Get Affiliate Links" API enables users to retrieve a list of affiliate links associated with their account. Affiliate links are used for tracking referrals and commissions in affiliate marketing programs. This API provides access to crucial affiliate link details, aiding affiliates in monitoring their performance and earnings.

  • Endpoint: api/customer/affiliate/links

  • Http Method: GET

نصيحة

Before using the "Get Affiliate Link History" API, ensure that the system's configuration includes the enable_affiliate setting, which should be enabled. This setting determines whether the affiliate functionality is active or not.

  • Success Response:
Affiliate Link Resource

You can check more details about Affiliate Link Resource.

{
"code": 200,
"message": "Success",
"data": {
"id": 1,
"url": "https://www.doc.supercommerce.io?referral=R5kvn5yBFGN70B4lEJR7",
"referral": "R5kvn5yBFGN70B4lEJR7",
"affiliate_id": 32,
"expiration_date": "2023-10-07 16:17:04",
"history_count": 0,
"created_at": "2023-09-07 16:17:04"
},
"meta": []
}
معلومات

Check the following section to learn more about the Get Affiliate Links API Reference

The "Create Affiliate Link" API allows users to create a new affiliate link. Affiliate links are used for tracking referrals and commissions in affiliate marketing programs. This API provides access to crucial affiliate link details, aiding affiliates in monitoring their performance and earnings.

  • Endpoint: api/customer/affiliate/links

  • Http Method: POST

نصيحة

Ensure that the system's configuration includes the enable_affiliate setting, which should be enabled. This setting determines whether the affiliate functionality is active or not.

  • Request Body:
KeyTypeDescription
urlstringThe URL of the affiliate link.
  • Success Response:
Affiliate Link Resource

You can check more details about Affiliate Link Resource.

{
"code": 200,
"message": "Success",
"data": {
"id": 1,
"url": "https://www.doc.supercommerce.io?referral=R5kvn5yBFGN70B4lEJR7",
"referral": "R5kvn5yBFGN70B4lEJR7",
"affiliate_id": 32,
"expiration_date": "2023-10-07 16:17:04",
"history_count": 0,
"created_at": "2023-09-07 16:17:04"
},
"meta": []
}
معلومات

Check the following section to learn more about the Create Affiliate Links API Reference

The "Set Clicked Affiliate Link" API is a valuable tool for retrieving historical data about how affiliate links were used.

  • Endpoint: api/customer/affiliate/links/history

  • Http Method: GET

  • Success Response:

KeyTypeDescription
idIntegerThe ID of the affiliate link history.
user_ipstringThe IP address of the user who clicked the affiliate link.
user_idIntegerThe ID of the user who clicked the affiliate link.
link_idIntegerThe ID of the affiliate link.
{
"code": 200,
"message": "Success",
"data": {
"user_ip": "156.215.23.28",
"user_id": 32,
"link_id": 1,
"updated_at": "2023-09-07T13:38:00.000000Z",
"created_at": "2023-09-07T13:38:00.000000Z",
"id": 1
},
"meta": []
}
معلومات

Check the following section to learn more about the Set Clicked Affiliate Link API Reference