Salesforce Sales Cloud · Arazzo Workflow

Salesforce Sales Cloud Close Opportunity Won

Version 1.0.0

Move an Opportunity to Closed Won, then read it back and log a follow-up Task.

1 workflow 1 source API 1 provider
View Spec View on GitHub CloudCRMCustomer ManagementEnterpriseSalesArazzoWorkflows

Provider

salesforce-sales-cloud

Workflows

close-opportunity-won
Update an Opportunity to Closed Won, verify, and log a follow-up Task.
Patches the Opportunity stage and amount, retrieves it to confirm the stage, then creates a Task linked to the Opportunity through WhatId.
3 steps inputs: accessToken, amount, closedStage, followUpSubject, opportunityId outputs: finalStage, taskId
1
closeOpportunity
Patch the Opportunity to the Closed Won stage with the final amount.
2
verifyOpportunity
Read the Opportunity back to confirm the stage advanced.
3
logFollowUp
Log a follow-up Task linked to the won Opportunity.

Source API Descriptions

Arazzo Workflow Specification

Raw ↑
arazzo: 1.0.1
info:
  title: Salesforce Sales Cloud Close Opportunity Won
  summary: Move an Opportunity to Closed Won, then read it back and log a follow-up Task.
  description: >-
    A deal-closing pattern over the SObject Rows resource. The workflow patches
    an Opportunity to a Closed Won stage with an amount, reads the record back to
    confirm the new stage, and logs a follow-up Task referencing the Opportunity
    so the win is actioned. Every step inlines its request and the OAuth bearer
    Authorization header.
  version: 1.0.0
sourceDescriptions:
- name: sobjectRowsApi
  url: ../openapi/salesforce-sales-cloud-sobject-rows-api-openapi.yml
  type: openapi
workflows:
- workflowId: close-opportunity-won
  summary: Update an Opportunity to Closed Won, verify, and log a follow-up Task.
  description: >-
    Patches the Opportunity stage and amount, retrieves it to confirm the stage,
    then creates a Task linked to the Opportunity through WhatId.
  inputs:
    type: object
    required:
    - accessToken
    - opportunityId
    - closedStage
    properties:
      accessToken:
        type: string
        description: OAuth 2.0 access token used as the Bearer credential.
      opportunityId:
        type: string
        description: Id of the Opportunity to close.
      closedStage:
        type: string
        description: The Closed Won stage name configured in the org.
      amount:
        type: number
        description: Final deal amount to stamp on the Opportunity.
      followUpSubject:
        type: string
        description: Subject of the follow-up Task to log on the won deal.
        default: Kick off won deal
  steps:
  - stepId: closeOpportunity
    description: Patch the Opportunity to the Closed Won stage with the final amount.
    operationId: updateSObjectRecord
    parameters:
    - name: Authorization
      in: header
      value: Bearer $inputs.accessToken
    - name: sObjectName
      in: path
      value: Opportunity
    - name: recordId
      in: path
      value: $inputs.opportunityId
    requestBody:
      contentType: application/json
      payload:
        StageName: $inputs.closedStage
        Amount: $inputs.amount
    successCriteria:
    - condition: $statusCode == 204
  - stepId: verifyOpportunity
    description: Read the Opportunity back to confirm the stage advanced.
    operationId: getSObjectRecord
    parameters:
    - name: Authorization
      in: header
      value: Bearer $inputs.accessToken
    - name: sObjectName
      in: path
      value: Opportunity
    - name: recordId
      in: path
      value: $inputs.opportunityId
    - name: fields
      in: query
      value: Id,Name,StageName,Amount
    successCriteria:
    - condition: $statusCode == 200
    outputs:
      stageName: $response.body#/StageName
  - stepId: logFollowUp
    description: Log a follow-up Task linked to the won Opportunity.
    operationId: createSObjectRecord
    parameters:
    - name: Authorization
      in: header
      value: Bearer $inputs.accessToken
    - name: sObjectName
      in: path
      value: Task
    requestBody:
      contentType: application/json
      payload:
        Subject: $inputs.followUpSubject
        Status: Not Started
        WhatId: $inputs.opportunityId
    successCriteria:
    - condition: $statusCode == 201
    outputs:
      taskId: $response.body#/id
  outputs:
    finalStage: $steps.verifyOpportunity.outputs.stageName
    taskId: $steps.logFollowUp.outputs.taskId

Work with this as data

Every workflow here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for arazzo workflows

4 MCP tools reach this
  • find_arazzoBrowse and filter every workflow in the catalog.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This workflow
curl "https://apis.io/api/v1/arazzo/salesforce-sales-cloud-close-opportunity-won-workflow"
All arazzo workflows
curl "https://apis.io/api/v1/arazzo?limit=25"

Discovery needs no key. Ratings and market analysis are Pro.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.