> **Building with AI coding agents?** Install the authstack plugin with one command. This equips your agent with accurate Scalekit implementation patterns.
>
> **Recommended** (the `-y` flags skip prompts, so the command runs without an interactive terminal):
> ```bash
> npx -y @scalekit-inc/cli setup -y
> ```
>
> Global:
> ```bash
> npm install -g @scalekit-inc/cli
> scalekit setup -y
> ```
>
> Supports Claude Code, Cursor, GitHub Copilot, Codex + skills for other Agent Skills-compatible agents in `~/.agents/skills`.
> Skills: integrate-agentkit, implement-saaskit, add-mcp-oauth, implement-sso, implement-scim.
> [Full setup guide](https://docs.scalekit.com/dev-kit/build-with-ai/)

---

# Connect AI agents to AltTextLab

The AltTextLab connector lets your AI agent act in each user's AltTextLab account. Each user connects their own AltTextLab API key once, and Scalekit sends it with every call, so your agent never handles credentials. It comes with 1 tool.

**Authentication:** API Key
**Categories:** AI, Marketing
**Tools:** 1: 0 read, 1 write, 0 destructive
**Users sign in with:** API key
**Built by:** Scalekit connector
**Try it:** [Playground in the Scalekit dashboard](https://app.scalekit.com/ws/signup?sk_intent=playground&provider=ALTTEXTLAB)

## Setup

1. ### Install the SDK

   **Node.js**

   ```bash
   npm install @scalekit-sdk/node dotenv
   ```

   **Python**

   ```bash
   pip install scalekit-sdk-python python-dotenv
   ```

2. ### Set your credentials

   Add your Scalekit credentials to your `.env` file. Find values in **[app.scalekit.com](https://app.scalekit.com)** > **Developers** > **API Credentials**.

   ```sh title=".env"
   SCALEKIT_ENVIRONMENT_URL=<your-environment-url>
   SCALEKIT_CLIENT_ID=<your-client-id>
   SCALEKIT_CLIENT_SECRET=<your-client-secret>
   ```

3. ### Create the AltTextLab connection

   In **AgentKit > Connections**, create an AltTextLab connection. The name you give it is the `connection_name` your code passes. See [Configure connections](/agentkit/connections/).

4. ### Authorize a user and make your first call

   **Node.js** (`quickstart.mts`)

   ```typescript
   import { ScalekitClient } from '@scalekit-sdk/node'
   import 'dotenv/config'
   import { createInterface } from 'node:readline/promises'

   const scalekit = new ScalekitClient(
     process.env.SCALEKIT_ENVIRONMENT_URL,
     process.env.SCALEKIT_CLIENT_ID,
     process.env.SCALEKIT_CLIENT_SECRET,
   )
   const actions = scalekit.actions

   const connector = 'alttextlab'
   const identifier = 'user_123'

   // Generate an authorization link for the user
   const { link } = await actions.getAuthorizationLink({ connectionName: connector, identifier })
   console.log('Authorize AltTextLab:', link)
   const rl = createInterface({ input: process.stdin, output: process.stdout })
   await rl.question('Press Enter after authorizing...')
   rl.close()

   // Make your first call
   const result = await actions.executeTool({
     connector,
     identifier,
     toolName: 'alttextlab_alt_text_generate',
     toolInput: { image_url: 'https://example.com/images/mug.jpg' },
   })
   console.log(result)
   ```

   ```bash
   npx tsx quickstart.mts
   ```

   **Python** (`quickstart.py`)

   ```python
   import os
   from scalekit import ScalekitClient
   from dotenv import load_dotenv
   load_dotenv()

   scalekit_client = ScalekitClient(
       env_url=os.getenv("SCALEKIT_ENVIRONMENT_URL"),
       client_id=os.getenv("SCALEKIT_CLIENT_ID"),
       client_secret=os.getenv("SCALEKIT_CLIENT_SECRET"),
   )
   actions = scalekit_client.actions

   connection_name = "alttextlab"
   identifier = "user_123"

   # Generate an authorization link for the user
   link_response = actions.get_authorization_link(
       connection_name=connection_name,
       identifier=identifier,
   )
   print("Authorize AltTextLab:", link_response.link)
   input("Press Enter after authorizing...")

   # Make your first call
   result = actions.execute_tool(
       tool_input={"image_url":"https://example.com/images/mug.jpg"},
       tool_name="alttextlab_alt_text_generate",
       connection_name=connection_name,
       identifier=identifier,
   )
   print(result)
   ```

   ```bash
   python quickstart.py
   ```

   Each user opens the link once and enters their AltTextLab credentials there. See [Authorize a user](/agentkit/tools/authorize/) for the full flow and statuses.

## Tools

Pass the exact name to `execute_tool`, with an input like each tool's example. To ask for a tool that's missing, use the [request form](https://scalekitsupport.portal.usepylon.com/forms/request-a-connector-tool).

**Node.js**

```typescript
const result = await actions.executeTool({
  toolName: 'alttextlab_alt_text_generate',
  toolInput: {
    image_url: '<image_url>',
  },
  connector: 'alttextlab',
  identifier: 'user_123',
})
```

**Python**

```python
result = actions.execute_tool(
    tool_name="alttextlab_alt_text_generate",
    tool_input={
        "image_url": "<image_url>",
    },
    connection_name="alttextlab",
    identifier="user_123",
)
```

`result.data` is the app's response as JSON, and `result.execution_id` (`executionId` in Node.js) is the ID of the call.

### `alttextlab_alt_text_generate`

Generate Alt Text · Write

Generate alt text for a public image URL, in a chosen language and writing style, optionally steered by keywords, product details (e-commerce mode) or page context.
Returns id, result (the alt text, null on failure), status (generated or failed), lang, style, keywords, ecommerce and customFields.
Each generated result uses one credit; failed results do not.

Read only: no. Destructive: no. Idempotent (safe to retry): no.

Inputs:

- `image_url` (`string`, required): Public URL of the image, reachable without login or redirects. Example: https://example.com/images/mug.jpg.
- `brand` (`string`, optional): E-commerce mode: brand name. Example: Nike.
- `color` (`string`, optional): E-commerce mode: dominant color. Example: black.
- `context_description` (`string`, optional): Context: editorial description or explanation of the image. Example: Keynote at the 2025 product launch.
- `custom_fields` (`object`, optional): Up to 30 string key-value pairs echoed back unchanged, to match results to your assets. Example: {"sku": "TSHIRT-001"}.
- `keywords` (`array`, optional): Keywords to include when they fit what the image shows (not guaranteed). Example: ["eco-friendly", "minimalist"].
- `lang` (`string`, optional): Language code for the alt text (130+ supported); defaults to your account setting. Example: de.
- `material` (`string`, optional): E-commerce mode: product material. Example: leather.
- `page_title` (`string`, optional): Context: title of the page where the image appears. Example: Our team.
- `person_name` (`string`, optional): Context: name of the main person in the image. Example: Ada Lovelace.
- `product` (`string`, optional): E-commerce mode: product name or type. Any product field turns on e-commerce mode. Example: sneakers.
- `section_heading` (`string`, optional): Context: heading of the section containing the image. Example: Leadership.
- `style` (`string`, optional): Writing style: descriptive, neutral (default), matter-of-fact or minimal; defaults to your account setting. Example: minimal. One of: `descriptive`, `neutral`, `matter-of-fact`, `minimal`.
- `surrounding_text` (`string`, optional): Context: caption or text near the image. Example: Our CEO opens the event.

Example input: `{"image_url":"<image_url>"}`

## Related

Other AI connectors ([all 216](/agentkit/connectors/?category=ai)):

- [Chorus](/agentkit/connectors/chorus/): Scalekit connector, Username and password, 9 tools
- [Gong](/agentkit/connectors/gong/): Scalekit connector, OAuth, 69 tools
- [Jiminny](/agentkit/connectors/jiminny/): Scalekit connector, Access token, 27 tools


---

## More Scalekit documentation

| Resource | What it contains | When to use it |
|----------|-----------------|----------------|
| [/llms.txt](/llms.txt) | Structured index with routing hints per product area | Start here — find which documentation set covers your topic before loading full content |
| [/llms-full.txt](/llms-full.txt) | Complete documentation for all Scalekit products in one file | Use when you need exhaustive context across multiple products or when the topic spans several areas |
| [sitemap-0.xml](https://docs.scalekit.com/sitemap-0.xml) | Full URL list of every documentation page | Use to discover specific page URLs you can fetch for targeted, page-level answers |
