Archive API docs
    Jump to

    Narrow by kind with a prefix — q: queries, m: mutations, t: types, g: guides, f: fields and arguments.

    Example prompts

    Copy these into your client to explore what’s possible. Each one lists the tools it calls, so you can follow along in the tool log.

    Surface top content

    “Show me our 10 best-performing TikTok posts from the last 30 days, with a link to each one.”

    Calls getWorkspaces, then searchItems.

    The agent resolves the workspace first, then searches with responseFormat: "concise" — each node keeps originalUrl and currentEngagement, which is all a ranking needs.

    tools/call — searchItems
    {
    "jsonrpc": "2.0",
    "id": 3,
    "method": "tools/call",
    "params": {
      "name": "searchItems",
      "arguments": {
        "workspaceId": "6ccefa76-e8ba-5ab0-9c60-e48a9e235a4a",
        "filters": { "itemTypes": ["TIKTOK"] },
        "responseFormat": "concise",
        "limit": 10
      }
    }
    }

    Creator lookup

    “Who are the creators behind our most viral posts this quarter? Pull their handles and follower counts.”

    Calls searchItems, then searchCreators.

    Concise searchItems returns creator { id } on every node — the join key for matching posts to creator records. Matching on handle is unsafe: a workspace can hold two creators sharing one.

    Save a reusable view

    “Create a content view called ‘Q3 UGC winners’ with the same filters as our ‘UGC — all time’ view, and add it to the Campaigns group.”

    Calls getContentViews, then createContentView.

    The agent clones the existing view’s filters rather than composing one from scratch, and inspects userErrors before reporting success — a duplicate name comes back as a domain rejection, not a crash. See Agent conventions for why both matter.

    Import a post

    “Add this Instagram post to Archive and tell me when it’s ready: instagram.com/p/…”

    Calls uploadItemFromUrl, then getOperation.

    uploadItemFromUrl is asynchronous: a success payload means the import was enqueued, not that it finished. The agent polls getOperation for the result, and doesn’t retry the upload on a timeout — a duplicate runs the import twice.

    Workflow prompt: weekly content report

    For recurring work, a structured prompt is more reliable than a one-liner. This one produces a weekly report from recent content:

    Copy into Claude
    You are compiling our weekly content report from Archive.
    
    1. Confirm the workspace with me before doing anything else.
    2. Pull the top 15 posts from the last 7 days by engagement,
     using concise responses.
    3. Group them by platform, and for each group note the
     best-performing creator (join on creator id, never on handle).
    4. Compare against the same window last week and call out
     anything that doubled or halved.
    5. Do not create or modify anything — this is a read-only report.
     If a tool call fails, show me the error instead of retrying.