Skip to main content
Job: trigger the same workflow from the place your team already works.

CLI: run a local file

deepline plays check enrich.play.ts
deepline plays run enrich.play.ts --input '{"domain":"stripe.com"}' --watch

CLI: run a named play

deepline plays run prebuilt/person-linkedin-to-email \
  --input '{"linkedin_url":"https://www.linkedin.com/in/example-person/"}' \
  --watch

TypeScript: call from an app or script

TypeScript apps can call the same workflow the CLI runs.
import { Deepline } from 'deepline';

const deepline = await Deepline.connect();
const job = await deepline.play('prebuilt/person-linkedin-to-email').run({
  linkedin_url: 'https://www.linkedin.com/in/example-person/',
});
const result = await job.get();
console.log(result);

Inside another play

import { definePlay } from 'deepline';

export default definePlay(
  'call-enrichment-step',
  async (ctx, input: { domain: string }) => {
    const company = await ctx.tools.execute({
      id: 'company_lookup',
      tool: 'test_rate_limit',
      input: { key: input.domain },
      description: 'Look up one company.',
    });

    return { company_status: company.status };
  },
);
Use ctx.runPlay(...) for child plays that are statically resolvable in your workspace. Use ctx.tools.execute(...) when one provider/tool call is the step you need.

HTTP: call from any runtime

curl -X POST "$DEEPLINE_HOST_URL/api/v2/plays/run" \
  -H "Authorization: Bearer $DEEPLINE_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"name":"prebuilt/person-linkedin-to-email","input":{"linkedin_url":"https://www.linkedin.com/in/example-person/"}}'
The response includes a workflow id. Poll that id until the run finishes.