Kadam icon

Kadam

Interact with Kadam API (v1.4.x) for managing campaigns, clients, creatives, and more.

Campaign → Get Categories

AI-generated

Overview

This node interacts with the Kadam advertising platform API to retrieve campaign-related data. Specifically, the "Get Categories" operation under the Campaign resource fetches categories associated with a specified ad format and optionally filters by category ID.

Use cases include:

  • Fetching available campaign categories for a given ad format to dynamically populate UI elements or validate inputs.
  • Filtering categories by a specific category ID to narrow down results.
  • Integrating campaign category data into marketing automation workflows or reporting pipelines.

Example: A marketer wants to list all campaign categories available for the "Teaser" ad format (ID 10) to select appropriate categories when creating new campaigns.

Properties

Name Meaning
Ad Format Required. The ID of the ad format (e.g., 10 for Teaser). Use the "Get Ad Formats" operation to retrieve valid options.
Category ID Optional. Filter categories by this specific category ID. If omitted, all categories for the ad format are returned.
Retry on Failure Optional boolean. If enabled, the node will retry the request up to 3 times on temporary failures such as rate limits or network issues.

Output

The output is a JSON array of campaign category objects retrieved from the Kadam API. Each item typically includes fields like:

  • id: Unique identifier of the category.
  • title: Name/title of the category.
  • Possibly other metadata related to the category.

The node returns these categories as individual JSON items in the output array, each paired with the input item index.

No binary data is produced by this operation.

Dependencies

  • Requires an active Kadam API credential with an API token and application ID configured in n8n.
  • Makes HTTP GET requests to the Kadam API endpoint /ads.campaigns.categories.get.
  • Uses Axios library internally for HTTP requests.
  • Requires internet connectivity to reach the Kadam API service.

Troubleshooting

  • Common Issues:

    • Invalid or missing API credentials will cause authentication errors.
    • Providing an invalid or unsupported ad format ID may result in empty or error responses.
    • Network issues or Kadam API rate limiting can cause request failures.
  • Error Messages:

    • "Failed to load campaign categories: <error message>" indicates problems fetching categories, possibly due to invalid parameters or API issues.
    • "Invalid response structure for campaign categories. Expected response.items." means the API response did not contain the expected data format.
    • Generic API errors will be wrapped and surfaced with details if available.
  • Resolutions:

    • Verify that the API token and app ID credentials are correctly set up.
    • Use the "Get Ad Formats" operation to ensure the ad format ID is valid.
    • Enable "Retry on Failure" to automatically handle transient errors.
    • Check network connectivity and Kadam API status.

Links and References


This summary is based solely on static analysis of the provided source code and property definitions without runtime execution.

Discussion