# Add Invite Request — Repuso

> Add an invite request See docs here

- Key: `repuso-add-invite-request`
- Type: Action (Write)
- Version: 0.0.2
- App: Repuso (`repuso`) — https://pipedream.com/apps/repuso.md
- This page (HTML): https://pipedream.com/apps/repuso/actions/add-invite-request
- Hints: open-world
- Source: https://github.com/PipedreamHQ/pipedream/blob/master/components/repuso/actions/add-invite-request/add-invite-request.ts

## Description

Add an invite request [See docs here](https://documenter.getpostman.com/view/4975691/TzzGFYg3#f417c9ce-2376-495c-85c3-bdcfc204eee2)

## Props

| Prop | Type | Required | Description |
|---|---|---|---|
| `recipient` | `string` | Yes | Recipient Email |
| `schedule` | `string` | No | Use a date/time string such as 2021-08-30 16:00:00, or leave empty for the default settings |
| `name` | `string` | No | Name |

## Run it

**MCP**

```ts
import { Client } from "@modelcontextprotocol/sdk/client/index.js"
import { StreamableHTTPClientTransport } from "@modelcontextprotocol/sdk/client/streamableHttp.js"
import { PipedreamClient } from "@pipedream/sdk"

const pd = new PipedreamClient({
  projectId: process.env.PIPEDREAM_PROJECT_ID!,
  clientId: process.env.PIPEDREAM_CLIENT_ID!,
  clientSecret: process.env.PIPEDREAM_CLIENT_SECRET!,
  projectEnvironment: "production",
})

const accessToken = await pd.rawAccessToken

const transport = new StreamableHTTPClientTransport(
  new URL("https://remote.mcp.pipedream.net/v3"),
  {
    requestInit: {
      headers: {
        Authorization: `Bearer ${accessToken}`,
        "x-pd-project-id": process.env.PIPEDREAM_PROJECT_ID!,
        "x-pd-environment": "production",
        "x-pd-external-user-id": "{external_user_id}", // any stable ID for this user in your system
        "x-pd-app-slug": "repuso",
      },
    },
  },
)

const mcp = new Client({ name: "my-agent", version: "1.0.0" })
await mcp.connect(transport)

const { tools } = await mcp.listTools()

// listTools() hands your model this tool's input schema, so it can
// fill the arguments itself:
const result = await mcp.callTool({
  name: "repuso-add-invite-request",
  arguments: {
    recipient: "Recipient Email",
    schedule: "Schedule",
  },
})
```

**TypeScript**

```ts
import { PipedreamClient } from "@pipedream/sdk"

const pd = new PipedreamClient({
  projectId: process.env.PIPEDREAM_PROJECT_ID!,
  clientId: process.env.PIPEDREAM_CLIENT_ID!,
  clientSecret: process.env.PIPEDREAM_CLIENT_SECRET!,
  projectEnvironment: "production",
})

const result = await pd.actions.run({
  id: "repuso-add-invite-request",
  externalUserId: "{external_user_id}", // any stable ID for this user in your system
  configuredProps: {
    repuso: { authProvisionId: "apn_xxxxxxx" },
    recipient: "Recipient Email",
    schedule: "Schedule",
  },
})

console.log(result)
```

**cURL**

```bash
curl -X POST https://api.pipedream.com/v1/connect/{project_id}/actions/run \
  -H "Content-Type: application/json" \
  -H "X-PD-Environment: production" \
  -H "Authorization: Bearer {access_token}" \
  -d '{
    "external_user_id": "{external_user_id}",
    "id": "repuso-add-invite-request",
    "configured_props": {
      "repuso": { "authProvisionId": "apn_xxxxxxx" },
      "recipient": "Recipient Email",
      "schedule": "Schedule"
    }
  }'
```

---

- App: https://pipedream.com/apps/repuso.md · All apps: https://pipedream.com/apps
