---
title: "Export referrals"
method: GET
path: "/v1/applications/{applicationId}/export_referrals"
tags: ["Referrals"]
---

# Export referrals

`GET /v1/applications/{applicationId}/export_referrals`

## Request

- Base URL: `https://yourbaseurl.talon.one`
- URL: `https://yourbaseurl.talon.one/v1/applications/{applicationId}/export_referrals`
- Auth: one of:
  - API key in header `Authorization`
  - API key in header `Authorization`
- TypeScript: <https://skmtc.dev/talon/apis/management-api/docs/v1/applications/:applicationId/export_referrals/get.ts> (a function with typed inputs; its response is checked against the schema)

> [!note] Management API endpoints are **not** meant to be used in real-time integrations that directly serve your end users. Rate limit: 3 requests per second.

Download a CSV file containing the referrals that match the given
parameters.

> [!tip] If the exported CSV file is too large to view, you can
> [split it into multiple files](https://www.google.com/search?q=split+CSV+into+multiple+files).

The CSV file contains the following columns:

- `code`: The referral code.
- `advocateprofileintegrationid`: The profile ID of the advocate.
- `startdate`: The start date in RFC3339 of the code redemption period.
- `expirydate`: The end date in RFC3339 of the code redemption period.
- `limitval`: The maximum number of redemptions of this code. Defaults to `1` when left blank.
- `attributes`: A json object describing _custom_ referral attribute names and their values.

## Path parameters

- `applicationId` integer, required

## Query parameters

- `campaignId` number
- `createdBefore` string, date-time
- `createdAfter` string, date-time
- `valid` 'expired' | 'validNow' | 'validFuture'
- `usable` 'true' | 'false'
- `batchId` string
- `dateFormat` 'excel' | 'ISO8601'

## Response `200`

OK

---

[API](https://skmtc.dev/talon/apis/management-api.md) - [All operations](https://skmtc.dev/talon/apis/management-api/llms.txt) - [OpenAPI document](https://skmtc.dev/talon/apis/management-api/revisions/7ef1b9504c3a?raw)
