Skip to main content
POST

Authorizations

k
string
query
required

Secret key appended by WP as ?k=<secret>. Account-created uses ss_pipedrive_sync_secret. Quote-sync uses ss_pipedrive_quote_sync_secret.

Body

application/json
email
string<email>
required

Primary lookup key for the Pipedrive person record

Example:

"john@example.com"

first_name
string
required
Example:

"John"

stage
enum<string>
required

Pipedrive deal stage to advance to

Available options:
demo_complete,
trial_complete
Example:

"demo_complete"

last_name
string
Example:

"Doe"

phone
string

Included on demo_complete if available from the demo signup form

Example:

"555-1234"

company
string

demo_complete: value of company field from the demo_user post. trial_complete: council name from get_the_title($council_post_id).

Example:

"ACME Corp"

deal_fields
object

demo_complete only: includes wp_website when the demo signup form had a URL. Omitted on trial_complete.

pd_contact_id
integer

trial_complete only: stored Pipedrive person ID from user_meta.pipedrive_contact_id on the council_admin user. Omitted if not yet stored or on demo_complete.

Example:

1234

pd_org_id
integer

trial_complete only: stored Pipedrive org ID from post_meta.pipedrive_company_id on the ss_council post.

Example:

4001

pd_deal_id
integer

trial_complete only: stored Pipedrive deal ID from post_meta.pipedrive_deal_id on the ss_council post.

Example:

5001

Response

200 - application/json

Stage change result

ok
boolean

true on success. WP uses the same guard as account-created: checks ok === true AND pd_contact_id before persisting IDs.

Example:

true

pd_contact_id
integer

Pipedrive person ID resolved during stage change

Example:

1234

pd_org_id
integer

Pipedrive org ID resolved during stage change

Example:

4001

pd_deal_id
integer

Pipedrive deal ID advanced to new stage

Example:

5001

error
string

Human-readable error when ok is false

Example:

"Unauthorized"