/datasets/profile/{datasetId}/batch/{batchId}

Download a list of profile variables and records of members with profile variables.

Steps

Retrieve member data from your download link by following these steps:

  1. Make a GET call to obtain the download link:

    https://api.{region}.alida.com/v2/applications/{communityApiKeyName}/datasets/profile/{datasetId}/batch/{batchId}

  2. Make a GET call to retrieve member data from the download link in the data field:

    https://api.{region}.alida.com/v2/applications/{communityApiKeyName}/datasets/profile/{datasetId}/files/{fileId}

  3. In the Locations header, use the link to download the export file. Skip this step if the download link is automatically redirected to download the export file.
    Note: Streaming is a recommended method to extract large quantities of data without affecting memory or performance. Use any HTTP client capable of streaming and is compatible with the language you are using.

Resource URL

  1. /v2/applications/{communityApiKeyName}/datasets/profile/{datasetId}/batch/{batchId}
  2. /v2/applications/{communityApiKeyName}/datasets/profile/{datasetId}/files/{fileId}
Note:

Use the appropriate regional endpoint to ensure that you comply with your organization's privacy policy, and applicable laws and regulations. For details about the available regional endpoints, and how to identify your organization's region, see API Access.

Available methods

Method Description
1. GET Get the status and download link of the batch member profile dataset export.
2. GET Get the batched member profile dataset from the download link.

Available fields for 1. GET

Element Description
createDate The date and time in UTC when the export was created.
createdBy The GUID of the user who created the batch member profile data export.
data The download link to the batch member profile data export.
errorMessage The string value of the error message.
id The string GUID of the batchId.
lastUpdateDate The date and time in UTC when the export was last updated.
lastUpdatedBy The string GUID of the user who last updated the profile variable dataset.
message

This element contains a field called artifact. The artifact field gets appended to the end of the data element, otherwise known as fileId.

status The string value of the current status of the export. Possible values are:
  • Pending
  • Running
  • Succeeded
  • Failed
Example
{
    "id": <GUID of the batch>,
    "datasetId": <GUID of the applicationId>,
    "status": <pending|running|succeeded|failed>,
    "message": {"artifact": <fileId of the batch export>},
    "errorMessage": <string value of the error message>,
    "createDate": <date-time (UTC) of when this record got created>,
    "createdBy": <user context that created this record>,
    "lastUpdateDate": <date-time (UTC) of when this record got last updated>,
    "lastUpdatedBy": <user context that last updated this record>,
    "data": <link to the batch export>
}

Available fields from the JSON file

Table 1. Top-level elements
Element Description
id

GUID of the batchId.

datasetId GUID of the applicationId.
exportDate The date and time when the export was started.
lastSyncDate The date and time when member profile values were last synced.
Note: It is recommended to use the value from this element as the sinceDatetime in the next export.
Table 2. Elements under the fields attribute
Element Description
dataType The value of how the profile variable values are stored. Possible values are:
  • string: The value is stored as text.
  • double: The value is stored as numeric.
  • datetime: The value is stored as date-time.
  • identifier: The value is stored as a text identifier.
  • enum: Allows the choice of a single value from a list of possible values.
  • set: Allows the choice of multiple values from a list of possible values.

The element can be found under the property container type.

id The GUID of the profile variable.
isSensitive A boolean value indicating whether the profile variable dataset contains sensitive data.
name The string name of the profile variable.
values The values of the Member Profile Dataset.
  • id: The GUID of the profile variable value.
    Note: id is not applicable to Open End questions.
  • name: The string name of the profile variable.
  • visibility: The visibility setting of the profile variable.

The element can be found under the property container type.

visibility The visibility setting of the profile variable. Possible values are:
  • active
  • hidden

The element can be found under the property container meta.

Table 3. Elements under the records attribute
Element Description
fields
  • id: GUID of the profile variable.
  • values: GUID of the profile variable value.
lastUpdateDate The date and time in UTC when a profile variable was last updated.
ownerId GUID of the member.
Note: The response payload can differ from the example if you specified parameters in /datasets/profile/{datasetId}/batch.
Example
{
    "id": <GUID of the batchId>,
    "exportDate": <date-time when the export started>,
    "lastSyncDate": <date-time when the latest profile variable value were last synced>,
    "datasetId": <GUID of the applicationId>,
    "definition": {
        "fields": [
            {
                "id": <GUID of the profile variable 1>,
                "name": <string name of the profile variable 1>,
                "type": {
                    "dataType": <string|double|datetime|identifier|enum|set>,
                    "values": [
                        {
                            "id": <GUID of the profile variable value>,
                            "name": <string name of the profile variable value>,
                            "meta": {
                                "visibility": <active|hidden>
                            }
                        }
                    ]
                },
                "isSensitive": <true|false>
                "meta": {
                    "visibility": <active|hidden>
                }
            }
            {
                "id": <GUID of the profile variable 2>,
                "name": <string name of the profile variable 2>,
                "type": {
                    "dataType": <string|double|datetime|identifier|enum|set>,
                    "values": [
                        {
                            "id": <GUID of the profile variable value>,
                            "name": <string name of the profile variable value>,
                            "meta": {
                                "visibility": <active|hidden>
                            }
                        }
                    ]
                },
                "isSensitive": <true|false>
                "meta": {
                    "visibility": <active|hidden>
                }
            }
        ]
    },
    "records": [
        {
            "ownerId": <GUID of the member>,
            "lastUpdateDate": <date-time (UTC) when a profile variable was last updated>,
            "fields": [
                {
                    "id": <GUID of the profile variable 1>,
                    "values": [
                        <GUID of the profile variable value>
                    ]
                },
                {
                    "id": <GUID of profile variable 2>,
                    "values": [
                        <GUID of the profile variable value>
                    ]
                }
            ]
        }
    ]
}