Salesforce Sales Cloud · Arazzo Workflow

Salesforce Sales Cloud Opportunity With Contact Role

Version 1.0.0

Open an Opportunity, then attach a Contact to it as an OpportunityContactRole.

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

Provider

salesforce-sales-cloud

Workflows

opportunity-with-contact-role
Create an Opportunity and attach a Contact as a contact role.
Creates an Opportunity tied to an Account, then creates an OpportunityContactRole record referencing the new Opportunity and the supplied Contact.
2 steps inputs: accessToken, accountId, closeDate, contactId, isPrimary, opportunityName, role, stageName outputs: contactRoleId, opportunityId
1
createOpportunity
Open the Opportunity against the supplied Account.
2
addContactRole
Link the Contact to the new Opportunity as a contact role.

Source API Descriptions

Arazzo Workflow Specification

Raw ↑
arazzo: 1.0.1
info:
  title: Salesforce Sales Cloud Opportunity With Contact Role
  summary: Open an Opportunity, then attach a Contact to it as an OpportunityContactRole.
  description: >-
    Models the deal-stakeholder pattern over the SObject Rows resource. The
    workflow opens an Opportunity against an existing Account, then creates an
    OpportunityContactRole junction record linking a Contact to that Opportunity
    with a named role and primary flag. 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: opportunity-with-contact-role
  summary: Create an Opportunity and attach a Contact as a contact role.
  description: >-
    Creates an Opportunity tied to an Account, then creates an
    OpportunityContactRole record referencing the new Opportunity and the
    supplied Contact.
  inputs:
    type: object
    required:
    - accessToken
    - accountId
    - contactId
    - opportunityName
    - closeDate
    - stageName
    - role
    properties:
      accessToken:
        type: string
        description: OAuth 2.0 access token used as the Bearer credential.
      accountId:
        type: string
        description: Id of the existing Account the Opportunity belongs to.
      contactId:
        type: string
        description: Id of the Contact to attach as a contact role.
      opportunityName:
        type: string
        description: Name of the Opportunity to create.
      closeDate:
        type: string
        description: Close date for the Opportunity (YYYY-MM-DD).
      stageName:
        type: string
        description: Stage name for the Opportunity.
      role:
        type: string
        description: The contact role label (e.g. "Decision Maker").
      isPrimary:
        type: boolean
        description: Whether this contact is the primary contact on the Opportunity.
        default: true
  steps:
  - stepId: createOpportunity
    description: Open the Opportunity against the supplied Account.
    operationId: createSObjectRecord
    parameters:
    - name: Authorization
      in: header
      value: Bearer $inputs.accessToken
    - name: sObjectName
      in: path
      value: Opportunity
    requestBody:
      contentType: application/json
      payload:
        Name: $inputs.opportunityName
        AccountId: $inputs.accountId
        CloseDate: $inputs.closeDate
        StageName: $inputs.stageName
    successCriteria:
    - condition: $statusCode == 201
    outputs:
      opportunityId: $response.body#/id
  - stepId: addContactRole
    description: Link the Contact to the new Opportunity as a contact role.
    operationId: createSObjectRecord
    parameters:
    - name: Authorization
      in: header
      value: Bearer $inputs.accessToken
    - name: sObjectName
      in: path
      value: OpportunityContactRole
    requestBody:
      contentType: application/json
      payload:
        OpportunityId: $steps.createOpportunity.outputs.opportunityId
        ContactId: $inputs.contactId
        Role: $inputs.role
        IsPrimary: $inputs.isPrimary
    successCriteria:
    - condition: $statusCode == 201
    outputs:
      contactRoleId: $response.body#/id
  outputs:
    opportunityId: $steps.createOpportunity.outputs.opportunityId
    contactRoleId: $steps.addContactRole.outputs.contactRoleId

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-opportunity-with-contact-role-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.