Anaplan has a set of APIs that allow for a developer to programmatically interact in certain ways with the Anaplan platform, rather than using the Anaplan user interface.
These APIs are grouped into the following categories:
The subset of Bulk and Transactional APIs are the two that allows for someone to programmatically move data into and out of an Anaplan model. We will be focusing on those two APIs in this article, specifically loading data into Anaplan and explaining what the difference between the two is, when to and how to make an informed decision on which one to use.
What’s the Difference Between Bulk and Transactional?
Historically Anaplan’s Bulk API (very literally named) has been used for sending large (a.k.a. bulk of) data sets into Anaplan. These data sets are either in .csv or .txt format and can range in size anywhere from a few KB to 10s of GB worth of data.
The steps to set up a Bulk API load are as follows:
Manually load the file into the Anaplan model
Save the export action
Upload the file via API
Execute the import action via API
Poll the /tasks endpoint to check on the status of the job
The Bulk API is a very efficient and effective way to load mass amounts of data into an Anaplan model at a scheduled frequency and customers have been using it successfully for years for their data needs.
The Transactional API on the other hand is a much more lightweight alternative to the Bulk APIs. It is meant for targeted, small loads of data into an Anaplan model vs. updating an entire data set like the Bulk API. This API accepts .csv or .json formatted data sets. JSON is a much easier data type for developers to work with and is a general standard for Restful APIs.
The steps to set up a Transactional API load are as follows:
Load the data into the Anaplan model via the API
As you can tell, this is a much simpler process to load data into Anaplan.
Right now you are probably thinking, why wouldn’t I just use Transactional always? There are several considerations to take into account which we will now cover.
When to use Bulk API
The Bulk API should be used for traditional scheduled, batch, data loads into Anaplan. Think of loading an entire month’s worth of general ledger entries from an ERP every week or a refresh of your employee roster from an HRIS nightly.
Some general criteria to guide your decision are as follows:
Large data set (>1000 cells of data)
.csv or .txt files to be loaded
OK to have asynchronous responses for the load status
When to use Transactional API
The Transactional API on the other hand should be used for event-based data feeds into Anaplan.
That sounds like some technical jargon, right? What this means is rather than scheduling loads in a batch process to run, say, nightly, perhaps an event takes place in another system (a record is updated) and you’d like that update to immediately be reflected in your Anaplan model.
If you have small “transactions” worth of data that should be loaded quickly and w/o blocking the model, the Transactional API could be a great choice.
Small data set (<1000 cells of data)
.json or .csv to be loaded
Need synchronous load status responses
Another consideration is as previously discussed the Transactional API does not need an import data source file or import action in the model to run. This can be particularly useful when model changes are frequent (think renaming, adding, or deleting of line items), or you’d like to keep your actions tab lean. Since Transactional API loads straight into the model, there is less change management needed to keep integrations working properly.
What else can Transactional API do?
As you can imagine, the single step of loading data into the Anaplan model needs a few pieces of information to work properly. Things like the ID of the module, the line item names, the list IDs, list member IDs, etc. basically the information needed to tell Anaplan the exact cell within the model it needs to update…The full list is here. As such, the Transactional API also offers endpoints for a developer to access this model info. Some examples of data that can be queried out of the model via Transactional API:
Data about all lists
Data about all modules (dimensions, line items, etc.)
Data about all line items (everything from model blueprint view)
Data about model calendar, versions, and switchover
While these are useful for constructing the API request to upload data into the model, they can also be used on their own to run some powerful model analytics and monitoring. By using the API, it would take a simple script to loop through every model and consolidate info about your models.
With this info you could perform various analyses, some examples:
Modeling best practice analysis (where are my biggest formulas, Planual violations, over-dimensioned line items, etc.)
Do all of my models have the same versions? The same switchover date?
Search all line items in a tenant (where is “salary” stored in my models?)
Got feedback on this content? Let us know in the comments below.
The content in this article has not been evaluated for all Anaplan implementations and may not be recommended for your specific situation.
Please consult your internal administrators prior to applying any of the ideas or steps in this article.