![]() |
VOOZH | about |
Slingshot (formerly known as Reveal BI) is a data-driven work management suite that brings together analytics, team and project coordination, content sharing, and communication in a single platform. With CData API Server, you can generate OData APIs for live Amazon Athena data that are seamlessly consumable within Slingshot.
In this guide, we'll walk you through a step-by-step process to generate OData endpoints for Amazon Athena using CData API Server, and bring those endpoints into Slingshot to create real-time dashboards and streamline data analysis.
Let's begin!
Here's an overview of the steps:
CData provides the easiest way to access and integrate live data from Amazon Athena. Customers use CData connectivity to:
Users frequently integrate Athena with analytics tools like Tableau, Power BI, and Excel for in-depth analytics from their preferred tools.
To learn more about unique Amazon Athena use cases with CData, check out our blog post: https://www.cdata.com/blog/amazon-athena-use-cases.
If you haven't already, download and install the CData API Server. Follow the installation wizard to complete the setup for your machine.
Once installed, you can start the server in the following ways:
If the Slingshot app and API Server are hosted on different domains, CORS (Cross-Origin Resource Sharing) must be enabled to allow cross-domain communication. To enable CORS in the API Server:
To authorize Amazon Athena requests, provide the credentials for an administrator account or for an IAM user with custom permissions: Set to the access key Id. Set to the secret access key.
Note: Though you can connect as the AWS account administrator, it is recommended to use IAM user credentials to access AWS services.
To obtain the credentials for an IAM user, follow the steps below:
To obtain the credentials for your AWS root account, follow the steps below:
If you are using the CData Data Provider for Amazon Athena 2018 from an EC2 Instance and have an IAM Role assigned to the instance, you can use the IAM Role to authenticate. To do so, set to true and leave and empty. The CData Data Provider for Amazon Athena 2018 will automatically obtain your IAM Role credentials and authenticate with them.
In many situations it may be preferable to use an IAM role for authentication instead of the direct security credentials of an AWS root user. An AWS role may be used instead by specifying the . This will cause the CData Data Provider for Amazon Athena 2018 to attempt to retrieve credentials for the specified role. If you are connecting to AWS (instead of already being connected such as on an EC2 instance), you must additionally specify the and of an IAM user to assume the role for. Roles may not be used when specifying the and of an AWS root user.
For users and roles that require Multi-factor Authentication, specify the and connection properties. This will cause the CData Data Provider for Amazon Athena 2018 to submit the MFA credentials in a request to retrieve temporary authentication credentials. Note that the duration of the temporary credentials may be controlled via the (default 3600 seconds).
In addition to the and properties, specify , and . Set to the region where your Amazon Athena data is hosted. Set to a folder in S3 where you would like to store the results of queries.
If is not set in the connection, the data provider connects to the default database set in Amazon Athena.
To allow secure access to the OData endpoints, you need to create and configure users in the CData API Server. Each user will have authentication credentials and role-based access control, ensuring that only authorized users can query the connected data.
Once a user is created, an Authtoken is automatically generated. This token can be used in API requests as a secure authentication method in place of the password.
You can also refresh the Authtoken, disable it, or set expiration rules (e.g., number of days until expiry) by enabling the Token Expiration option in the user settings.
π Authtoken Settings for the Added User in CData API ServerTo make your data available to Slingshot via OData, you need to expose your desired tables through the API Server:
Now that your API is configured, Slingshot can connect to the OData endpoints to visualize live data. Use the following endpoint URL formats to access your API resources:
| Endpoint | URL | |
|---|---|---|
| Entity List | http://address:port/api.rsc/ | |
| Table Metadata (e.g., albums) | http://address:port/api.rsc/albums/$metadata?@json | |
| Table Data (e.g., albums) | http://address:port/api.rsc/albums |
These OData endpoints can now be consumed directly in Slingshot by creating a new data source using the URL. Slingshot supports OData, so once connected, you can build dashboards and visualizations using live data from Amazon Athena.
For custom queries and filtered visualizations in Slingshot, append standard OData query parameters like $select, $filter, $orderby, $top, and $skip to your requests.
Now that your OData API is ready, it's time to bring it into Slingshot and start analyzing your live Amazon Athena data.
Now that your OData feed is connected and available in Slingshot, you can start creating visualizations to explore and analyze your data in real-time.
For our example, let's build a simple Grid visualization.
Similarly, you can create different visualizations like charts, tables, or pivot views by selecting the appropriate components from the panel. Just drag, drop, and configure as needed to explore your data from multiple angles.
You can also play with your data further by applying filters, sorting values, or grouping rows as needed. The possibilities are vast to tailor your dashboard exactly how you want it β powered by live Amazon Athena data, connected data from your OData feed.
The CData API Server offers the fastest way to build REST APIs from 270+ live data sources β with a no/low-code, plug-and-play approach that's ready for real-time app integrations!
Start your free trial and connect instantly with tools like Slingshot. Simplify how your team accesses and interacts with data today.
Learn more or sign up for a free trial:
CData API Server