Skip to main content
POST
/
api
/
public
/
v1
/
opportunities
/
create
cURL
curl --request POST \
  --url https://api.boxpilote.fr/api/public/v1/opportunities/create \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "email": "<string>",
  "first_name": "<string>",
  "last_name": "<string>",
  "phone": "<string>",
  "name": "<string>",
  "type": "<string>",
  "origin": "<string>",
  "title": "<string>",
  "size": "<string>",
  "priority": "<string>",
  "category": "<array>",
  "referer": "<string>",
  "precision": "<string>",
  "estimated_date": "<string>",
  "external_id": "<string>"
}
'
{
  "success": true,
  "opportunityId": "<string>",
  "createdAt": "<string>"
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Body

application/json

Data required to create an opportunity and optionally a new client

email
string
required

Customer email (required)

first_name
string
required

Customer first name (required)

last_name
string
required

Customer last name (required)

phone
string
required

Customer phone number (required)

name
string

Company name

type
string

Client type (Professionnel, Particulier, Association). Default: Professionnel

origin
string

Lead origin. Default: Site Web

title
string

Short title or description of the opportunity. Default: Demande de démo

size
string

Size in m²

priority
string

Opportunity priority (Faible, Moyen, Important). Default: Important

category
array

Category tags

referer
string

Referrer source

precision
string

Additional precision/details

estimated_date
string

Estimated date for the opportunity

external_id
string

External ID of the customer

Response

Opportunity successfully created

success
boolean
opportunityId
string
createdAt
string

Creation timestamp