openapi: 3.2.0 info: description: Marketo Engage Rest API version: '1.0' title: Marketo Engage Rest Bulk Export Program Members API termsOfService: https://www.adobe.com/legal.html contact: name: Adobe Developer Relations url: https://experienceleague.adobe.com/en/docs/marketo-developer/marketo/home email: '' license: name: API License Agreement url: https://experienceleague.adobe.com/en/docs/marketo-developer/marketo/api-license servers: - url: https://localhost:8080/ tags: - name: Bulk Export Program Members description: Bulk Export Program Members Controller paths: /bulk/v1/program/members/export.json: get: tags: - Bulk Export Program Members summary: Get Export Program Member Jobs description: 'Returns a list of export jobs that were created in the past 7 days. Required Permissions: Read-Only Lead' operationId: getExportProgramMembersUsingGET parameters: - name: status in: query description: Comma separated list of statuses to filter on. required: false style: form explode: true schema: type: array items: type: string enum: - created - queued - processing - cancelled - completed - failed - name: batchSize in: query description: The batch size to return. The max and default value is 300. required: false schema: type: integer format: int32 - name: nextPageToken in: query description: A token will be returned by this endpoint if the result set is greater than the batch size and can be passed in a subsequent call through this parameter. See Paging Tokens for more info. required: false schema: type: string responses: '200': description: OK content: application/json: schema: $ref: '#/components/schemas/ResponseOfExportResponseWithToken' /bulk/v1/program/members/export/create.json: post: tags: - Bulk Export Program Members summary: Create Export Program Member Job description: 'Create export job for search criteria defined via "filter" parameter. Request returns the "exportId" which is passed as a parameter in subsequent calls to Bulk Export Program Members endpoints. Use Enqueue Export Program Member Job endpoint to queue the export job for processing. Use Get Export Program Member Job Status endpoint to retrieve status of export job. Required Permissions: Read-Only Lead' operationId: createExportProgramMembersUsingPOST responses: '200': description: OK content: application/json: schema: $ref: '#/components/schemas/ResponseOfExportResponse' requestBody: content: application/json: schema: $ref: '#/components/schemas/ExportProgramMemberRequest' description: 'exportProgramMemberRequest

ColumnHeaderNames: A JSON object containing key-value pairs of field and column header names.

Example:
"columnHeaderNames":{
"firstName":"First Name",
"lastName":"Last Name",
"email":"Email Address"
}

' /bulk/v1/program/members/export/{exportId}/cancel.json: post: tags: - Bulk Export Program Members summary: Cancel Export Program Member Job description: 'Cancel export job. Required Permissions: Read-Only Lead' operationId: cancelExportProgramMembersUsingPOST parameters: - name: exportId in: path description: Id of export batch job. required: true schema: type: string responses: '200': description: OK content: application/json: schema: $ref: '#/components/schemas/ResponseOfExportResponse' /bulk/v1/program/members/export/{exportId}/enqueue.json: post: tags: - Bulk Export Program Members summary: Enqueue Export Program Member Job description: 'Enqueue export job. This will place export job in queue, and will start the job when computing resources become available. The export job must be in "Created" state. Use Get Export Program Member Job Status endpoint to retrieve status of export job. Required Permissions: Read-Only Lead' operationId: enqueueExportProgramMembersUsingPOST parameters: - name: exportId in: path description: Id of export batch job. required: true schema: type: string responses: '200': description: OK content: application/json: schema: $ref: '#/components/schemas/ResponseOfExportResponse' /bulk/v1/program/members/export/{exportId}/file.json: get: tags: - Bulk Export Program Members summary: Get Export Program Member File description: 'Returns the file content of an export job. The export job must be in "Completed" state. Use Get Export Program Member Job Status endpoint to retrieve status of export job. Required Permissions: Read-Only Lead

The file format is specified by calling the Create Export Program Member Job endpoint. The following is an example of the default file format ("CSV").

firstName,lastName,email
Marvin,Gaye,marvin.gaye@motown.com' operationId: getExportProgramMembersFileUsingGET parameters: - name: exportId in: path description: Id of export batch job. required: true schema: type: string - name: Range in: header description: To support partial retrieval of extracted data, the HTTP header "Range" of type "bytes" may be specified. See RFC 2616 "Range Retrieval Requests" for more information. If the header is not set, the entire contents will be returned. required: false schema: type: string responses: '200': description: OK content: application/json: schema: $ref: '#/components/schemas/ObservableOfInputStreamRangeContent' /bulk/v1/program/members/export/{exportId}/status.json: get: tags: - Bulk Export Program Members summary: Get Export Program Member Job Status description: 'Returns status of an export job. Job status is available for 30 days after Completed or Failed status was reached. Required Permissions: Read-Only Lead' operationId: getExportProgramMembersStatusUsingGET parameters: - name: exportId in: path description: Id of export batch job. required: true schema: type: string responses: '200': description: OK content: application/json: schema: $ref: '#/components/schemas/ResponseOfExportResponse' components: schemas: Error: type: object required: - code - message properties: code: type: string description: Error code of the error. See full list of error codes here message: type: string description: Message describing the cause of the error ResponseOfExportResponseWithToken: type: object required: - errors - requestId - result - success - warnings properties: errors: type: array description: Array of errors that occurred if the request was unsuccessful items: $ref: '#/components/schemas/Error' nextPageToken: type: string description: Paging token given if the result set exceeded the allowed batch size requestId: type: string description: Id of the request made result: type: array description: Array of results for individual records in the operation, may be empty items: $ref: '#/components/schemas/ExportResponse' success: type: boolean example: false description: Whether the request succeeded warnings: type: array description: Array of warnings given for the operation items: $ref: '#/components/schemas/Warning' Warning: type: object required: - code - message properties: code: type: integer format: int32 description: Integer code of the warning message: type: string description: Message describing the warning ExportProgramMemberFilter: type: object properties: programId: type: integer format: int32 description: Id of program to retrieve members from. Cannot be used in combination with "programIds" filter programIds: type: array description: Array of program ids to retrieve members from. Cannot be used in combination with "programId" filter items: type: integer format: int32 isExhausted: type: boolean description: Filter program membership records for people who have exhausted content nurtureCadence: type: string description: Filter program membership records for a given nurture cadence enum: - paused - normal statusNames: type: array description: Array of program member status names. Can be default and/or user-defined. Multiple status names are ORed together. items: type: string updatedAt: description: Date range to filter program members on $ref: '#/components/schemas/DateRange' ResponseOfExportResponse: type: object required: - errors - requestId - result - success - warnings properties: errors: type: array description: Array of errors that occurred if the request was unsuccessful items: $ref: '#/components/schemas/Error' requestId: type: string description: Id of the request made result: type: array description: Array of results for individual records in the operation, may be empty items: $ref: '#/components/schemas/ExportResponse' success: type: boolean example: false description: Whether the request succeeded warnings: type: array description: Array of warnings given for the operation items: $ref: '#/components/schemas/Warning' ObservableOfInputStreamRangeContent: type: object ColumnHeaderNames: type: object required: - name - value properties: name: type: string description: REST API name for header field value: type: string description: Value for header field DateRange: type: object properties: endAt: type: string description: End of date range filter (ISO 8601-format) startAt: type: string description: Start of date range filter (ISO-8601 format) ExportResponse: type: object required: - exportId - status properties: createdAt: type: string format: date-time description: Date when the export request was created errorMsg: type: string description: Error message in case of "Failed" status exportId: type: string description: Unique id of the export job fileSize: type: integer format: int64 description: Size of exported file in bytes. This will have a value only when status is "Completed", otherwise null fileChecksum: type: string description: SHA-256 hash of exported file. This will have a value only when status is "Completed", otherwise null finishedAt: type: string format: date-time description: Finish time of export job. This will have value only when status is "Completed" or "Failed", otherwise null format: type: string description: Format of file as given in the request ("CSV", "TSV", "SSV") numberOfRecords: type: integer format: int64 description: Number of records in the export file. This will have value only when status is "Completed", otherwise null queuedAt: type: string format: date-time description: Queue time of export job. This will have value when "Queued" status is reached, before that null startedAt: type: string format: date-time description: Start time of export job. This will have value when "Processing" status is reached, before that null status: type: string description: Status of the export job ("Created","Queued","Processing","Canceled","Completed","Failed") description: Response containing export job status information ExportProgramMemberRequest: type: object required: - fields - filter properties: columnHeaderNames: description: File header field names override (corresponds with REST API name) $ref: '#/components/schemas/ColumnHeaderNames' fields: type: array description: Comma-separated list of fields to include in the file items: type: string filter: description: 'Program member record selection criteria. Must be the following: "programId"' $ref: '#/components/schemas/ExportProgramMemberFilter' format: type: string description: File format to create("CSV", "TSV", "SSV"). Default is "CSV"