Big News: Socket raises $60M Series C at a $1B valuation to secure software supply chains for AI-driven development.Announcement
Sign In

@wipcomputer/wip-grok

Package Overview
Dependencies
Maintainers
1
Versions
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@wipcomputer/wip-grok

xAI Grok API. Search the web, search X, generate images, generate video.

latest
Source
npmnpm
Version
1.0.2
Version published
Maintainers
1
Created
Source
WIP Computer

wip-grok

xAI Grok API. Search the web, search X, generate images, generate video. All from one module.

Sensor: search_web, search_x ... turns questions into knowledge. Actuator: generate_image, edit_image, generate_video ... turns prompts into media.

Zero dependencies. Four interfaces: CLI, Module, MCP Server, Skill.

Install

Open your AI coding tool and say:

Clone wipcomputer/wip-grok and read the README and SKILL.md.
Then explain to me:
1. What is this tool?
2. What does it do?
3. What would it change or fix in our current system?

Then ask me if I have more questions, or if I want you to integrate it into our system.

Your agent will read the repo, explain the tool, and walk you through integration interactively.

API Key

Get your xAI API key from https://console.x.ai/

The tool resolves your key automatically:

  • 1Password (preferred) ... op://Agent Secrets/X API/api key. No env vars needed.
  • Environment variable ... export XAI_API_KEY="your-key" as a fallback.

Usage

CLI

# Search (sensor)
wip-grok search-web "latest AI regulation developments"
wip-grok search-x "what people are saying about OpenAI"
wip-grok search-x "AI thoughts" --handles=elonmusk,kaboré --from=2026-01-01

# Image generation (actuator)
wip-grok imagine "a cat in space, photorealistic" --output=cat.png
wip-grok imagine "minimalist logo" --aspect=16:9 --n=4

# Image editing (actuator)
wip-grok edit "make the sky purple" --image=photo.jpg --output=edited.jpg

# Video generation (actuator)
wip-grok video "a sunset timelapse over the ocean" --duration=10 --resolution=720p --wait
wip-grok video "animate this image" --image=photo.jpg --output=animated.mp4

# Check video status
wip-grok video-status abc123

As a Module

import { search_web, search_x, generate_image, generate_video, wait_for_video } from '@wipcomputer/wip-grok';

// Sensor: search
const web = await search_web({ query: "UN climate summit" });
console.log(web.content);
console.log(web.citations);

const x = await search_x({
  query: "AI regulation",
  allowed_x_handles: ["elonmusk"],
  from_date: "2026-01-01",
});

// Actuator: generate
const img = await generate_image({ prompt: "a red cube on white", aspect_ratio: "1:1" });
console.log(img.images[0].url);

const vid = await generate_video({ prompt: "spinning globe", duration: 5 });
const result = await wait_for_video({ request_id: vid.request_id });
console.log(result.url);

MCP Server

Add to your .mcp.json:

{
  "wip-grok": {
    "command": "node",
    "args": ["/path/to/wip-grok/mcp-server.mjs"]
  }
}

Exposes 6 tools: grok_search_web, grok_search_x, grok_imagine, grok_edit_image, grok_generate_video, grok_poll_video.

Functions

FunctionWhatEndpoint
search_webWeb search via GrokPOST /v1/responses (web_search tool)
search_xX/Twitter search via GrokPOST /v1/responses (x_search tool)

Actuator (Generate)

FunctionWhatEndpointCost
generate_imageText to imagePOST /v1/images/generations$0.02/image
edit_imageEdit image with textPOST /v1/images/edits$0.022/image
generate_videoText/image to videoPOST /v1/video/generations$0.05-0.07/sec
poll_videoCheck video statusGET /v1/video/generations/:idfree
wait_for_videoPoll until complete(convenience wrapper)free

Attribution

Search functions ported from castanley/grok v1.0.3 by Christopher Stanley on ClawHub.

License

MIT

Built by Parker Todd Brooks, with Claude Code and Lēsa (OpenClaw).

Keywords

xai

FAQs

Package last updated on 21 Feb 2026

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts