using RestSharp;
var options = new RestClientOptions("http://localhost:65002/api/v1/Agents/Quote/SaveQuoteEntity");
var client = new RestClient(options);
var request = new RestRequest("");
request.AddHeader("Authorization", "Bearer <token>");
request.AddJsonBody("{\n \"QuoteEntity\": {\n \"QuoteId\": 123,\n \"SaleId\": 123,\n \"QuoteConnectionId\": 123,\n \"ERPQuoteKey\": \"<string>\",\n \"ERPOrderKey\": \"<string>\",\n \"ActiveQuoteVersionId\": 123,\n \"AcceptedQuoteAlternativeId\": 123,\n \"UseValuesFromQuote\": 123,\n \"DocumentId\": 123,\n \"PoNumber\": \"<string>\",\n \"OrderComment\": \"<string>\",\n \"PreferredEmailCulture\": \"<string>\",\n \"QuoteVersions\": [\n {\n \"QuoteVersionId\": 123,\n \"ERPQuoteVersionKey\": \"<string>\",\n \"QuoteId\": 123,\n \"Description\": \"<string>\",\n \"Number\": \"<string>\",\n \"Reason\": \"<string>\",\n \"LikelyQuoteAlternativeId\": 123,\n \"SentDate\": \"2023-11-07T05:31:56Z\",\n \"FollowupId\": 123,\n \"ExpirationDate\": \"2023-11-07T05:31:56Z\",\n \"DeliveryCountryId\": 123,\n \"HasOwnDeliveryAddress\": true,\n \"InvoiceCountryId\": 123,\n \"HasOwnInvoiceAddress\": true,\n \"ERPPaymentTermsKey\": \"<string>\",\n \"ERPPaymentTypeKey\": \"<string>\",\n \"ERPDeliveryTermsKey\": \"<string>\",\n \"ERPDeliveryTypeKey\": \"<string>\",\n \"Rank\": 123,\n \"ApprovedBy\": 123,\n \"ApprovedText\": \"<string>\",\n \"ApprovedRegisteredBy\": 123,\n \"ApprovedRegisteredDate\": \"2023-11-07T05:31:56Z\",\n \"ExtraField1\": \"<string>\",\n \"ExtraField2\": \"<string>\",\n \"ExtraField3\": \"<string>\",\n \"ExtraField4\": \"<string>\",\n \"ExtraField5\": \"<string>\",\n \"LastRecalculated\": \"2023-11-07T05:31:56Z\",\n \"Updated\": \"2023-11-07T05:31:56Z\",\n \"UpdatedAssociateId\": 123,\n \"Registered\": \"2023-11-07T05:31:56Z\",\n \"RegisteredAssociateId\": 123,\n \"RequestAssociateId\": 123,\n \"RequestComment\": \"<string>\",\n \"QuoteAlternatives\": [\n {\n \"QuoteAlternativeId\": 123,\n \"ERPQuoteAlternativeKey\": \"<string>\",\n \"QuoteVersionId\": 123,\n \"Name\": \"<string>\",\n \"Description\": \"<string>\",\n \"Reason\": \"<string>\",\n \"ERPDiscountPercent\": 123,\n \"ERPDiscountAmount\": 123,\n \"DiscountPercent\": 123,\n \"DiscountAmount\": 123,\n \"VATInfo\": \"<string>\",\n \"VAT\": 123,\n \"EarningPercent\": 123,\n \"EarningAmount\": 123,\n \"SubTotal\": 123,\n \"TotalPrice\": 123,\n \"ExtraField1\": \"<string>\",\n \"ExtraField2\": \"<string>\",\n \"ExtraField3\": \"<string>\",\n \"ExtraField4\": \"<string>\",\n \"ExtraField5\": \"<string>\",\n \"TableRight\": {\n \"Mask\": \"<string>\",\n \"Reason\": \"<string>\"\n },\n \"FieldProperties\": {}\n }\n ],\n \"TableRight\": {\n \"Mask\": \"<string>\",\n \"Reason\": \"<string>\"\n },\n \"FieldProperties\": {}\n }\n ],\n \"TableRight\": {\n \"Mask\": \"<string>\",\n \"Reason\": \"<string>\"\n },\n \"FieldProperties\": {}\n }\n}", false);
var response = await client.PostAsync(request);
Console.WriteLine("{0}", response.Content);const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
QuoteEntity: {
QuoteId: 123,
SaleId: 123,
QuoteConnectionId: 123,
ERPQuoteKey: '<string>',
ERPOrderKey: '<string>',
ActiveQuoteVersionId: 123,
AcceptedQuoteAlternativeId: 123,
UseValuesFromQuote: 123,
DocumentId: 123,
PoNumber: '<string>',
OrderComment: '<string>',
PreferredEmailCulture: '<string>',
QuoteVersions: [
{
QuoteVersionId: 123,
ERPQuoteVersionKey: '<string>',
QuoteId: 123,
Description: '<string>',
Number: '<string>',
Reason: '<string>',
LikelyQuoteAlternativeId: 123,
SentDate: '2023-11-07T05:31:56Z',
FollowupId: 123,
ExpirationDate: '2023-11-07T05:31:56Z',
DeliveryCountryId: 123,
HasOwnDeliveryAddress: true,
InvoiceCountryId: 123,
HasOwnInvoiceAddress: true,
ERPPaymentTermsKey: '<string>',
ERPPaymentTypeKey: '<string>',
ERPDeliveryTermsKey: '<string>',
ERPDeliveryTypeKey: '<string>',
Rank: 123,
ApprovedBy: 123,
ApprovedText: '<string>',
ApprovedRegisteredBy: 123,
ApprovedRegisteredDate: '2023-11-07T05:31:56Z',
ExtraField1: '<string>',
ExtraField2: '<string>',
ExtraField3: '<string>',
ExtraField4: '<string>',
ExtraField5: '<string>',
LastRecalculated: '2023-11-07T05:31:56Z',
Updated: '2023-11-07T05:31:56Z',
UpdatedAssociateId: 123,
Registered: '2023-11-07T05:31:56Z',
RegisteredAssociateId: 123,
RequestAssociateId: 123,
RequestComment: '<string>',
QuoteAlternatives: [
{
QuoteAlternativeId: 123,
ERPQuoteAlternativeKey: '<string>',
QuoteVersionId: 123,
Name: '<string>',
Description: '<string>',
Reason: '<string>',
ERPDiscountPercent: 123,
ERPDiscountAmount: 123,
DiscountPercent: 123,
DiscountAmount: 123,
VATInfo: '<string>',
VAT: 123,
EarningPercent: 123,
EarningAmount: 123,
SubTotal: 123,
TotalPrice: 123,
ExtraField1: '<string>',
ExtraField2: '<string>',
ExtraField3: '<string>',
ExtraField4: '<string>',
ExtraField5: '<string>',
TableRight: {Mask: '<string>', Reason: '<string>'},
FieldProperties: {}
}
],
TableRight: {Mask: '<string>', Reason: '<string>'},
FieldProperties: {}
}
],
TableRight: {Mask: '<string>', Reason: '<string>'},
FieldProperties: {}
}
})
};
fetch('http://localhost:65002/api/v1/Agents/Quote/SaveQuoteEntity', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_PORT => "65002",
CURLOPT_URL => "http://localhost:65002/api/v1/Agents/Quote/SaveQuoteEntity",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'QuoteEntity' => [
'QuoteId' => 123,
'SaleId' => 123,
'QuoteConnectionId' => 123,
'ERPQuoteKey' => '<string>',
'ERPOrderKey' => '<string>',
'ActiveQuoteVersionId' => 123,
'AcceptedQuoteAlternativeId' => 123,
'UseValuesFromQuote' => 123,
'DocumentId' => 123,
'PoNumber' => '<string>',
'OrderComment' => '<string>',
'PreferredEmailCulture' => '<string>',
'QuoteVersions' => [
[
'QuoteVersionId' => 123,
'ERPQuoteVersionKey' => '<string>',
'QuoteId' => 123,
'Description' => '<string>',
'Number' => '<string>',
'Reason' => '<string>',
'LikelyQuoteAlternativeId' => 123,
'SentDate' => '2023-11-07T05:31:56Z',
'FollowupId' => 123,
'ExpirationDate' => '2023-11-07T05:31:56Z',
'DeliveryCountryId' => 123,
'HasOwnDeliveryAddress' => true,
'InvoiceCountryId' => 123,
'HasOwnInvoiceAddress' => true,
'ERPPaymentTermsKey' => '<string>',
'ERPPaymentTypeKey' => '<string>',
'ERPDeliveryTermsKey' => '<string>',
'ERPDeliveryTypeKey' => '<string>',
'Rank' => 123,
'ApprovedBy' => 123,
'ApprovedText' => '<string>',
'ApprovedRegisteredBy' => 123,
'ApprovedRegisteredDate' => '2023-11-07T05:31:56Z',
'ExtraField1' => '<string>',
'ExtraField2' => '<string>',
'ExtraField3' => '<string>',
'ExtraField4' => '<string>',
'ExtraField5' => '<string>',
'LastRecalculated' => '2023-11-07T05:31:56Z',
'Updated' => '2023-11-07T05:31:56Z',
'UpdatedAssociateId' => 123,
'Registered' => '2023-11-07T05:31:56Z',
'RegisteredAssociateId' => 123,
'RequestAssociateId' => 123,
'RequestComment' => '<string>',
'QuoteAlternatives' => [
[
'QuoteAlternativeId' => 123,
'ERPQuoteAlternativeKey' => '<string>',
'QuoteVersionId' => 123,
'Name' => '<string>',
'Description' => '<string>',
'Reason' => '<string>',
'ERPDiscountPercent' => 123,
'ERPDiscountAmount' => 123,
'DiscountPercent' => 123,
'DiscountAmount' => 123,
'VATInfo' => '<string>',
'VAT' => 123,
'EarningPercent' => 123,
'EarningAmount' => 123,
'SubTotal' => 123,
'TotalPrice' => 123,
'ExtraField1' => '<string>',
'ExtraField2' => '<string>',
'ExtraField3' => '<string>',
'ExtraField4' => '<string>',
'ExtraField5' => '<string>',
'TableRight' => [
'Mask' => '<string>',
'Reason' => '<string>'
],
'FieldProperties' => [
]
]
],
'TableRight' => [
'Mask' => '<string>',
'Reason' => '<string>'
],
'FieldProperties' => [
]
]
],
'TableRight' => [
'Mask' => '<string>',
'Reason' => '<string>'
],
'FieldProperties' => [
]
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}import requests
url = "http://localhost:65002/api/v1/Agents/Quote/SaveQuoteEntity"
payload = { "QuoteEntity": {
"QuoteId": 123,
"SaleId": 123,
"QuoteConnectionId": 123,
"ERPQuoteKey": "<string>",
"ERPOrderKey": "<string>",
"ActiveQuoteVersionId": 123,
"AcceptedQuoteAlternativeId": 123,
"UseValuesFromQuote": 123,
"DocumentId": 123,
"PoNumber": "<string>",
"OrderComment": "<string>",
"PreferredEmailCulture": "<string>",
"QuoteVersions": [
{
"QuoteVersionId": 123,
"ERPQuoteVersionKey": "<string>",
"QuoteId": 123,
"Description": "<string>",
"Number": "<string>",
"Reason": "<string>",
"LikelyQuoteAlternativeId": 123,
"SentDate": "2023-11-07T05:31:56Z",
"FollowupId": 123,
"ExpirationDate": "2023-11-07T05:31:56Z",
"DeliveryCountryId": 123,
"HasOwnDeliveryAddress": True,
"InvoiceCountryId": 123,
"HasOwnInvoiceAddress": True,
"ERPPaymentTermsKey": "<string>",
"ERPPaymentTypeKey": "<string>",
"ERPDeliveryTermsKey": "<string>",
"ERPDeliveryTypeKey": "<string>",
"Rank": 123,
"ApprovedBy": 123,
"ApprovedText": "<string>",
"ApprovedRegisteredBy": 123,
"ApprovedRegisteredDate": "2023-11-07T05:31:56Z",
"ExtraField1": "<string>",
"ExtraField2": "<string>",
"ExtraField3": "<string>",
"ExtraField4": "<string>",
"ExtraField5": "<string>",
"LastRecalculated": "2023-11-07T05:31:56Z",
"Updated": "2023-11-07T05:31:56Z",
"UpdatedAssociateId": 123,
"Registered": "2023-11-07T05:31:56Z",
"RegisteredAssociateId": 123,
"RequestAssociateId": 123,
"RequestComment": "<string>",
"QuoteAlternatives": [
{
"QuoteAlternativeId": 123,
"ERPQuoteAlternativeKey": "<string>",
"QuoteVersionId": 123,
"Name": "<string>",
"Description": "<string>",
"Reason": "<string>",
"ERPDiscountPercent": 123,
"ERPDiscountAmount": 123,
"DiscountPercent": 123,
"DiscountAmount": 123,
"VATInfo": "<string>",
"VAT": 123,
"EarningPercent": 123,
"EarningAmount": 123,
"SubTotal": 123,
"TotalPrice": 123,
"ExtraField1": "<string>",
"ExtraField2": "<string>",
"ExtraField3": "<string>",
"ExtraField4": "<string>",
"ExtraField5": "<string>",
"TableRight": {
"Mask": "<string>",
"Reason": "<string>"
},
"FieldProperties": {}
}
],
"TableRight": {
"Mask": "<string>",
"Reason": "<string>"
},
"FieldProperties": {}
}
],
"TableRight": {
"Mask": "<string>",
"Reason": "<string>"
},
"FieldProperties": {}
} }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
QuoteEntity: {
QuoteId: 123,
SaleId: 123,
QuoteConnectionId: 123,
ERPQuoteKey: '<string>',
ERPOrderKey: '<string>',
ActiveQuoteVersionId: 123,
AcceptedQuoteAlternativeId: 123,
UseValuesFromQuote: 123,
DocumentId: 123,
PoNumber: '<string>',
OrderComment: '<string>',
PreferredEmailCulture: '<string>',
QuoteVersions: [
{
QuoteVersionId: 123,
ERPQuoteVersionKey: '<string>',
QuoteId: 123,
Description: '<string>',
Number: '<string>',
Reason: '<string>',
LikelyQuoteAlternativeId: 123,
SentDate: '2023-11-07T05:31:56Z',
FollowupId: 123,
ExpirationDate: '2023-11-07T05:31:56Z',
DeliveryCountryId: 123,
HasOwnDeliveryAddress: true,
InvoiceCountryId: 123,
HasOwnInvoiceAddress: true,
ERPPaymentTermsKey: '<string>',
ERPPaymentTypeKey: '<string>',
ERPDeliveryTermsKey: '<string>',
ERPDeliveryTypeKey: '<string>',
Rank: 123,
ApprovedBy: 123,
ApprovedText: '<string>',
ApprovedRegisteredBy: 123,
ApprovedRegisteredDate: '2023-11-07T05:31:56Z',
ExtraField1: '<string>',
ExtraField2: '<string>',
ExtraField3: '<string>',
ExtraField4: '<string>',
ExtraField5: '<string>',
LastRecalculated: '2023-11-07T05:31:56Z',
Updated: '2023-11-07T05:31:56Z',
UpdatedAssociateId: 123,
Registered: '2023-11-07T05:31:56Z',
RegisteredAssociateId: 123,
RequestAssociateId: 123,
RequestComment: '<string>',
QuoteAlternatives: [
{
QuoteAlternativeId: 123,
ERPQuoteAlternativeKey: '<string>',
QuoteVersionId: 123,
Name: '<string>',
Description: '<string>',
Reason: '<string>',
ERPDiscountPercent: 123,
ERPDiscountAmount: 123,
DiscountPercent: 123,
DiscountAmount: 123,
VATInfo: '<string>',
VAT: 123,
EarningPercent: 123,
EarningAmount: 123,
SubTotal: 123,
TotalPrice: 123,
ExtraField1: '<string>',
ExtraField2: '<string>',
ExtraField3: '<string>',
ExtraField4: '<string>',
ExtraField5: '<string>',
TableRight: {Mask: '<string>', Reason: '<string>'},
FieldProperties: {}
}
],
TableRight: {Mask: '<string>', Reason: '<string>'},
FieldProperties: {}
}
],
TableRight: {Mask: '<string>', Reason: '<string>'},
FieldProperties: {}
}
})
};
fetch('http://localhost:65002/api/v1/Agents/Quote/SaveQuoteEntity', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"QuoteId": 123,
"SaleId": 123,
"QuoteConnectionId": 123,
"ERPQuoteKey": "<string>",
"ERPOrderKey": "<string>",
"ActiveQuoteVersionId": 123,
"AcceptedQuoteAlternativeId": 123,
"UseValuesFromQuote": 123,
"DocumentId": 123,
"PoNumber": "<string>",
"OrderComment": "<string>",
"PreferredEmailCulture": "<string>",
"QuoteVersions": [
{
"QuoteVersionId": 123,
"ERPQuoteVersionKey": "<string>",
"QuoteId": 123,
"Description": "<string>",
"Number": "<string>",
"State": "Unknown",
"ArchivedState": "Unknown",
"Status": "Ok",
"Reason": "<string>",
"LikelyQuoteAlternativeId": 123,
"SentDate": "2023-11-07T05:31:56Z",
"FollowupId": 123,
"ExpirationDate": "2023-11-07T05:31:56Z",
"DeliveryCountryId": 123,
"HasOwnDeliveryAddress": true,
"InvoiceCountryId": 123,
"HasOwnInvoiceAddress": true,
"ERPPaymentTermsKey": "<string>",
"ERPPaymentTypeKey": "<string>",
"ERPDeliveryTermsKey": "<string>",
"ERPDeliveryTypeKey": "<string>",
"Rank": 123,
"ApprovedBy": 123,
"ApprovedText": "<string>",
"ApprovedRegisteredBy": 123,
"ApprovedRegisteredDate": "2023-11-07T05:31:56Z",
"ExtraField1": "<string>",
"ExtraField2": "<string>",
"ExtraField3": "<string>",
"ExtraField4": "<string>",
"ExtraField5": "<string>",
"LastRecalculated": "2023-11-07T05:31:56Z",
"Updated": "2023-11-07T05:31:56Z",
"UpdatedAssociateId": 123,
"Registered": "2023-11-07T05:31:56Z",
"RegisteredAssociateId": 123,
"RequestAssociateId": 123,
"RequestComment": "<string>",
"QuoteAlternatives": [
{
"QuoteAlternativeId": 123,
"ERPQuoteAlternativeKey": "<string>",
"QuoteVersionId": 123,
"Name": "<string>",
"Description": "<string>",
"Status": "Ok",
"Reason": "<string>",
"ERPDiscountPercent": 123,
"ERPDiscountAmount": 123,
"DiscountPercent": 123,
"DiscountAmount": 123,
"UserValueOverride": "None",
"VATInfo": "<string>",
"VAT": 123,
"EarningPercent": 123,
"EarningAmount": 123,
"SubTotal": 123,
"TotalPrice": 123,
"ExtraField1": "<string>",
"ExtraField2": "<string>",
"ExtraField3": "<string>",
"ExtraField4": "<string>",
"ExtraField5": "<string>",
"TableRight": {
"Mask": "<string>",
"Reason": "<string>"
},
"FieldProperties": {}
}
],
"TableRight": {
"Mask": "<string>",
"Reason": "<string>"
},
"FieldProperties": {}
}
],
"TableRight": {
"Mask": "<string>",
"Reason": "<string>"
},
"FieldProperties": {}
}Save Quote Entity
Saves a QuoteEntity.
Versions and alternatives will not be saved by this call. NsApiSlow threshold: 5000 ms.
using RestSharp;
var options = new RestClientOptions("http://localhost:65002/api/v1/Agents/Quote/SaveQuoteEntity");
var client = new RestClient(options);
var request = new RestRequest("");
request.AddHeader("Authorization", "Bearer <token>");
request.AddJsonBody("{\n \"QuoteEntity\": {\n \"QuoteId\": 123,\n \"SaleId\": 123,\n \"QuoteConnectionId\": 123,\n \"ERPQuoteKey\": \"<string>\",\n \"ERPOrderKey\": \"<string>\",\n \"ActiveQuoteVersionId\": 123,\n \"AcceptedQuoteAlternativeId\": 123,\n \"UseValuesFromQuote\": 123,\n \"DocumentId\": 123,\n \"PoNumber\": \"<string>\",\n \"OrderComment\": \"<string>\",\n \"PreferredEmailCulture\": \"<string>\",\n \"QuoteVersions\": [\n {\n \"QuoteVersionId\": 123,\n \"ERPQuoteVersionKey\": \"<string>\",\n \"QuoteId\": 123,\n \"Description\": \"<string>\",\n \"Number\": \"<string>\",\n \"Reason\": \"<string>\",\n \"LikelyQuoteAlternativeId\": 123,\n \"SentDate\": \"2023-11-07T05:31:56Z\",\n \"FollowupId\": 123,\n \"ExpirationDate\": \"2023-11-07T05:31:56Z\",\n \"DeliveryCountryId\": 123,\n \"HasOwnDeliveryAddress\": true,\n \"InvoiceCountryId\": 123,\n \"HasOwnInvoiceAddress\": true,\n \"ERPPaymentTermsKey\": \"<string>\",\n \"ERPPaymentTypeKey\": \"<string>\",\n \"ERPDeliveryTermsKey\": \"<string>\",\n \"ERPDeliveryTypeKey\": \"<string>\",\n \"Rank\": 123,\n \"ApprovedBy\": 123,\n \"ApprovedText\": \"<string>\",\n \"ApprovedRegisteredBy\": 123,\n \"ApprovedRegisteredDate\": \"2023-11-07T05:31:56Z\",\n \"ExtraField1\": \"<string>\",\n \"ExtraField2\": \"<string>\",\n \"ExtraField3\": \"<string>\",\n \"ExtraField4\": \"<string>\",\n \"ExtraField5\": \"<string>\",\n \"LastRecalculated\": \"2023-11-07T05:31:56Z\",\n \"Updated\": \"2023-11-07T05:31:56Z\",\n \"UpdatedAssociateId\": 123,\n \"Registered\": \"2023-11-07T05:31:56Z\",\n \"RegisteredAssociateId\": 123,\n \"RequestAssociateId\": 123,\n \"RequestComment\": \"<string>\",\n \"QuoteAlternatives\": [\n {\n \"QuoteAlternativeId\": 123,\n \"ERPQuoteAlternativeKey\": \"<string>\",\n \"QuoteVersionId\": 123,\n \"Name\": \"<string>\",\n \"Description\": \"<string>\",\n \"Reason\": \"<string>\",\n \"ERPDiscountPercent\": 123,\n \"ERPDiscountAmount\": 123,\n \"DiscountPercent\": 123,\n \"DiscountAmount\": 123,\n \"VATInfo\": \"<string>\",\n \"VAT\": 123,\n \"EarningPercent\": 123,\n \"EarningAmount\": 123,\n \"SubTotal\": 123,\n \"TotalPrice\": 123,\n \"ExtraField1\": \"<string>\",\n \"ExtraField2\": \"<string>\",\n \"ExtraField3\": \"<string>\",\n \"ExtraField4\": \"<string>\",\n \"ExtraField5\": \"<string>\",\n \"TableRight\": {\n \"Mask\": \"<string>\",\n \"Reason\": \"<string>\"\n },\n \"FieldProperties\": {}\n }\n ],\n \"TableRight\": {\n \"Mask\": \"<string>\",\n \"Reason\": \"<string>\"\n },\n \"FieldProperties\": {}\n }\n ],\n \"TableRight\": {\n \"Mask\": \"<string>\",\n \"Reason\": \"<string>\"\n },\n \"FieldProperties\": {}\n }\n}", false);
var response = await client.PostAsync(request);
Console.WriteLine("{0}", response.Content);const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
QuoteEntity: {
QuoteId: 123,
SaleId: 123,
QuoteConnectionId: 123,
ERPQuoteKey: '<string>',
ERPOrderKey: '<string>',
ActiveQuoteVersionId: 123,
AcceptedQuoteAlternativeId: 123,
UseValuesFromQuote: 123,
DocumentId: 123,
PoNumber: '<string>',
OrderComment: '<string>',
PreferredEmailCulture: '<string>',
QuoteVersions: [
{
QuoteVersionId: 123,
ERPQuoteVersionKey: '<string>',
QuoteId: 123,
Description: '<string>',
Number: '<string>',
Reason: '<string>',
LikelyQuoteAlternativeId: 123,
SentDate: '2023-11-07T05:31:56Z',
FollowupId: 123,
ExpirationDate: '2023-11-07T05:31:56Z',
DeliveryCountryId: 123,
HasOwnDeliveryAddress: true,
InvoiceCountryId: 123,
HasOwnInvoiceAddress: true,
ERPPaymentTermsKey: '<string>',
ERPPaymentTypeKey: '<string>',
ERPDeliveryTermsKey: '<string>',
ERPDeliveryTypeKey: '<string>',
Rank: 123,
ApprovedBy: 123,
ApprovedText: '<string>',
ApprovedRegisteredBy: 123,
ApprovedRegisteredDate: '2023-11-07T05:31:56Z',
ExtraField1: '<string>',
ExtraField2: '<string>',
ExtraField3: '<string>',
ExtraField4: '<string>',
ExtraField5: '<string>',
LastRecalculated: '2023-11-07T05:31:56Z',
Updated: '2023-11-07T05:31:56Z',
UpdatedAssociateId: 123,
Registered: '2023-11-07T05:31:56Z',
RegisteredAssociateId: 123,
RequestAssociateId: 123,
RequestComment: '<string>',
QuoteAlternatives: [
{
QuoteAlternativeId: 123,
ERPQuoteAlternativeKey: '<string>',
QuoteVersionId: 123,
Name: '<string>',
Description: '<string>',
Reason: '<string>',
ERPDiscountPercent: 123,
ERPDiscountAmount: 123,
DiscountPercent: 123,
DiscountAmount: 123,
VATInfo: '<string>',
VAT: 123,
EarningPercent: 123,
EarningAmount: 123,
SubTotal: 123,
TotalPrice: 123,
ExtraField1: '<string>',
ExtraField2: '<string>',
ExtraField3: '<string>',
ExtraField4: '<string>',
ExtraField5: '<string>',
TableRight: {Mask: '<string>', Reason: '<string>'},
FieldProperties: {}
}
],
TableRight: {Mask: '<string>', Reason: '<string>'},
FieldProperties: {}
}
],
TableRight: {Mask: '<string>', Reason: '<string>'},
FieldProperties: {}
}
})
};
fetch('http://localhost:65002/api/v1/Agents/Quote/SaveQuoteEntity', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_PORT => "65002",
CURLOPT_URL => "http://localhost:65002/api/v1/Agents/Quote/SaveQuoteEntity",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'QuoteEntity' => [
'QuoteId' => 123,
'SaleId' => 123,
'QuoteConnectionId' => 123,
'ERPQuoteKey' => '<string>',
'ERPOrderKey' => '<string>',
'ActiveQuoteVersionId' => 123,
'AcceptedQuoteAlternativeId' => 123,
'UseValuesFromQuote' => 123,
'DocumentId' => 123,
'PoNumber' => '<string>',
'OrderComment' => '<string>',
'PreferredEmailCulture' => '<string>',
'QuoteVersions' => [
[
'QuoteVersionId' => 123,
'ERPQuoteVersionKey' => '<string>',
'QuoteId' => 123,
'Description' => '<string>',
'Number' => '<string>',
'Reason' => '<string>',
'LikelyQuoteAlternativeId' => 123,
'SentDate' => '2023-11-07T05:31:56Z',
'FollowupId' => 123,
'ExpirationDate' => '2023-11-07T05:31:56Z',
'DeliveryCountryId' => 123,
'HasOwnDeliveryAddress' => true,
'InvoiceCountryId' => 123,
'HasOwnInvoiceAddress' => true,
'ERPPaymentTermsKey' => '<string>',
'ERPPaymentTypeKey' => '<string>',
'ERPDeliveryTermsKey' => '<string>',
'ERPDeliveryTypeKey' => '<string>',
'Rank' => 123,
'ApprovedBy' => 123,
'ApprovedText' => '<string>',
'ApprovedRegisteredBy' => 123,
'ApprovedRegisteredDate' => '2023-11-07T05:31:56Z',
'ExtraField1' => '<string>',
'ExtraField2' => '<string>',
'ExtraField3' => '<string>',
'ExtraField4' => '<string>',
'ExtraField5' => '<string>',
'LastRecalculated' => '2023-11-07T05:31:56Z',
'Updated' => '2023-11-07T05:31:56Z',
'UpdatedAssociateId' => 123,
'Registered' => '2023-11-07T05:31:56Z',
'RegisteredAssociateId' => 123,
'RequestAssociateId' => 123,
'RequestComment' => '<string>',
'QuoteAlternatives' => [
[
'QuoteAlternativeId' => 123,
'ERPQuoteAlternativeKey' => '<string>',
'QuoteVersionId' => 123,
'Name' => '<string>',
'Description' => '<string>',
'Reason' => '<string>',
'ERPDiscountPercent' => 123,
'ERPDiscountAmount' => 123,
'DiscountPercent' => 123,
'DiscountAmount' => 123,
'VATInfo' => '<string>',
'VAT' => 123,
'EarningPercent' => 123,
'EarningAmount' => 123,
'SubTotal' => 123,
'TotalPrice' => 123,
'ExtraField1' => '<string>',
'ExtraField2' => '<string>',
'ExtraField3' => '<string>',
'ExtraField4' => '<string>',
'ExtraField5' => '<string>',
'TableRight' => [
'Mask' => '<string>',
'Reason' => '<string>'
],
'FieldProperties' => [
]
]
],
'TableRight' => [
'Mask' => '<string>',
'Reason' => '<string>'
],
'FieldProperties' => [
]
]
],
'TableRight' => [
'Mask' => '<string>',
'Reason' => '<string>'
],
'FieldProperties' => [
]
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}import requests
url = "http://localhost:65002/api/v1/Agents/Quote/SaveQuoteEntity"
payload = { "QuoteEntity": {
"QuoteId": 123,
"SaleId": 123,
"QuoteConnectionId": 123,
"ERPQuoteKey": "<string>",
"ERPOrderKey": "<string>",
"ActiveQuoteVersionId": 123,
"AcceptedQuoteAlternativeId": 123,
"UseValuesFromQuote": 123,
"DocumentId": 123,
"PoNumber": "<string>",
"OrderComment": "<string>",
"PreferredEmailCulture": "<string>",
"QuoteVersions": [
{
"QuoteVersionId": 123,
"ERPQuoteVersionKey": "<string>",
"QuoteId": 123,
"Description": "<string>",
"Number": "<string>",
"Reason": "<string>",
"LikelyQuoteAlternativeId": 123,
"SentDate": "2023-11-07T05:31:56Z",
"FollowupId": 123,
"ExpirationDate": "2023-11-07T05:31:56Z",
"DeliveryCountryId": 123,
"HasOwnDeliveryAddress": True,
"InvoiceCountryId": 123,
"HasOwnInvoiceAddress": True,
"ERPPaymentTermsKey": "<string>",
"ERPPaymentTypeKey": "<string>",
"ERPDeliveryTermsKey": "<string>",
"ERPDeliveryTypeKey": "<string>",
"Rank": 123,
"ApprovedBy": 123,
"ApprovedText": "<string>",
"ApprovedRegisteredBy": 123,
"ApprovedRegisteredDate": "2023-11-07T05:31:56Z",
"ExtraField1": "<string>",
"ExtraField2": "<string>",
"ExtraField3": "<string>",
"ExtraField4": "<string>",
"ExtraField5": "<string>",
"LastRecalculated": "2023-11-07T05:31:56Z",
"Updated": "2023-11-07T05:31:56Z",
"UpdatedAssociateId": 123,
"Registered": "2023-11-07T05:31:56Z",
"RegisteredAssociateId": 123,
"RequestAssociateId": 123,
"RequestComment": "<string>",
"QuoteAlternatives": [
{
"QuoteAlternativeId": 123,
"ERPQuoteAlternativeKey": "<string>",
"QuoteVersionId": 123,
"Name": "<string>",
"Description": "<string>",
"Reason": "<string>",
"ERPDiscountPercent": 123,
"ERPDiscountAmount": 123,
"DiscountPercent": 123,
"DiscountAmount": 123,
"VATInfo": "<string>",
"VAT": 123,
"EarningPercent": 123,
"EarningAmount": 123,
"SubTotal": 123,
"TotalPrice": 123,
"ExtraField1": "<string>",
"ExtraField2": "<string>",
"ExtraField3": "<string>",
"ExtraField4": "<string>",
"ExtraField5": "<string>",
"TableRight": {
"Mask": "<string>",
"Reason": "<string>"
},
"FieldProperties": {}
}
],
"TableRight": {
"Mask": "<string>",
"Reason": "<string>"
},
"FieldProperties": {}
}
],
"TableRight": {
"Mask": "<string>",
"Reason": "<string>"
},
"FieldProperties": {}
} }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
QuoteEntity: {
QuoteId: 123,
SaleId: 123,
QuoteConnectionId: 123,
ERPQuoteKey: '<string>',
ERPOrderKey: '<string>',
ActiveQuoteVersionId: 123,
AcceptedQuoteAlternativeId: 123,
UseValuesFromQuote: 123,
DocumentId: 123,
PoNumber: '<string>',
OrderComment: '<string>',
PreferredEmailCulture: '<string>',
QuoteVersions: [
{
QuoteVersionId: 123,
ERPQuoteVersionKey: '<string>',
QuoteId: 123,
Description: '<string>',
Number: '<string>',
Reason: '<string>',
LikelyQuoteAlternativeId: 123,
SentDate: '2023-11-07T05:31:56Z',
FollowupId: 123,
ExpirationDate: '2023-11-07T05:31:56Z',
DeliveryCountryId: 123,
HasOwnDeliveryAddress: true,
InvoiceCountryId: 123,
HasOwnInvoiceAddress: true,
ERPPaymentTermsKey: '<string>',
ERPPaymentTypeKey: '<string>',
ERPDeliveryTermsKey: '<string>',
ERPDeliveryTypeKey: '<string>',
Rank: 123,
ApprovedBy: 123,
ApprovedText: '<string>',
ApprovedRegisteredBy: 123,
ApprovedRegisteredDate: '2023-11-07T05:31:56Z',
ExtraField1: '<string>',
ExtraField2: '<string>',
ExtraField3: '<string>',
ExtraField4: '<string>',
ExtraField5: '<string>',
LastRecalculated: '2023-11-07T05:31:56Z',
Updated: '2023-11-07T05:31:56Z',
UpdatedAssociateId: 123,
Registered: '2023-11-07T05:31:56Z',
RegisteredAssociateId: 123,
RequestAssociateId: 123,
RequestComment: '<string>',
QuoteAlternatives: [
{
QuoteAlternativeId: 123,
ERPQuoteAlternativeKey: '<string>',
QuoteVersionId: 123,
Name: '<string>',
Description: '<string>',
Reason: '<string>',
ERPDiscountPercent: 123,
ERPDiscountAmount: 123,
DiscountPercent: 123,
DiscountAmount: 123,
VATInfo: '<string>',
VAT: 123,
EarningPercent: 123,
EarningAmount: 123,
SubTotal: 123,
TotalPrice: 123,
ExtraField1: '<string>',
ExtraField2: '<string>',
ExtraField3: '<string>',
ExtraField4: '<string>',
ExtraField5: '<string>',
TableRight: {Mask: '<string>', Reason: '<string>'},
FieldProperties: {}
}
],
TableRight: {Mask: '<string>', Reason: '<string>'},
FieldProperties: {}
}
],
TableRight: {Mask: '<string>', Reason: '<string>'},
FieldProperties: {}
}
})
};
fetch('http://localhost:65002/api/v1/Agents/Quote/SaveQuoteEntity', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"QuoteId": 123,
"SaleId": 123,
"QuoteConnectionId": 123,
"ERPQuoteKey": "<string>",
"ERPOrderKey": "<string>",
"ActiveQuoteVersionId": 123,
"AcceptedQuoteAlternativeId": 123,
"UseValuesFromQuote": 123,
"DocumentId": 123,
"PoNumber": "<string>",
"OrderComment": "<string>",
"PreferredEmailCulture": "<string>",
"QuoteVersions": [
{
"QuoteVersionId": 123,
"ERPQuoteVersionKey": "<string>",
"QuoteId": 123,
"Description": "<string>",
"Number": "<string>",
"State": "Unknown",
"ArchivedState": "Unknown",
"Status": "Ok",
"Reason": "<string>",
"LikelyQuoteAlternativeId": 123,
"SentDate": "2023-11-07T05:31:56Z",
"FollowupId": 123,
"ExpirationDate": "2023-11-07T05:31:56Z",
"DeliveryCountryId": 123,
"HasOwnDeliveryAddress": true,
"InvoiceCountryId": 123,
"HasOwnInvoiceAddress": true,
"ERPPaymentTermsKey": "<string>",
"ERPPaymentTypeKey": "<string>",
"ERPDeliveryTermsKey": "<string>",
"ERPDeliveryTypeKey": "<string>",
"Rank": 123,
"ApprovedBy": 123,
"ApprovedText": "<string>",
"ApprovedRegisteredBy": 123,
"ApprovedRegisteredDate": "2023-11-07T05:31:56Z",
"ExtraField1": "<string>",
"ExtraField2": "<string>",
"ExtraField3": "<string>",
"ExtraField4": "<string>",
"ExtraField5": "<string>",
"LastRecalculated": "2023-11-07T05:31:56Z",
"Updated": "2023-11-07T05:31:56Z",
"UpdatedAssociateId": 123,
"Registered": "2023-11-07T05:31:56Z",
"RegisteredAssociateId": 123,
"RequestAssociateId": 123,
"RequestComment": "<string>",
"QuoteAlternatives": [
{
"QuoteAlternativeId": 123,
"ERPQuoteAlternativeKey": "<string>",
"QuoteVersionId": 123,
"Name": "<string>",
"Description": "<string>",
"Status": "Ok",
"Reason": "<string>",
"ERPDiscountPercent": 123,
"ERPDiscountAmount": 123,
"DiscountPercent": 123,
"DiscountAmount": 123,
"UserValueOverride": "None",
"VATInfo": "<string>",
"VAT": 123,
"EarningPercent": 123,
"EarningAmount": 123,
"SubTotal": 123,
"TotalPrice": 123,
"ExtraField1": "<string>",
"ExtraField2": "<string>",
"ExtraField3": "<string>",
"ExtraField4": "<string>",
"ExtraField5": "<string>",
"TableRight": {
"Mask": "<string>",
"Reason": "<string>"
},
"FieldProperties": {}
}
],
"TableRight": {
"Mask": "<string>",
"Reason": "<string>"
},
"FieldProperties": {}
}
],
"TableRight": {
"Mask": "<string>",
"Reason": "<string>"
},
"FieldProperties": {}
}Authorizations
SuperOffice SuperId OAuth implicit flow. You need to issue a request to the SuperId authorization URL https://online.superoffice.com/login/common/oauth/authorize?response_type=token &client_id=670734e0-4c5a-11e3-be9e-a171392e81db &redirect_uri=https://example.com/spa/
passing in the application id and redirect URL.
SuperId will log the user in, and redirect to the requested redirect URL with a #payload containing the access token and claims. (The redirect URL must be registered with SuperId in advance)
https://example.com/spa#access_token=8A%3aCust12227.AXRrCITpPBvQX3UbIohb &token_type=bearer &state= &expires_in=3600 &ctx=Cust12227 &netserver_url=https%3a%2f%2fsod.superoffice.com%2fCust12227%2fRemote%2fServices82%2f
You can take the #access_token value and pass it as the Authenticate HTTP header as a BEARER token.
Headers
Query Parameters
Body
QuoteEntity
Response
OK
Quote methods Carrier object for QuoteEntity. Services for the QuoteEntity Carrier is available from the Quote Agent.