---
title: "Create an opportunity"
method: POST
path: "/opportunities"
tags: ["Opportunities"]
---

# Create an opportunity

`POST /opportunities`

## Request

- Base URL: `https://www.ruddr.io/api/workspace`
- URL: `https://www.ruddr.io/api/workspace/opportunities`
- Auth: HTTP bearer

## Request body

- object
  - `name` string, required: The name of the opportunity. Max 255 characters.
  - `description` string, nullable: A description of the opportunity. Max 5000 characters.
  - `nextSteps` string, nullable: The next steps for the opportunity. Max 255 characters.
  - `amount` number, nullable: The monetary amount of the opportunity.
  - `probability` number: The probability of the opportunity closing successfully. Accepts a value of 0 to 1 using a maximum of four decimals.
  - `priorityId` 'high' | 'medium' | 'low', nullable: The priority of the opportunity.
  - `openDate` string, date: The open date of the opportunity in `YYYY-MM-DD` format. Defaults to the creation date if not provided.
  - `closeDate` string, date, nullable: The expected close date of the opportunity in `YYYY-MM-DD` format.
  - `currency` string: The 3-letter currency code for the opportunity. Defaults to the workspace currency if not provided.
  - `cloudFolderUrl` string, nullable: A URL to a cloud folder associated with the opportunity. Max 1024 characters.
  - `ownerId` string, nullable: The member ID (`uuid`) of the owner of the opportunity.
  - `opportunityLeadSourceId` string, nullable: The ID (`uuid`) of the lead source for the opportunity.
  - `opportunityTypeId` string, nullable: The ID (`uuid`) of the opportunity type.
  - `tagIds` string[]: A list of opportunity tag IDs (`uuid`) to associate with the opportunity.
  - `practiceId` string, nullable: The ID (`uuid`) of the practice associated with the opportunity.
  - `businessUnitId` string, nullable: The ID (`uuid`) of the business unit associated with the opportunity.
  - `companyId` string, required: The ID (`uuid`) of the company associated with the opportunity.
  - `projects` object[]: A list of projects to associate with the opportunity.
    - `id` string, required: The ID (`uuid`) of the project.
    - `amount` number, nullable: The amount allocated to this project. The total across all projects must not exceed the opportunity `amount`.
  - `opportunityStageId` string: The ID (`uuid`) of the opportunity stage. Defaults to the active stage with the lowest probability if not provided.
  - `opportunityPipelineId` string, required: The ID (`uuid`) of the opportunity pipeline.

## Response `200`

200

- Opportunity
  - `id` string: The unique identifier for the object.
  - `name` string: The name of the opportunity.
  - `description` string, nullable: A description of the opportunity.
  - `nextSteps` string, nullable: The next steps for the opportunity.
  - `amount` number, nullable: The monetary amount of the opportunity.
  - `probability` number: The probability of the opportunity closing successfully, expressed as a decimal between 0 and 1.
  - `priorityId` 'high' | 'medium' | 'low', nullable: The priority level of the opportunity.
  - `createdAt` string, date-time: The timestamp when the object was created.
  - `openDate` string, date: The date the opportunity was opened. Will be in the form YYYY-MM-DD.
  - `closeDate` string, date, nullable: The expected close date for the opportunity. Will be in the form YYYY-MM-DD.
  - `modifiedAt` string, date-time: The timestamp when the object was last modified.
  - `currency` string: The 3-letter currency code for the opportunity.
  - `cloudFolderUrl` string, nullable: A URL to a cloud folder associated with the opportunity.
  - `weightedAmount` number, nullable: The probability-weighted amount, calculated as `amount` multiplied by `probability`.
  - `owner` object, nullable: The owner of the opportunity.
    - `id` string: The unique identifier for the object.
    - `name` string: The name of the member.
  - `opportunityLeadSource` object, nullable: The lead source for the opportunity.
    - `id` string: The unique identifier for the object.
    - `name` string: The name of the lead source.
  - `opportunityType` object, nullable: The type of the opportunity.
    - `id` string: The unique identifier for the object.
    - `name` string: The name of the opportunity type.
  - `tags` object[]: The tags associated with the opportunity.
    - `id` string: The unique identifier for the object.
    - `name` string: The name of the tag.
  - `practice` object, nullable: The practice associated with the opportunity.
    - `id` string: The unique identifier for the object.
    - `name` string: The name of the practice.
  - `businessUnit` object, nullable: The business unit associated with the opportunity.
    - `id` string: The unique identifier for the object.
    - `name` string: The name of the business unit.
  - `company` object: The company associated with the opportunity.
    - `id` string: The unique identifier for the object.
    - `name` string: The name of the company.
    - `client` object, nullable: The client associated with the company.
      - `id` string: The unique identifier for the object.
      - `key` string: The client key.
      - `name` string: The name of the client.
  - `projects` object[]: The projects associated with the opportunity.
    - `id` string: The unique identifier for the object.
    - `name` string: The name of the project.
    - `amount` number, nullable: The amount allocated to this project from the opportunity.
  - `opportunityStage` object: The current stage of the opportunity.
    - `id` string: The unique identifier for the object.
    - `name` string: The name of the opportunity stage.
    - `statusId` 'open' | 'won' | 'lost': The status of the opportunity stage.
  - `opportunityPipeline` object: The pipeline the opportunity belongs to.
    - `id` string: The unique identifier for the object.
    - `name` string: The name of the pipeline.
  - `timeSpent` integer: Total time spent in minutes across all pipeline activities.
  - `salesforceId` string, nullable: The Salesforce opportunity ID. Will be `null` unless synced via the Salesforce integration.
  - `hubspotId` string, nullable: The HubSpot deal ID. Will be `null` unless synced via the HubSpot integration.

## Other responses

- `400`: 400
- `403`: 403
- `409`: 409

---

[API](https://skmtc.dev/ruddr/apis/ruddr-api.md) · [All operations](https://skmtc.dev/ruddr/apis/ruddr-api/llms.txt) · [OpenAPI document](https://skmtc.dev/ruddr/apis/ruddr-api/revisions/01c3f2a969ba?raw)
