Exa

Search the web, find similar pages, and get page contents with Exa's neural search.

AI and MLAPI key5 actionsAll integrations

On this page
  1. Connect
  2. Call it from a workflow
  3. Actions (5)
  4. find_similar_links
  5. get_contents
  6. perform_search
  7. custom_api_call
  8. generate_answer
  9. Details

Connect

Auth type: API key (secret_text). Pass the provider's API key or token as the connection's credential. It is sealed at rest and only opened on the server when an action runs.

  • From your agent: integrations {action: "connect", piece, credentials, env} stores the credentials for dev, prod or all. Answers name the fields, never the values.
  • Or set the integration's project secrets with the secrets tool (SLACK_BOT_TOKEN, DISCORD_WEBHOOK_URL, TELEGRAM_BOT_TOKEN, TWILIO_ACCOUNT_SID and TWILIO_AUTH_TOKEN …): a call uses the connection, else those secrets. integrations {action: "catalog", piece} lists which ones work.
  • Try one action now with integrations {action: "call", piece, piece_action, input}. It really sends.

Call it from a workflow

step.ctx.integrations.invoke("exa", action, input) resolves with the provider's answer and rejects when Exa isn't connected or refuses. Wrap it in step.run so a retry sends once. See step.ctx. Its actions run through the integration runner, which the server's operator turns on: integrations {action: "catalog", piece: "exa"} says whether yours can call it.

Workflow
// workflows/notify.ts: call Exa when a booking is confirmed
import { on } from "@appbricx/workflows";

export const tellExa = on.transition("booking", "status", "confirmed", async (_event, step) => {
  // Recorded once: a retry doesn't send it twice. Rejects when Exa isn't connected.
  const output = await step.run("Exa", () =>
    step.ctx.integrations.invoke("exa", "find_similar_links", {
      "url": "<url>"
    }),
  );
  step.ctx.log("Exa answered", output);
});
Try it from your agent
{
  "name": "integrations",
  "arguments": {
    "project_id": "<project-id>",
    "action": "call",
    "piece": "exa",
    "piece_action": "find_similar_links",
    "input": {
      "url": "<url>"
    },
    "env": "dev"
  }
}
From another backend (connector proxy)
curl -X POST "$APP_ORIGIN/__appbricx/connector-proxy/exa/find_similar_links" \
  -H "Authorization: Bearer $APP_KEY" \
  -H "content-type: application/json" \
  -d '{"props":{"url":"<url>"}}'

Actions

Find Similar Links. Find pages similar to a given URL.

InputTypeDescription
urlrequiredtextReference URL to find semantically similar links.
numResultsoptionalnumberNumber of results to return (max 100).
includeDomainsoptionalarrayList of domains to include in results.
excludeDomainsoptionalarrayList of domains to exclude from results.
startCrawlDateoptionaldate-time (ISO)Include links crawled after this date (ISO format).
endCrawlDateoptionaldate-time (ISO)Include links crawled before this date (ISO format).
startPublishedDateoptionaldate-time (ISO)Only include links published after this date (ISO format).
endPublishedDateoptionaldate-time (ISO)Only include links published before this date (ISO format).
includeTextoptionalarrayStrings that must be present in the webpage text (max 1 string of up to 5 words).
excludeTextoptionalarrayStrings that must not be present in the webpage text (max 1 string of up to 5 words).

get_contents

Get Contents. Retrieve clean HTML content from specified URLs.

InputTypeDescription
urlsrequiredarrayArray of URLs to crawl
textoptionalbooleanIf true, returns full page text. If false, disables text return.
livecrawloptionalone of "never" | "fallback" | "always" | "auto"Options for livecrawling pages.
livecrawlTimeoutoptionalnumberTimeout for livecrawling in milliseconds.
subpagesoptionalnumberNumber of subpages to crawl.
subpageTargetoptionaltextKeyword(s) to find specific subpages.

perform_search

Perform Search. Search the web using semantic or keyword-based search.

Also accepted as search.

InputTypeDescription
queryrequiredtextSearch query to find related articles and data.
typeoptionalone of "auto" | "keyword" | "neural"Type of search to perform.
categoryoptionalone of "company" | "research paper" | "news" | "pdf" | "github" | "tweet" | "personal site" | "linkedin profile" | "financial report"Category of data to focus the search on.
numResultsoptionalnumberNumber of results to return (max 100).
includeDomainsoptionalarrayLimit results to only these domains.
excludeDomainsoptionalarrayExclude results from these domains.
startCrawlDateoptionaldate-time (ISO)Only include results crawled after this ISO date.
endCrawlDateoptionaldate-time (ISO)Only include results crawled before this ISO date.
startPublishedDateoptionaldate-time (ISO)Only include results published after this ISO date.
endPublishedDateoptionaldate-time (ISO)Only include results published before this ISO date.
includeTextoptionalarrayStrings that must be present in the text of results.
excludeTextoptionalarrayStrings that must not be present in the text of results.

custom_api_call

Custom API Call. Make a custom API call to a specific endpoint

InputTypeDescription
urlrequiredobject (depends on other props)url
methodrequiredone of "GET" | "POST" | "PATCH" | "PUT" | "DELETE" | "HEAD"Method
headersrequiredobjectAuthorization headers are injected automatically from your connection.
queryParamsrequiredobjectQuery Parameters
body_typeoptionalone of "none" | "json" | "form_data" | "raw"Body Type
bodyoptionalobject (depends on other props)Body
response_is_binaryoptionalbooleanEnable for files like PDFs, images, etc.
failsafeoptionalbooleanNo Error on Failure
timeoutoptionalnumberTimeout (in seconds)
followRedirectsoptionalbooleanFollow redirects

generate_answer

Ask AI. Provides direct answers to queries by summarizing results.

InputTypeDescription
queryrequiredtextAsk a question to get summarized answers from the web.
textoptionalbooleanIf true, includes full text content from the search results
modelrequiredone of "exa" | "exa-pro"Choose the Exa model to use for the answer.

Details

Id
exa
Category
AI and ML
Tags
search, neural-search, web, ai, discovery
Package
@activepieces/piece-exa@0.1.5
Runs
Through the integration runner