--- title: "BulkExportLiveAudiences" slug: "bulkexportaudiences" updated: 2024-05-07T16:04:41Z published: 2024-05-07T16:04:41Z canonical: "docs.datajet.app/bulkexportaudiences" --- > ## Documentation Index > Fetch the complete documentation index at: https://docs.datajet.app/llms.txt > Use this file to discover all available pages before exploring further. # BulkExportAudiences Exports all audiences of specified status into appended files of a specified size | Key | Value(s) | Description | | --- | --- | --- | | method | "BulkExportAudiences" | Exports all audiences of specified status into appended files of a specified size | | fileStub | "fileStubString" | Each file that is generated will have a filename beginning with the "fileStubString". The location of the export files is determined by the project's [campaign definition file](/v1/docs/campaign-prototype-how-to-make-a-system-campaign-enabled). | | status | "statusString" | Optional Filter. Available status: - * (All) - draft - live - ended - cancelled | | prefix | "prefix string" | Optional prefix added to start of each hashkey as part of export. e.g., US\t will generate US 23c4ga5678639ca72520a257cf5760a1dfbd35ea558d66766f4d404d185f9 | | suffix | "suffix string" | Optional suffix added to end of each hashkey as part of export. e.g., \t%AUDIENCEID% will generate 23c4ga5678639ca72520a257cf5760a1dfbd35ea558d66766f4d404d185f9 27988405173 Note: the following read-only variables are supported: - %AUDIENCEID% - % | | recordsPerFile | NNNNNN | Optional. Number of records to be included in each file. Default = {TODO} | | user | "username" | Optional Filter. Last Modified By username | | archiveStatus | "statusString" | Optional Filter. Available status: - * (All) - active - archived | | creator | "username" | Optional Filter. Created by username. | For each audience in the search, obtains the unique hash-keys that are in the audience and outputs to file. Data from multiple audiences may be appended into the same file - to identify which audience a key belongs to, use %AUDIENCEID% as either a prefix or suffix. ```json { "method": "BulkExportAudiences", "fileStub": "testexport", "status": "*", "prefix": "US\t", "suffix": "\t%AUDIENCEID%", "recordsPerFile": 50000, "project": "eyeota" } ``` ```json { "method": "BulkExportAudiences", "user": "smc@datajetsoft.com", "fileStub": "testexport", "prefix": "US\t", "suffix": "\t%AUDIENCEID%", "recordsPerFile": 50000, "project": "eyeota" } ``` #### Sample Return ```json { "files": 1, "totalLinesWritten": 0, "audiencesExported": 0, "audiencesFailed": 0, } ``` ```json { "files": 7, "totalLinesWritten": 322924, "audiencesExported": 6, "audiencesFailed": 0, } ```