Skip to main content
POST
/
opportunities
Create opportunity
curl --request POST \
  --url https://api.gospott.com/opportunities \
  --header 'Content-Type: application/json' \
  --header 'x-api-key: <api-key>' \
  --data '
{
  "companyId": "<string>",
  "name": "<string>",
  "description": "<string>",
  "stageId": "<string>",
  "closeDate": {
    "target": "2023-11-07T05:31:56Z"
  },
  "ownerId": "<string>",
  "clientTeam": [
    {
      "id": "<string>"
    }
  ]
}
'
{
  "id": "<string>"
}

Authorizations

x-api-key
string
header
required

API key for authentication. Get your API key from Settings → API Keys in your Spott dashboard.

Body

application/json
companyId
string
required

The ID of the company this opportunity belongs to

name
string
required

The name of the opportunity

description
string | null
required

Detailed description of the opportunity

stageId
string
required

The pipeline stage ID to assign to this opportunity

closeDate
object
required

The target close date for this opportunity

ownerId
string

The user ID of the opportunity owner

clientTeam
object[]

Client contacts to associate with this opportunity

Response

Opportunity created successfully. Returns the opportunity ID.

id
string
required