Quickstart

From a fresh terminal to your first contact upserted into SendGrid, Mailchimp, or Klaviyo in under five minutes — assuming the prerequisites below.

Before you start

CLI install: the public quickstart uses the published @vorlek/cli package. You do not need source repository access.

Version note: the CLI package, SKILL file, SDK/MCP packages, and API/docs changelog are versioned independently. Check the CLI with vorlek --version or npm view @vorlek/cli version.

Step 1 — Install the CLI

npm install -g @vorlek/cli
vorlek --version

If your environment blocks global npm installs, run the CLI in a temporary project with npm install @vorlek/cli and npx vorlek --version.

Step 2 — Sign up

vorlek auth signup

Interactive prompts ask for an email and a password (≥ 8 chars). You get back two API keys:

Already have an API key?

If you received a Vorlek API key for a smoke test, CI probe, or shared workspace, use it directly instead of signing up:

vorlek auth use --api-key "$VORLEK_API_KEY" --api-base https://api.vorlek.com
vorlek status

Keep API keys out of transcripts, shell history, and shared logs. Redact the key value if you need to attach command output.

Test mode

Use the one-time vk_test_… key from signup in CI, agent evals, and retry-path tests. Vorlek still runs auth, idempotency, validation, quota, rate-limit, and circuit-breaker middleware, but adapter HTTP calls are replaced by deterministic fixtures and every SDK result carries meta.test_mode: true.

Test traffic is isolated: it uses a 10,000-call test quota plus separate rate-limit and circuit buckets, so synthetic failures never trip a live provider breaker.

Outcome headerHTTPError code
success or omitted200n/a
rate_limited429RATE_LIMITED
provider_unavailable503PROVIDER_UNAVAILABLE
invalid_params400INVALID_PARAMS
tool_not_supported501TOOL_NOT_SUPPORTED
provider_failed502PROVIDER_FAILED

Example CI probe for an agent retry path:

curl -X POST https://api.vorlek.com/v1/tools/upsert_contact \
  -H "Authorization: Bearer vk_test_xxxxxxxxxxxxxxxxxxxxxxxx" \
  -H "Idempotency-Key: 01HV8K5K7JJZ7JWQ9X0F7G8Q3A" \
  -H "X-Vorlek-Test-Outcome: rate_limited" \
  -H "Content-Type: application/json" \
  -d '{
    "provider": "sendgrid",
    "email": "retry-path@example.com"
  }'

The response is a normal error envelope with meta.test_mode: true and a Retry-After header, so the same retry handler can run in test and live mode.

Step 3 — Connect a provider

vorlek connect sendgrid --api-key SG.your_sendgrid_key_here
# or
vorlek connect mailchimp --api-key your_key-us7 --list-id a1b2c3d4e5
# or
vorlek connect klaviyo --api-key pk_your_klaviyo_private_key

Vorlek validates the key against the provider, encrypts it with AES-256-GCM, and stores the ciphertext server-side. If the key is wrong or lacks scope, you get a clear error before anything is stored.

Step 4 — Upsert your first contact

vorlek contact upsert \
  --email jamie@example.com \
  --first-name Jamie \
  --properties '{"plan":"free","loyalty_tier":"gold"}'

Behind the scenes:

  1. Vorlek normalizes the input + dispatches to the SendGrid adapter.
  2. For each property the adapter doesn't know yet (plan, loyalty_tier), it auto-creates the field at SendGrid and records the mapping.
  3. It calls PUT /v3/marketing/contacts and returns the unified envelope.

Successful output:

contact_id        f1ec8680-...
action            upserted
fields_auto_created   plan, loyalty_tier
provider          sendgrid
quota             1 / 1000 (resets 2026-05-01)

Step 5 — Verify in SendGrid

Open mc.sendgrid.com/contacts and search for jamie@example.com. You should see the contact with plan and loyalty_tier populated. If the new fields don't appear in the contact yet, give it 1–2 minutes — SendGrid takes a moment to index newly-created custom fields.

What's next

Direct API call (no CLI)

If you'd rather skip the CLI and call the REST API yourself:

curl -X POST https://api.vorlek.com/v1/tools/upsert_contact \
  -H "Authorization: Bearer vk_live_xxxxxxxxxxxxxxxxxxxxxxxx" \
  -H "Content-Type: application/json" \
  -d '{
    "email": "jamie@example.com",
    "first_name": "Jamie",
    "properties": {"plan": "free", "loyalty_tier": "gold"}
  }'

You get a Vorlek key the same way — POST https://api.vorlek.com/v1/accounts/signup with {"email": "...", "password": "≥12 chars"} returns the live + test keys.