Skip to main content
GET
/
affiliate_sales
cURL
curl --request GET \
  --url https://api.growi.io/api/public/v1/affiliate_sales \
  --header 'Authorization: Bearer <token>'
{
  "data": [
    {
      "id": 1947457,
      "external_id": "ORD-12345",
      "platform": "website",
      "status": "unpaid",
      "occurred_at": "2025-09-30T23:55:29.000Z",
      "total": 9999,
      "commission": 500,
      "currency": "usd"
    }
  ],
  "meta": {
    "row_count": 150,
    "page_count": 8,
    "current_page": 1
  },
  "additional_data": {
    "total_gmv": 14245.57,
    "total_commission": 1403.31,
    "paid_commission": 500,
    "unpaid_commission": 903.31,
    "total_vat": 0,
    "total_orders": 150,
    "total_refunded_amount": 0
  }
}
Retrieves paginated affiliate sales (conversions) for the organization. These endpoints manage conversions (affiliate sales) attributed to your creators and ambassadors. For website conversions, call with store_platform=website (no store_id required). For Shopify conversions, use store_platform=shopify_store along with your store_id. The response includes data (array of sales), meta (pagination info), and additional_data (aggregate totals like total GMV, commission breakdown, and order counts).

Request Parameters

ParameterTypeDescriptionRequired
pageIntegerPage number for pagination. Default is 1.No
per_pageIntegerNumber of results per page. Default is 20. Maximum is 100.No
start_dateStringFilter sales from this date (MM/DD/YYYY format)No
end_dateStringFilter sales until this date (MM/DD/YYYY format)No
searchStringSearch by customer name or emailNo
creator_idIntegerFilter by Growi creator/user IDNo
creator_emailStringFilter by creator’s email addressNo
campaign_idIntegerFilter by campaign IDNo
order_idStringFilter by external order IDNo
statusStringFilter by status: paid, due, unpaid, canceled, or refundedNo
affiliate_tagStringFilter by affiliate tag (campaign_affiliate_id tag)No
store_idStringStore identifier (required for Shopify, not needed for website)No
store_platformStringPlatform type: website or shopify_store. Use website for website-sourced conversions.No
ambassador_programBooleanFilter to only ambassador program sales. Default is false.No

Request Example

curl -X GET "https://api.growi.io/api/public/v1/affiliate_sales?store_platform=website&page=1&per_page=20" \
     -H "Authorization: Bearer YOUR_PUBLIC_API_KEY"
With date range and status filter:
curl -X GET "https://api.growi.io/api/public/v1/affiliate_sales?store_platform=website&start_date=01/01/2025&end_date=01/31/2025&status=unpaid" \
     -H "Authorization: Bearer YOUR_PUBLIC_API_KEY"

Response Example

{
  "data": [
    {
      "id": 1947457,
      "external_id": "ORD-12345",
      "platform": "website",
      "status": "unpaid",
      "occurred_at": "2025-09-30T23:55:29.000Z",
      "total": 9999,
      "commission": 500,
      "currency": "usd"
    }
  ],
  "meta": {
    "row_count": 150,
    "page_count": 8,
    "current_page": 1
  },
  "additional_data": {
    "total_gmv": 14245.57,
    "total_commission": 1403.31,
    "paid_commission": 500.00,
    "unpaid_commission": 903.31,
    "total_vat": 0.0,
    "total_orders": 150,
    "total_refunded_amount": 0.0
  }
}

Response Fields

FieldTypeDescription
dataArrayArray of affiliate sale objects
data[].idIntegerUnique Growi identifier for the sale
data[].external_idStringExternal order ID (your system’s order identifier)
data[].platformStringSource platform: website, shopify, etc.
data[].statusStringSale status: paid, due, unpaid, canceled, or refunded
data[].occurred_atStringISO 8601 timestamp when the sale occurred
data[].totalIntegerTotal order amount in cents
data[].commissionIntegerCommission amount in cents
data[].currencyStringCurrency code (e.g., usd, eur)
metaObjectPagination metadata
meta.row_countIntegerTotal number of sales matching the query
meta.page_countIntegerTotal number of pages available
meta.current_pageIntegerCurrent page number
additional_dataObjectAggregate totals for the query
additional_data.total_gmvNumberTotal Gross Merchandise Value in dollars
additional_data.total_commissionNumberTotal commission amount in dollars
additional_data.paid_commissionNumberCommission already paid out in dollars
additional_data.unpaid_commissionNumberCommission not yet paid in dollars
additional_data.total_vatNumberTotal VAT amount in dollars
additional_data.total_ordersIntegerTotal number of orders
additional_data.total_refunded_amountNumberTotal refunded amount in dollars

Use Cases

This endpoint is useful for:
  • Conversions Dashboard: Build a real-time dashboard showing all affiliate-attributed sales
  • Data Warehouse Sync: Export conversion data to your analytics or data warehouse
  • Payout Reconciliation: Verify commission amounts before processing creator payouts
  • Creator Performance: Filter by creator_id or creator_email to analyze individual creator performance
  • Campaign Analytics: Filter by campaign_id to measure campaign-specific conversion metrics
  • Financial Reporting: Use additional_data totals for GMV and commission reporting

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Query Parameters

page
integer
default:1

Page number for pagination. Default is 1.

per_page
integer
default:20

Number of results per page. Default is 20. Maximum is 100.

Required range: x <= 100
start_date
string<date>

Filter sales from this date (MM/DD/YYYY format)

end_date
string<date>

Filter sales until this date (MM/DD/YYYY format)

Search by customer name or email

creator_id
integer

Filter by Growi creator/user ID

creator_email
string<email>

Filter by creator's email address

campaign_id
integer

Filter by campaign ID

order_id
string

Filter by external order ID

status
enum<string>

Filter by sale status

Available options:
paid,
due,
unpaid,
canceled,
refunded
affiliate_tag
string

Filter by affiliate tag

store_id
string

Store identifier (required for Shopify, not needed for website)

store_platform
enum<string>

Platform type: website or shopify_store

Available options:
website,
shopify_store
ambassador_program
boolean
default:false

Filter to only ambassador program sales

Response

Affiliate sales retrieved successfully

data
object[]
meta
object
additional_data
object