Sage Intacct provides a set of API functions for using the Data Delivery Service (DDS). Before you run a DDS job, you must define a cloud storage target in the Sage Intacct UI.

Because DDS is designed to work on very large datasets, DDS jobs run asynchronously. The following is a basic sequence diagram for a DDS job.

Sequence diagram for DDS job

The DDS Manager regularly polls the queue for new jobs and processes them.

The sections that follow show how to list available DDS objects, start a job, and monitor the results.

List available objects

You can use the following function to get a listing of all objects, both standard and custom, available for DDS jobs.

<getDdsObjects/>

Start a job

You can run a job to get all the records for an object, or you can run a job to get only the records that have changed since the last run.

To start a DDS job, use the runDdsJob function. The following example runs a DDS job to get all vendors, then saves the data to the specified cloud storage location:

<runDdsJob>
    <object>VENDOR</object>
    <cloudDelivery>AWS-S3-DDS</cloudDelivery>
    <jobType>all</jobType>
</runDdsJob>

The response provides the DDS job object, for example:

 <ddsjob>
     <DDSJOB>VENDOR;all;2017-10-04T18:47:55+00:00</DDSJOB>
     <OBJECT>VENDOR</OBJECT>
     <JOBTYPE>all</JOBTYPE>
     <SUBSCRIPTIONKEY></SUBSCRIPTIONKEY>
     <QUEUETIME>10/04/2017 18:47:55</QUEUETIME>
     <STARTTIME></STARTTIME>
     <ENDTIME></ENDTIME>
     <RECORDSCREATED>0</RECORDSCREATED>
     <RECORDSUPDATED>0</RECORDSUPDATED>
     <RECORDSDELETED>0</RECORDSDELETED>
     <STATUS>Queued</STATUS>
     <ERROR></ERROR>
     <FILELIST></FILELIST>
     <DDSHISTORYKEY>11</DDSHISTORYKEY>
     <RECORDNO>12</RECORDNO>
 </ddsjob>

Monitor a job

DDS does not actively communicate job status. To get the job status, use the read function on the DDSJOB object and provide the RECORDNO returned by runDdsJob.

<read>
    <object>DDSJOB</object>
    <keys>1</keys>
    <fields>*</fields>
</read>

When the job is complete, the response provides a list of CSV files published to the cloud storage target, for example:

<STATUS>Completed</STATUS>
<ERROR></ERROR>
<FILELIST>VENDOR.all.10.2017-09-29_18.04.59_UTC_00000.csv</FILELIST>

Provide feedback