# Setup with agent

Install the Vask realtime skill, then let your AI agent wire the right Pusher-compatible setup for your stack.

This guide is intentionally framework-agnostic. Your agent should inspect the codebase first, then choose the Pusher-compatible server and client setup that fits the app already in front of it.

## Recommended: install the skill

For JavaScript, TypeScript, Rails, Django, PHP, or other non-Laravel projects, install the public Vask skill:

```bash
npx skills add vask-dev/skills --skill vask-realtime
```

Then ask your agent:

```text
Use $vask-realtime to set up Vask realtime WebSockets in this app.
```

The skill includes the Vask agent signup flow. If your local SSH key is published on GitHub, the agent can register or recover a default Vask app by signing a short payload with your SSH key and calling `https://vask.dev/api/agent-signup`. No browser, OAuth prompt, password, or CAPTCHA is needed for that path.

Laravel users should usually install [`vask/laravel`](/docs/laravel) instead; it has Laravel-native setup, diagnostics, and webhook helpers.

## Copy-paste fallback prompt

Use this prompt if your agent does not support skills yet. Paste it into Claude, Codex, Cursor, Windsurf, or any agent that can edit your app directly.

```text
# Integrate Vask into this app

Vask is a low-latency Pusher-compatible websocket platform powered by Cloudflare.

Implement or migrate to a complete Vask integration for this codebase using the stack and conventions already present in the project.

Goal:
- send server-side events through Vask
- subscribe from the client
- keep the implementation production-ready
- use existing framework patterns instead of inventing a parallel setup

Use these Vask values:
- app key: YOUR_VASK_APP_KEY
- key: YOUR_VASK_APP_KEY
- secret: YOUR_VASK_SECRET
- host: wss.vask.dev
- port: 443
- scheme: https / wss
- auth endpoint: YOUR_AUTH_ENDPOINT_IF_USING_PRIVATE_OR_PRESENCE_CHANNELS

Requirements:
- install the correct Pusher-compatible server and client libraries for this stack
- configure the server broadcaster/client with the Vask credentials
- add one end-to-end example event and one example channel subscription
- if the app uses private or presence channels, wire auth with the app's existing auth system
- map the credentials into whatever env vars or config files this stack already uses
- use env/config files for secrets, not hardcoded values
- explain which files changed and how to run the integration locally
- ensure you use the Vask app_key anywhere a Pusher-compatible SDK asks for app id or key, and ensure you send a valid origin header

Constraints:
- choose the framework-specific implementation details yourself
- do not assume Laravel or any specific framework unless this repo already uses it
- do not change unrelated architecture
- keep code minimal and idiomatic for this project

If you don't have the details you need, ask me.
```

## Replace these values first

- **YOUR_VASK_APP_KEY** - your public Vask app key. Use this anywhere a Pusher-compatible SDK asks for app id or key.
- **YOUR_VASK_SECRET** - your server secret.
- **YOUR_VASK_HOST** - your Vask host, usually the app host you were given.
- **443** and **https** - keep these unless Vask told you to use a different port or scheme.
- **YOUR_AUTH_ENDPOINT_IF_USING_PRIVATE_OR_PRESENCE_CHANNELS** - only needed for protected channels.

## Need a manual guide?

If you want a concrete framework example instead, use the [Laravel integration guide](/docs/laravel).
