Skip to main content
POST
/
v1
/
deals
Create deal
curl --request POST \
  --url https://api.stardex.ai/v1/deals \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "name": "<string>",
  "client_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "client_linkedin_url": "<string>",
  "amount": 123,
  "currency_code": "<string>",
  "compensation": 1,
  "compensation_currency_code": "<string>",
  "pricing_rate": 50,
  "win_probability": 50,
  "deal_status_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "description": "<string>",
  "closed_date": "<string>",
  "job_ids": [
    "3c90c3cc-0d44-4b50-8888-8dd25736052a"
  ],
  "referred_by": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "owner_ids": [
    "3c90c3cc-0d44-4b50-8888-8dd25736052a"
  ],
  "custom_fields": [
    {
      "attribute_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
      "value": "<string>",
      "add_values": [
        "<string>"
      ],
      "remove_values": [
        "<string>"
      ],
      "add_team_member_ids": [
        "3c90c3cc-0d44-4b50-8888-8dd25736052a"
      ],
      "remove_team_member_ids": [
        "3c90c3cc-0d44-4b50-8888-8dd25736052a"
      ],
      "clear_all": true
    }
  ]
}
'
{
  "success": true,
  "data": {
    "id": "aaa11111-bbbb-cccc-dddd-eeeeeeee1111",
    "name": "Acme Corp Staffing Agreement",
    "amount": 150000,
    "currency_code": "USD",
    "compensation": 750000,
    "compensation_currency_code": "USD",
    "pricing_rate": 20,
    "win_probability": 75,
    "deal_status_id": "ccc33333-dddd-eeee-ffff-000000003333",
    "client_id": "bbb22222-cccc-dddd-eeee-ffffffff2222",
    "job_ids": [
      "eee55555-ffff-0000-1111-222222225555"
    ],
    "created_at": "2024-01-15T10:00:00Z"
  }
}

Documentation Index

Fetch the complete documentation index at: https://docs.stardex.com/llms.txt

Use this file to discover all available pages before exploring further.

Authorizations

Authorization
string
header
required

Authenticate with a Bearer token: API key, OAuth token, or session token.

Body

application/json
name
string
required

Deal name (required).

Minimum string length: 1
client_id
string<uuid>

Client company UUID.

client_linkedin_url
string<uri>

Client company LinkedIn URL. Used to look up or create the client company if client_id is not provided.

amount
number

Deal amount — the fee the firm invoices the client.

currency_code
string

ISO 4217 currency code (e.g. USD, EUR, GBP). Defaults to the organization setting or USD.

Required string length: 3
compensation
number

Candidate's expected total annual compensation.

Required range: x >= 0
compensation_currency_code
string

ISO 4217 currency code for compensation. Defaults to currency_code (or the organization default / USD).

Required string length: 3
pricing_rate
number

Recruitment fee percentage (0–100).

Required range: 0 <= x <= 100
win_probability
number

Win probability (0–100).

Required range: 0 <= x <= 100
deal_status_id
string<uuid>

Deal status UUID. Use List deal statuses endpoint to get the UUID.

description
string

Description.

closed_date
string

ISO 8601 expected or actual close date.

job_ids
string<uuid>[]

Job UUIDs to link to this deal. Creates entries in the deal_jobs table.

referred_by
string<uuid>

Person UUID of the referrer.

owner_ids
string<uuid>[]

Team member UUIDs to assign as deal owners. If omitted, the caller is auto-assigned when authenticated as a team member.

custom_fields
object[]

Custom field values to set on creation.

Response

Deal created

success
enum<boolean>
required
Available options:
true
data
object
required