Patch proposal draft fields or proposal census cells
curl --request PATCH \
--url https://api.cx.stax.ai/deals/proposals/{proposal} \
--header 'Content-Type: application/json' \
--header 'x-api-key: <api-key>' \
--data '
{
"acceptance_workflow": {
"deal_action": "<string>",
"deal_stage": "<string>",
"deal_stage_name": "<string>",
"effective_date": "<string>",
"form_template": "<string>",
"kind": "<string>",
"mark_deal_won": true,
"plan_name": "<string>",
"plan_type": "<string>",
"project_template": "<string>"
},
"assignee": "<string>",
"census": {
"action": "<string>",
"client_id": "<string>",
"employee": [
123
],
"employees": [
{}
],
"example": true,
"field": "<string>",
"name": "<string>",
"plan_compensation": {},
"test_compensation": {},
"value": "<unknown>"
},
"completed": true,
"data": [
123
],
"expected_revision": 123,
"illustration_year": 123,
"layout": "<string>",
"name": "<string>",
"plan_effective_date": "<string>",
"plan_type": "<string>",
"public_contact": "<string>",
"section": "<string>",
"status": "<string>"
}
'import requests
url = "https://api.cx.stax.ai/deals/proposals/{proposal}"
payload = {
"acceptance_workflow": {
"deal_action": "<string>",
"deal_stage": "<string>",
"deal_stage_name": "<string>",
"effective_date": "<string>",
"form_template": "<string>",
"kind": "<string>",
"mark_deal_won": True,
"plan_name": "<string>",
"plan_type": "<string>",
"project_template": "<string>"
},
"assignee": "<string>",
"census": {
"action": "<string>",
"client_id": "<string>",
"employee": [123],
"employees": [{}],
"example": True,
"field": "<string>",
"name": "<string>",
"plan_compensation": {},
"test_compensation": {},
"value": "<unknown>"
},
"completed": True,
"data": [123],
"expected_revision": 123,
"illustration_year": 123,
"layout": "<string>",
"name": "<string>",
"plan_effective_date": "<string>",
"plan_type": "<string>",
"public_contact": "<string>",
"section": "<string>",
"status": "<string>"
}
headers = {
"x-api-key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {'x-api-key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
acceptance_workflow: {
deal_action: '<string>',
deal_stage: '<string>',
deal_stage_name: '<string>',
effective_date: '<string>',
form_template: '<string>',
kind: '<string>',
mark_deal_won: true,
plan_name: '<string>',
plan_type: '<string>',
project_template: '<string>'
},
assignee: '<string>',
census: {
action: '<string>',
client_id: '<string>',
employee: [123],
employees: [{}],
example: true,
field: '<string>',
name: '<string>',
plan_compensation: {},
test_compensation: {},
value: '<unknown>'
},
completed: true,
data: [123],
expected_revision: 123,
illustration_year: 123,
layout: '<string>',
name: '<string>',
plan_effective_date: '<string>',
plan_type: '<string>',
public_contact: '<string>',
section: '<string>',
status: '<string>'
})
};
fetch('https://api.cx.stax.ai/deals/proposals/{proposal}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.cx.stax.ai/deals/proposals/{proposal}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PATCH",
CURLOPT_POSTFIELDS => json_encode([
'acceptance_workflow' => [
'deal_action' => '<string>',
'deal_stage' => '<string>',
'deal_stage_name' => '<string>',
'effective_date' => '<string>',
'form_template' => '<string>',
'kind' => '<string>',
'mark_deal_won' => true,
'plan_name' => '<string>',
'plan_type' => '<string>',
'project_template' => '<string>'
],
'assignee' => '<string>',
'census' => [
'action' => '<string>',
'client_id' => '<string>',
'employee' => [
123
],
'employees' => [
[
]
],
'example' => true,
'field' => '<string>',
'name' => '<string>',
'plan_compensation' => [
],
'test_compensation' => [
],
'value' => '<unknown>'
],
'completed' => true,
'data' => [
123
],
'expected_revision' => 123,
'illustration_year' => 123,
'layout' => '<string>',
'name' => '<string>',
'plan_effective_date' => '<string>',
'plan_type' => '<string>',
'public_contact' => '<string>',
'section' => '<string>',
'status' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"x-api-key: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.cx.stax.ai/deals/proposals/{proposal}"
payload := strings.NewReader("{\n \"acceptance_workflow\": {\n \"deal_action\": \"<string>\",\n \"deal_stage\": \"<string>\",\n \"deal_stage_name\": \"<string>\",\n \"effective_date\": \"<string>\",\n \"form_template\": \"<string>\",\n \"kind\": \"<string>\",\n \"mark_deal_won\": true,\n \"plan_name\": \"<string>\",\n \"plan_type\": \"<string>\",\n \"project_template\": \"<string>\"\n },\n \"assignee\": \"<string>\",\n \"census\": {\n \"action\": \"<string>\",\n \"client_id\": \"<string>\",\n \"employee\": [\n 123\n ],\n \"employees\": [\n {}\n ],\n \"example\": true,\n \"field\": \"<string>\",\n \"name\": \"<string>\",\n \"plan_compensation\": {},\n \"test_compensation\": {},\n \"value\": \"<unknown>\"\n },\n \"completed\": true,\n \"data\": [\n 123\n ],\n \"expected_revision\": 123,\n \"illustration_year\": 123,\n \"layout\": \"<string>\",\n \"name\": \"<string>\",\n \"plan_effective_date\": \"<string>\",\n \"plan_type\": \"<string>\",\n \"public_contact\": \"<string>\",\n \"section\": \"<string>\",\n \"status\": \"<string>\"\n}")
req, _ := http.NewRequest("PATCH", url, payload)
req.Header.Add("x-api-key", "<api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.patch("https://api.cx.stax.ai/deals/proposals/{proposal}")
.header("x-api-key", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"acceptance_workflow\": {\n \"deal_action\": \"<string>\",\n \"deal_stage\": \"<string>\",\n \"deal_stage_name\": \"<string>\",\n \"effective_date\": \"<string>\",\n \"form_template\": \"<string>\",\n \"kind\": \"<string>\",\n \"mark_deal_won\": true,\n \"plan_name\": \"<string>\",\n \"plan_type\": \"<string>\",\n \"project_template\": \"<string>\"\n },\n \"assignee\": \"<string>\",\n \"census\": {\n \"action\": \"<string>\",\n \"client_id\": \"<string>\",\n \"employee\": [\n 123\n ],\n \"employees\": [\n {}\n ],\n \"example\": true,\n \"field\": \"<string>\",\n \"name\": \"<string>\",\n \"plan_compensation\": {},\n \"test_compensation\": {},\n \"value\": \"<unknown>\"\n },\n \"completed\": true,\n \"data\": [\n 123\n ],\n \"expected_revision\": 123,\n \"illustration_year\": 123,\n \"layout\": \"<string>\",\n \"name\": \"<string>\",\n \"plan_effective_date\": \"<string>\",\n \"plan_type\": \"<string>\",\n \"public_contact\": \"<string>\",\n \"section\": \"<string>\",\n \"status\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.cx.stax.ai/deals/proposals/{proposal}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Patch.new(url)
request["x-api-key"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"acceptance_workflow\": {\n \"deal_action\": \"<string>\",\n \"deal_stage\": \"<string>\",\n \"deal_stage_name\": \"<string>\",\n \"effective_date\": \"<string>\",\n \"form_template\": \"<string>\",\n \"kind\": \"<string>\",\n \"mark_deal_won\": true,\n \"plan_name\": \"<string>\",\n \"plan_type\": \"<string>\",\n \"project_template\": \"<string>\"\n },\n \"assignee\": \"<string>\",\n \"census\": {\n \"action\": \"<string>\",\n \"client_id\": \"<string>\",\n \"employee\": [\n 123\n ],\n \"employees\": [\n {}\n ],\n \"example\": true,\n \"field\": \"<string>\",\n \"name\": \"<string>\",\n \"plan_compensation\": {},\n \"test_compensation\": {},\n \"value\": \"<unknown>\"\n },\n \"completed\": true,\n \"data\": [\n 123\n ],\n \"expected_revision\": 123,\n \"illustration_year\": 123,\n \"layout\": \"<string>\",\n \"name\": \"<string>\",\n \"plan_effective_date\": \"<string>\",\n \"plan_type\": \"<string>\",\n \"public_contact\": \"<string>\",\n \"section\": \"<string>\",\n \"status\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{}deals
Patch proposal draft fields or proposal census cells
Applies an allowlisted CAS patch. Deal stages are never mutated by this endpoint.
PATCH
/
deals
/
proposals
/
{proposal}
Patch proposal draft fields or proposal census cells
curl --request PATCH \
--url https://api.cx.stax.ai/deals/proposals/{proposal} \
--header 'Content-Type: application/json' \
--header 'x-api-key: <api-key>' \
--data '
{
"acceptance_workflow": {
"deal_action": "<string>",
"deal_stage": "<string>",
"deal_stage_name": "<string>",
"effective_date": "<string>",
"form_template": "<string>",
"kind": "<string>",
"mark_deal_won": true,
"plan_name": "<string>",
"plan_type": "<string>",
"project_template": "<string>"
},
"assignee": "<string>",
"census": {
"action": "<string>",
"client_id": "<string>",
"employee": [
123
],
"employees": [
{}
],
"example": true,
"field": "<string>",
"name": "<string>",
"plan_compensation": {},
"test_compensation": {},
"value": "<unknown>"
},
"completed": true,
"data": [
123
],
"expected_revision": 123,
"illustration_year": 123,
"layout": "<string>",
"name": "<string>",
"plan_effective_date": "<string>",
"plan_type": "<string>",
"public_contact": "<string>",
"section": "<string>",
"status": "<string>"
}
'import requests
url = "https://api.cx.stax.ai/deals/proposals/{proposal}"
payload = {
"acceptance_workflow": {
"deal_action": "<string>",
"deal_stage": "<string>",
"deal_stage_name": "<string>",
"effective_date": "<string>",
"form_template": "<string>",
"kind": "<string>",
"mark_deal_won": True,
"plan_name": "<string>",
"plan_type": "<string>",
"project_template": "<string>"
},
"assignee": "<string>",
"census": {
"action": "<string>",
"client_id": "<string>",
"employee": [123],
"employees": [{}],
"example": True,
"field": "<string>",
"name": "<string>",
"plan_compensation": {},
"test_compensation": {},
"value": "<unknown>"
},
"completed": True,
"data": [123],
"expected_revision": 123,
"illustration_year": 123,
"layout": "<string>",
"name": "<string>",
"plan_effective_date": "<string>",
"plan_type": "<string>",
"public_contact": "<string>",
"section": "<string>",
"status": "<string>"
}
headers = {
"x-api-key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {'x-api-key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
acceptance_workflow: {
deal_action: '<string>',
deal_stage: '<string>',
deal_stage_name: '<string>',
effective_date: '<string>',
form_template: '<string>',
kind: '<string>',
mark_deal_won: true,
plan_name: '<string>',
plan_type: '<string>',
project_template: '<string>'
},
assignee: '<string>',
census: {
action: '<string>',
client_id: '<string>',
employee: [123],
employees: [{}],
example: true,
field: '<string>',
name: '<string>',
plan_compensation: {},
test_compensation: {},
value: '<unknown>'
},
completed: true,
data: [123],
expected_revision: 123,
illustration_year: 123,
layout: '<string>',
name: '<string>',
plan_effective_date: '<string>',
plan_type: '<string>',
public_contact: '<string>',
section: '<string>',
status: '<string>'
})
};
fetch('https://api.cx.stax.ai/deals/proposals/{proposal}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.cx.stax.ai/deals/proposals/{proposal}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PATCH",
CURLOPT_POSTFIELDS => json_encode([
'acceptance_workflow' => [
'deal_action' => '<string>',
'deal_stage' => '<string>',
'deal_stage_name' => '<string>',
'effective_date' => '<string>',
'form_template' => '<string>',
'kind' => '<string>',
'mark_deal_won' => true,
'plan_name' => '<string>',
'plan_type' => '<string>',
'project_template' => '<string>'
],
'assignee' => '<string>',
'census' => [
'action' => '<string>',
'client_id' => '<string>',
'employee' => [
123
],
'employees' => [
[
]
],
'example' => true,
'field' => '<string>',
'name' => '<string>',
'plan_compensation' => [
],
'test_compensation' => [
],
'value' => '<unknown>'
],
'completed' => true,
'data' => [
123
],
'expected_revision' => 123,
'illustration_year' => 123,
'layout' => '<string>',
'name' => '<string>',
'plan_effective_date' => '<string>',
'plan_type' => '<string>',
'public_contact' => '<string>',
'section' => '<string>',
'status' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"x-api-key: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.cx.stax.ai/deals/proposals/{proposal}"
payload := strings.NewReader("{\n \"acceptance_workflow\": {\n \"deal_action\": \"<string>\",\n \"deal_stage\": \"<string>\",\n \"deal_stage_name\": \"<string>\",\n \"effective_date\": \"<string>\",\n \"form_template\": \"<string>\",\n \"kind\": \"<string>\",\n \"mark_deal_won\": true,\n \"plan_name\": \"<string>\",\n \"plan_type\": \"<string>\",\n \"project_template\": \"<string>\"\n },\n \"assignee\": \"<string>\",\n \"census\": {\n \"action\": \"<string>\",\n \"client_id\": \"<string>\",\n \"employee\": [\n 123\n ],\n \"employees\": [\n {}\n ],\n \"example\": true,\n \"field\": \"<string>\",\n \"name\": \"<string>\",\n \"plan_compensation\": {},\n \"test_compensation\": {},\n \"value\": \"<unknown>\"\n },\n \"completed\": true,\n \"data\": [\n 123\n ],\n \"expected_revision\": 123,\n \"illustration_year\": 123,\n \"layout\": \"<string>\",\n \"name\": \"<string>\",\n \"plan_effective_date\": \"<string>\",\n \"plan_type\": \"<string>\",\n \"public_contact\": \"<string>\",\n \"section\": \"<string>\",\n \"status\": \"<string>\"\n}")
req, _ := http.NewRequest("PATCH", url, payload)
req.Header.Add("x-api-key", "<api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.patch("https://api.cx.stax.ai/deals/proposals/{proposal}")
.header("x-api-key", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"acceptance_workflow\": {\n \"deal_action\": \"<string>\",\n \"deal_stage\": \"<string>\",\n \"deal_stage_name\": \"<string>\",\n \"effective_date\": \"<string>\",\n \"form_template\": \"<string>\",\n \"kind\": \"<string>\",\n \"mark_deal_won\": true,\n \"plan_name\": \"<string>\",\n \"plan_type\": \"<string>\",\n \"project_template\": \"<string>\"\n },\n \"assignee\": \"<string>\",\n \"census\": {\n \"action\": \"<string>\",\n \"client_id\": \"<string>\",\n \"employee\": [\n 123\n ],\n \"employees\": [\n {}\n ],\n \"example\": true,\n \"field\": \"<string>\",\n \"name\": \"<string>\",\n \"plan_compensation\": {},\n \"test_compensation\": {},\n \"value\": \"<unknown>\"\n },\n \"completed\": true,\n \"data\": [\n 123\n ],\n \"expected_revision\": 123,\n \"illustration_year\": 123,\n \"layout\": \"<string>\",\n \"name\": \"<string>\",\n \"plan_effective_date\": \"<string>\",\n \"plan_type\": \"<string>\",\n \"public_contact\": \"<string>\",\n \"section\": \"<string>\",\n \"status\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.cx.stax.ai/deals/proposals/{proposal}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Patch.new(url)
request["x-api-key"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"acceptance_workflow\": {\n \"deal_action\": \"<string>\",\n \"deal_stage\": \"<string>\",\n \"deal_stage_name\": \"<string>\",\n \"effective_date\": \"<string>\",\n \"form_template\": \"<string>\",\n \"kind\": \"<string>\",\n \"mark_deal_won\": true,\n \"plan_name\": \"<string>\",\n \"plan_type\": \"<string>\",\n \"project_template\": \"<string>\"\n },\n \"assignee\": \"<string>\",\n \"census\": {\n \"action\": \"<string>\",\n \"client_id\": \"<string>\",\n \"employee\": [\n 123\n ],\n \"employees\": [\n {}\n ],\n \"example\": true,\n \"field\": \"<string>\",\n \"name\": \"<string>\",\n \"plan_compensation\": {},\n \"test_compensation\": {},\n \"value\": \"<unknown>\"\n },\n \"completed\": true,\n \"data\": [\n 123\n ],\n \"expected_revision\": 123,\n \"illustration_year\": 123,\n \"layout\": \"<string>\",\n \"name\": \"<string>\",\n \"plan_effective_date\": \"<string>\",\n \"plan_type\": \"<string>\",\n \"public_contact\": \"<string>\",\n \"section\": \"<string>\",\n \"status\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{}Authorizations
Body
application/json
Expected revision and patch
Response
200 - application/json
OK
The response is of type object.