Skip to main content
Check out the LinkUp website for more information.

1. Add Linkup Parameters to Your Request

Include linkup_params in your request’s keywordsai_params:

2. Use Template Variables in Your Messages

The Linkup response will be available as a variable named linkup_search_response in your templates. You can access it using Jinja2 syntax:
You can learn how to use Jinja2 syntax in the Jinja2 documentation.

3. Using with Prompts

If you’re using Keywords AI Prompts, you can include the Linkup template variables in your prompt templates. When you make a request with linkup_params, the variables will be populated and rendered in your prompt.

How It Works

  1. When a request with linkup_params is received, the system:
    • Extracts the Linkup parameters from the request
    • Calls the Linkup API to retrieve search results
    • Adds the results to the template variables as linkup_search_response
    • Renders the prompt templates with these variables
  2. If you’re using stored prompts, the system:
    • Loads the prompt without rendering variables
    • Merges variables from the prompt and the request
    • Processes Linkup parameters and adds results to variables
    • Renders the prompt with all variables, including Linkup results

Parameters

The linkup_params object supports the following parameters:

Response Structure

The linkup_search_response variable will contain:

Example

Here’s a complete example of using the Linkup integration:
Python
With a prompt template like:

Error Handling

If there’s an error with the Linkup API call, it will be added to the warnings_dict in the response with the key LINKUP_SEARCH_ERROR.