This guide covers ÃÛ¶¹ÊÓƵ Customer Journey Analytics (CJA) APIs, detailing data extraction, custom solutions, and third-party integration. It includes access setup, API keys, testing with Postman, a step-by-step API call example, and tips for first-time users.
Are you new to APIs and wondering how can help you? Fear not! In this beginner-friendly guide, we’ll walk you through the essentials, break down the jargons, and help you take your first steps into the exciting world of CJA APIs.
Imagine having the power to access and analyze your CJA data programatically, without manual effort. That’s exactly what CJA APIs allow you to do!
- Extract data efficiently: Streamline data extraction with API calls.
- Build custom solutions: Design and implement automated reporting pipelines tailored to specific business needs.
- Connect seamlessly: Enable smooth data flow between CJA and third-party applications through robust integrations.
Think of APIs as messengers - they carry your requests to ´¡»å´Ç²ú±ð’s servers and bring back the results in a neat package.
Setting Up for Success
Before making your first API call, you'll need to set up proper access and permissions. First, ensure you are added as a Developer for your Organization. Then, verify you have access to the Product profiles with the necessary permissions.
Step 1: Get Your API Key
- Log into .
- Create a new project and add the Customer Journey Analytics API to your project and select the required product profiles.
- Click on Add to Project and add ÃÛ¶¹ÊÓƵ Experience Platform API also to the project
- Once the setup is completed, you’ll be able to get all the required information under the Credentials tab in the left.
Here are the three essential header parameters required for all API requests
- Access Token – This ensures that only authorized users access the data and can be generated by clicking on the Generate access token CTA highlighted in the screenshot. This is referred as Authorization parameter in the AP request
- Client ID - Also known as the API Key, this is referred as x-api-key in the API request
- Organization ID – This is referred as x-gw-ims-org-id in the API request
Make sure to save these credentials- they’re your keys to unlocking the API’s power! More detailed step by step instructions are included in the section of the CJA API.
Step 2: Test Your Setup
A great way to test APIs without writing any code is by using the powerful and user-friendly tool . After launching the application, you can easily import your API credentials and begin experimenting with simple GET requests to verify that your connection and authentication are working properly. It's recommended to start your API testing journey with GET requests because they are considered safer and non-destructive, as they only retrieve data from the server without making any modifications. This is in contrast to other HTTP methods like POST, PUT, or DELETE requests, which can alter or remove data on the server and should therefore be tested with more caution.
Making Your First API Call
Let’s do something simple: fetch a list of available data views in your CJA account.
Example: List Data Views
Endpoint:
GET https://cja.adobe.io/data/dataviews
Headers:
x-api-key: {API_KEY}
x-gw-ims-org-id: {IMS_ORG_ID}
Authorization: Bearer {AUTHORIZATION_TOKEN}
CURL Request:
curl -X GET "https://cja.adobe.io/data/dataviewsexpansion=name%2Cowner%2Corganization%2Cdescription"\
-H "x-api-key: {API_KEY}" \
-H "x-gw-ims-org-id: {IMS_ORG_ID}" \
-H "Authorization: Bearer {AUTHORIZATION_TOKEN}"
You can also try out these requests within the CJA API endpoint documentation using the Try It feature. .
Simply click on the Try It CTA and enter all the mandatory parameters, in this case the header parameters that we discussed and hit Send.
You can also include additional parameters to customize your request. A list of available parameters can be found under the Query Parameters section for each API request in the .
Here are the key HTTP response codes you'll encounter when working with APIs:
- 200: Success — The server successfully processed the request and returned data
- 404: Not Found — The server couldn't find the requested resource
- 500: Internal Server Error — An error occurred on the server side
These status codes tell developers exactly what happened during an API request, making it easier to troubleshoot issues.
Tips for First-Time API Users
- Verify your access: Make sure that you’ve the right levels of permissions and that you’re added to the correct product profiles. Not having the right access is the most common root cause for unsuccessful API requests
- Test, Test, Test: Use the Try It feature in the API endpoint documentation or Postman to experiment with requests before writing code.
- Start Small: Begin with simple GET requests and work up to POST queries.
- Use Documentation: ´¡»å´Ç²ú±ð’s is your best friend. Regularly check for updates, as older configurations may not work as expected after major updates.
- Ask Questions: Don’t hesitate to reach out to the for help.
Getting started with ÃÛ¶¹ÊÓƵ CJA APIs might seem daunting at first, but with a little practice, you’ll be automating workflows and uncovering insights in no time. So, take the first step - log in, grab your credentials, and try out a simple API call. Your API adventure awaits!