Under Construction...
Its not a spelling mistake. https://www.domo.com/
I once worked with DOMO api's to render a widget (its a chart/graph). It was beautiful to see what/how the data is being rendered. I must say, the widget is the most advance that i have ever seen. You can change the Chart type on the fly. You can do all sort data filtering and sorting and styling on the widget itself. Beauty was that, its so fast and you wont feel nothing. But I had spend quite some time to get this done because as usual there wan't any ready made help or pages available for getting this done in CFML.
First things first, it was required to study the DOMO api's and their logic of rendering. I was not given with any DOMO account or login to get in and see what are all being offered. But instead i was asked to study from outside and make calls to their API to render a CARD or PAGE (that's what the terms in DOMO world)
I did exactly what I was asked to do in CFML. I will layout the steps and details of getting the DOMO rendering and little bit about my understanding about their API and "how to".
How does DOMO works (DOMO API Integration).
Domo has concept of Rendering reports as "CARD" OR "PAGE". You can either render them as "Private" or "Public". That's all. So assuming your organization or Business team has already designed all required reports in DOMO, the development team left with rendering them into their product or web page.
Card and Page Design:
When the card or page is designed, it was carefully taken into consideration for "filters". Because that's the only thing
For Private Cards/Page:
The integration part consists of multiple files. A class file and a custom tag. Test pages for card and page.
A Class Component file DOMO.cfc composed with all required DOMO server api calls.
Similar to OAUTH Model, DOMO API integration starts with AccessToken for vendor authentication.
Custom Tag (DOMO.cfm) enabled with flexible arguments to control DOMO server interactions as well as the rendering options.
Test pages, which you can use to test your card/page before you integrate it into your actual product or web page.
You can find all these files at my gist page (below).
-------- -------- -------- -------- -------- -------- -------- -------- -------- -------- -------- -------- -------- -------- -------- -------- -------- -------- --------
As said earlier, DOMO cards/Pages are already designed and available in DOMO Server.
So everything starts with DOMO card ID or Page ID.
For domo report ID (Card/Page) the authentication and rendering logic is same. Except that we have to use different url for Auth and Rendering.
Step 1. Authentication
-------- -------- -------- -------- -------- -------- -------- -------- -------- -------- -------- -------- -------- -------- -------- -------- -------- -------- --------
Domo.cfc
Base class for making DOMO server interactions. To begin with you need to set your vendor credentials such as clientId and Secret value pvt_PrepareDomo method.
<cfset instance.domo.keys.clientId = "<setyourvaluehere>" /><cfset instance.domo.keys.clientSecret = "<setyourvaluehere>" /><cfset instance.domo.keys.EmbedHost = "https://public.domo.com" /><cfset instance.domo.keys.APIHost = "https://api.domo.com" />prepareDomo_Embedding is the entry method