# Microsoft Dynamics 365 Sales — Pipedream Connect

> Close more deals and increase seller efficiency with an AI-powered CRM solution.

- API slug: `microsoft_dynamics_365_sales` (use in MCP headers and tool keys)
- Auth: OAuth (Pipedream-managed)
- Categories: CRM
- Website: https://www.microsoft.com/en-us/dynamics-365/products/sales
- Managed OAuth scopes: `email` · `offline_access` · `openid` · `profile`
- This page (HTML): https://pipedream.com/apps/microsoft-dynamics-365-sales
- Tools: 12 actions · 15 triggers

## Connect via MCP (recommended)

- Endpoint: `https://remote.mcp.pipedream.net/v3`
- Headers: `Authorization: Bearer <token>` · `x-pd-project-id` · `x-pd-environment` · `x-pd-external-user-id` · `x-pd-app-slug: microsoft_dynamics_365_sales`

```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": "microsoft_dynamics_365_sales",
      },
    },
  },
)

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

const { tools } = await mcp.listTools()

// e.g. run Create Appointment:
const result = await mcp.callTool({
  name: "microsoft_dynamics_365_sales-create-appointment",
  arguments: {
    subject: "Subject",
    scheduledstart: "Scheduled Start",
  },
})
```

Docs: [MCP guide](https://pipedream.com/docs/connect/mcp/developers.md)

## API proxy

For a Microsoft Dynamics 365 Sales endpoint with no pre-built tool, the proxy forwards your request with the connected user's credentials attached.

```bash
# The path segment is the target URL, URL-safe base64 encoded:
# https://api.example.com/v1/me

curl "https://api.pipedream.com/v1/connect/{project_id}/proxy/aHR0cHM6Ly9hcGkuZXhhbXBsZS5jb20vdjEvbWU?external_user_id={external_user_id}&account_id=apn_xxxxxxx" \
  -H "Authorization: Bearer {access_token}" \
  -H "x-pd-environment: production"
```

Docs: [API proxy guide](https://pipedream.com/docs/connect/api-proxy.md)

## SDK

```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: "microsoft_dynamics_365_sales-create-appointment",
  externalUserId: "{external_user_id}", // any stable ID for this user in your system
  configuredProps: {
    microsoft_dynamics_365_sales: { authProvisionId: "apn_xxxxxxx" },
    subject: "Subject",
    scheduledstart: "Scheduled Start",
  },
})
```

Docs: [Managed auth guide](https://pipedream.com/docs/connect/managed-auth/quickstart.md) · [Tools guide](https://pipedream.com/docs/connect/components.md)

## Actions (12)

### `microsoft_dynamics_365_sales-create-appointment` — Create Appointment (Write)

Create a new appointment linked to an account with a required attendee (system user). Use List Appointment Categories for valid category values. See the documentation and the appointment entity reference

Full schema: https://pipedream.com/apps/microsoft-dynamics-365-sales/actions/create-appointment.md

### `microsoft_dynamics_365_sales-create-custom-entity` — Create Custom Entity (Write)

Create a custom entity. See the documentation

Full schema: https://pipedream.com/apps/microsoft-dynamics-365-sales/actions/create-custom-entity.md

### `microsoft_dynamics_365_sales-find-contact` — Find Contact (Read-only)

Search for a contact by id, name, or using a custom filter. See the documentation

Full schema: https://pipedream.com/apps/microsoft-dynamics-365-sales/actions/find-contact.md

### `microsoft_dynamics_365_sales-get-account` — Get Account (Read-only)

Retrieve a single account by GUID. See the documentation

Full schema: https://pipedream.com/apps/microsoft-dynamics-365-sales/actions/get-account.md

### `microsoft_dynamics_365_sales-list-accounts` — List Accounts (Read-only)

List accounts with selected fields (accountid, name, phone, email, primary contact). See the documentation

Full schema: https://pipedream.com/apps/microsoft-dynamics-365-sales/actions/list-accounts.md

### `microsoft_dynamics_365_sales-list-appointment-categories` — List Appointment Categories (Read-only)

List Category of Appointment options for the custom attribute used by create/update appointment actions (loaded from metadata or distinct values on existing rows). See the documentation

Full schema: https://pipedream.com/apps/microsoft-dynamics-365-sales/actions/list-appointment-categories.md

### `microsoft_dynamics_365_sales-list-appointment-category-options` — List Appointment Category Options (Read-only)

Retrieves available options for the Category of appointment field.

Full schema: https://pipedream.com/apps/microsoft-dynamics-365-sales/actions/list-appointment-category-options.md

### `microsoft_dynamics_365_sales-list-appointments` — List Appointments (Read-only)

List appointments (full entity per row, ordered by scheduled start descending). See the documentation

Full schema: https://pipedream.com/apps/microsoft-dynamics-365-sales/actions/list-appointments.md

### `microsoft_dynamics_365_sales-list-solution-id-options` — List Solution ID Options (Read-only)

Retrieves available options for the Solution ID field.

Full schema: https://pipedream.com/apps/microsoft-dynamics-365-sales/actions/list-solution-id-options.md

### `microsoft_dynamics_365_sales-search-accounts` — Search Accounts (Read-only)

Search accounts by company name using contains(name, …). See the documentation

Full schema: https://pipedream.com/apps/microsoft-dynamics-365-sales/actions/search-accounts.md

### `microsoft_dynamics_365_sales-update-account` — Update Account (Write)

Update an existing account; only the fields you supply are sent. See the account entity reference for the full list of updatable fields. See the documentation

Full schema: https://pipedream.com/apps/microsoft-dynamics-365-sales/actions/update-account.md

### `microsoft_dynamics_365_sales-update-appointment` — Update Appointment (Write)

Patch an appointment; only supplied fields are sent. Use List Appointment Categories for category values. See the documentation and the appointment entity reference

Full schema: https://pipedream.com/apps/microsoft-dynamics-365-sales/actions/update-appointment.md

## Triggers (15)

### `microsoft_dynamics_365_sales-account-ownership-changed` — Account Ownership Changed (Polling)

Emit new event when the ownership of an account changes.

Full schema: https://pipedream.com/apps/microsoft-dynamics-365-sales/triggers/account-ownership-changed.md

### `microsoft_dynamics_365_sales-account-status-changed` — Account Status Changed (Polling)

Emit new event when an account is activated or deactivated.

Full schema: https://pipedream.com/apps/microsoft-dynamics-365-sales/triggers/account-status-changed.md

### `microsoft_dynamics_365_sales-contact-added-to-account` — Contact Added to Account (Polling)

Emit new event when a contact is added to an account.

Full schema: https://pipedream.com/apps/microsoft-dynamics-365-sales/triggers/contact-added-to-account.md

### `microsoft_dynamics_365_sales-new-account-activity` — New Account Activity (Polling)

Emit new event when a new task or activity is created for an account.

Full schema: https://pipedream.com/apps/microsoft-dynamics-365-sales/triggers/new-account-activity.md

### `microsoft_dynamics_365_sales-new-account-created` — New Account Created (Polling)

Emit new event when a new account is created.

Full schema: https://pipedream.com/apps/microsoft-dynamics-365-sales/triggers/new-account-created.md

### `microsoft_dynamics_365_sales-new-opportunity-activity` — New Opportunity Activity (Polling)

Emit new event when a new task or activity is created for an opportunity.

Full schema: https://pipedream.com/apps/microsoft-dynamics-365-sales/triggers/new-opportunity-activity.md

### `microsoft_dynamics_365_sales-new-opportunity-created` — New Opportunity Created (Polling)

Emit new event when a new opportunity is created.

Full schema: https://pipedream.com/apps/microsoft-dynamics-365-sales/triggers/new-opportunity-created.md

### `microsoft_dynamics_365_sales-opportunity-close-date-updated` — Opportunity Close Date Updated (Polling)

Emit new event when the estimated close date of an opportunity is updated.

Full schema: https://pipedream.com/apps/microsoft-dynamics-365-sales/triggers/opportunity-close-date-updated.md

### `microsoft_dynamics_365_sales-opportunity-close-probability-updated` — Opportunity Close Probability Updated (Polling)

Emit new event when the close probability of an opportunity is updated.

Full schema: https://pipedream.com/apps/microsoft-dynamics-365-sales/triggers/opportunity-close-probability-updated.md

### `microsoft_dynamics_365_sales-opportunity-contact-changed` — Opportunity Contact Changed (Polling)

Emit new event when an opportunity's contact is changed.

Full schema: https://pipedream.com/apps/microsoft-dynamics-365-sales/triggers/opportunity-contact-changed.md

### `microsoft_dynamics_365_sales-opportunity-estimated-value-updated` — Opportunity Estimated Value Updated (Polling)

Emit new event when the estimated value of an opportunity is updated.

Full schema: https://pipedream.com/apps/microsoft-dynamics-365-sales/triggers/opportunity-estimated-value-updated.md

### `microsoft_dynamics_365_sales-opportunity-marked-won-or-lost` — Opportunity Marked Won or Lost (Polling)

Emit new event when an opportunity is marked as won or lost.

Full schema: https://pipedream.com/apps/microsoft-dynamics-365-sales/triggers/opportunity-marked-won-or-lost.md

### `microsoft_dynamics_365_sales-opportunity-ownership-changed` — Opportunity Ownership Changed (Polling)

Emit new event when the ownership of an opportunity changes.

Full schema: https://pipedream.com/apps/microsoft-dynamics-365-sales/triggers/opportunity-ownership-changed.md

### `microsoft_dynamics_365_sales-opportunity-reopened` — Opportunity Reopened (Polling)

Emit new event when an opportunity is reopened.

Full schema: https://pipedream.com/apps/microsoft-dynamics-365-sales/triggers/opportunity-reopened.md

### `microsoft_dynamics_365_sales-opportunity-stage-updated` — Opportunity Stage Updated (Polling)

Emit new event when the stage of an opportunity is updated.

Full schema: https://pipedream.com/apps/microsoft-dynamics-365-sales/triggers/opportunity-stage-updated.md

---

- All apps: https://pipedream.com/apps — index: https://pipedream.com/llms.txt
- Pipedream docs for agents: https://pipedream.com/docs/llms.txt
