Answered

PIPELINE_ID and STAGE_ID not set to new project

Hi,

I'm using PHP+CURL with API v3.0 to set the new project on Insightly

PIPELINE_ID and STAGE_ID both number int and have live IDs

but some reason it's does not set anymore, but the new project created well

$params = array(
"PROJECT_NAME" => $task_name,
"STATUS"=>'Not Started',
"PROJECT_DETAILS"=>$details,
"STARTED_DATE"=>gmdate("Y-m-d\TH:i:s\Z"),
"COMPLETED_DATE"=>null,
"OPPORTUNITY_ID"=>null,
"PIPELINE_ID"=>1111111,
"STAGE_ID"=>2222222,
"IMAGE_URL"=>null,
"OWNER_USER_ID"=>33333,
"DATE_CREATED_UTC"=>gmdate("Y-m-d\TH:i:s\Z"),
"DATE_UPDATED_UTC"=>gmdate("Y-m-d\TH:i:s\Z"),
"LAST_ACTIVITY_DATE_UTC"=>null,
"NEXT_ACTIVITY_DATE_UTC"=>null,
"RESPONSIBLE_USER_ID"=>444444,
"CUSTOMFIELDS"=> array(
array("FIELD_NAME"=>"Company_Name__c", "FIELD_VALUE"=>"ACME")
)
);

When I tried to PUT a PIPELINE_ID to the new project, I got an error "Field 'PIPELINE_ID' cannot be null"

$params = array(
"PIPELINE_ID"=>1111111,
"PIPELINE_STAGE_CHANGE"=> array(
"STAGE_ID"=> 2222222,
"ACTIVITYSET_ASSIGNMENT"=>array(
"ACTIVITYSET_ID"=> 0,
"START_DATE"=>gmdate("Y-m-d\TH:i:s\Z"),
"END_DATE"=>gmdate("Y-m-d\TH:i:s\Z"),
"ACTIVITY_ASSIGNMENTS"=> array(
array(
"ACTIVITY_ID"=> 0,
"RESPONSIBLE_USER_ID"=> 0,
"ASSIGNED_TEAM_ID"=> 0
)
)
)
)
);


Change API ver to 3.1 does not help


What I'm doing wrong?

Please help!

1

Comments

2 comments
  • Hi James,

    Can you confirm that the pipeline ID is correctly being pulled and added to the PUT request? To get a list of Pipeline Stages and ID's you can use the below endpoint:

     

    https://api.insight.ly/v2.3/Help#!/PipelineStages/GetPipelineStages

     

     

    1
    Comment actions Permalink
  • Hi Alex,
    Thanks for your efforts.

    I can confirm that PIPELINE_ID is the live PIPELINE ID int number.

    The biggest problem is that live PIPELINE_ID is not set during new project created.

    Why is that happens?

    0
    Comment actions Permalink

Please sign in to leave a comment.