Create an opportunity
POST/v1/opportunities
Creates a new opportunity record. The $name and $stage fields and the $account relationship are required.
After creation, Lightfield automatically generates an opportunity summary in the background. The $opportunityStatus field is read-only and cannot be set via the API. The $task and $note relationships are also read-only — manage them via the $opportunity relationship on the task, or the $account/$opportunity note relationships instead.
Supports idempotency via the Idempotency-Key header.
Required scope: opportunities:create
Rate limit category: Write
Body ParametersJSON
Returns
Create an opportunity
curl https://api.lightfield.app/v1/opportunities \
-H 'Content-Type: application/json' \
-H 'Lightfield-Version: 2026-03-01' \
-H "Authorization: Bearer $API_KEY" \
-d '{
"fields": {
"$name": "$name",
"$stage": "$stage"
},
"relationships": {
"$account": "string"
}
}'{
"id": "id",
"createdAt": "createdAt",
"fields": {
"foo": {
"value": "string",
"valueType": "ADDRESS"
}
},
"httpLink": "httpLink",
"relationships": {
"foo": {
"cardinality": "cardinality",
"objectType": "objectType",
"values": [
"string"
]
}
}
}Returns Examples
{
"id": "id",
"createdAt": "createdAt",
"fields": {
"foo": {
"value": "string",
"valueType": "ADDRESS"
}
},
"httpLink": "httpLink",
"relationships": {
"foo": {
"cardinality": "cardinality",
"objectType": "objectType",
"values": [
"string"
]
}
}
}